Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

System.Diagnostics.Activity out of proc monitoring can't access Activity Events or Links #102924

Open
Tracked by #109396
CodeBlanch opened this issue May 31, 2024 · 2 comments

Comments

@CodeBlanch
Copy link
Contributor

We have DiagnosticSourceEventSource which enables listening to Activity \ traces out of process.

DiagnosticSourceEventSource supports an argument FilterAndPayloadSpecs which can be used to configure the events and payload which will be written to the source. Example:

[AS]MyActivitySource/Stop:-TraceId;SpanId;ParentSpanId;ActivityTraceFlags;Kind;DisplayName;StartTimeTicks=StartTimeUtc.Ticks;DurationTicks=Duration.Ticks;Status;StatusDescription;Tags=TagObjects.*Enumerate;ActivitySourceVersion=Source.Version

Tags=TagObjects.*Enumerate; works for retrieving tags.

But this...

Events=Events.*Enumerate;Links=Links.*Enumerate;

...won't work for retrieving Events and/or Links.

The reason it doesn't work is ActivityEvent and ActivityLink structs don't provide a suitable ToString implementation which is how the data gets serialized:

The solution could be to implement more useful ToString operations or provide some other way to include that data via the FilterAndPayloadSpecs. ToString could be tricky for ActivityEvent because it contains its own tag collection.

/cc @noahfalk @tarekgh @samsp-msft

@dotnet-policy-service dotnet-policy-service bot added the untriaged New issue has not been triaged by the area owner label May 31, 2024
Copy link
Contributor

Tagging subscribers to this area: @tarekgh, @tommcdon, @pjanotti
See info in area-owners.md if you want to be subscribed.

@tarekgh tarekgh added this to the Future milestone May 31, 2024
@tarekgh tarekgh added area-System.Diagnostics.Activity and removed untriaged New issue has not been triaged by the area owner area-System.Diagnostics.Tracing labels May 31, 2024
Copy link
Contributor

Tagging subscribers to this area: @dotnet/area-system-diagnostics-activity
See info in area-owners.md if you want to be subscribed.

@tarekgh tarekgh modified the milestones: Future, 10.0.0 Oct 30, 2024
@tarekgh tarekgh mentioned this issue Oct 31, 2024
11 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants