-
Notifications
You must be signed in to change notification settings - Fork 790
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
Optionally record activities in the service #13835
Conversation
This reverts commit c62e89c
* Move activities to BackgroundChecker layer, deduplicate
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice - I think it might demonstrate the value better if you could attach trace views to show the results.
Have attached Jaeger screenshots now and removed any dependencies except for |
We can merge after @KevinRansom looks at it |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this, it looks good. However, we will need to do some due diligence internally to ensure that this satisfies our telemetry and privacy policies. We will add this to our November milestone to see if we can get it approved.
Planning issue here: #14210
Thanks for looking. OOI what makes this more sensitive than any other existing logging? Also it doesn't depend on open telemetry and is off by default. Is there some increased risk of user data leakage or something like that? |
@vzarytovskii If this gets merged, how difficult will it be to add new activities for other areas of the compiler in future PRs? I'm looking into optimization and having some detailed tracing there would help (eg. a span for each file being optimized, similar to how parsing & type-checking work atm). Will it require new approvals from the policy PoV? |
Yep, it got approved in principle. Since compiler doesn't work with PII or EUII per se, we can just add new metrics, as long as we don't opt-in them by default (and we don't for neither old or new telemetry). |
@safesparrow It's ready to merge, let me know if you want any more changes here, or if we can merge it now. |
That is great news, let's merge it in so that new ones can build on this module. |
I'm happy to have it merged, and we can iterate easily in future. Thanks for help all 👍 |
This needs to be reverted: #14413 |
Revert has to also go directly to 17.5 |
Or, as Kevin pointed out, that might be solved by adding package to vsix. |
was removed in dotnet/fsharp#13835
was removed in dotnet/fsharp#13835
was removed in dotnet/fsharp#13835
Follow up on @baronfel 's initial work.
This PR adds activity recording to the FCS service.
It adds a dependency on
System.Diagnostics.DiagnosticSource
but nothing else.Recording and exporting of activities can be enabled in user code (eg. in the IDE or external tests) - example.
Sample traces
Sample traces produced can be found in https://github.com/safesparrow/fsharp-benchmark-generator/tree/main/trace_samples
They can be opened with Jaeger UI.
Jaeger UI screenshots:
Fantomas sample (codebase)
stress_huge_dense sample (codebase)
Sample traces for perf analysis of #13521
The driver for this PR is the need to easily verify the behaviour of the compiler/service, especially w.r.t. multi-threaded work.
With that in mind, I produced the following traces showcasing the behaviour of parallel project analysis:
50_leaves sample, parallel analysis on, server GC
50_leaves sample, parallel analysis on, workstation GC
50_leaves sample, parallel analysis off, server GC
50_leaves sample, parallel analysis off, workstation GC
Generating traces
Sample traces can be generated with the following tools:
using the following script:
Notes
Names of the activities and tags are likely wrong - please do suggest better names🙂
To do: