-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Extend property assignment event (The feature is opted-out by default) #11106
Extend property assignment event (The feature is opted-out by default) #11106
Conversation
…gic on bin log side
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.
I have couple comments to consider.
The main thing before signoff - this is currently not a default behavior (neither with /bl) - correct? Property tracking needs to be explicitly opted in - right?
Please add that info into the PR description (as otherwise the 8.5% perf hit might be bit concerning and might need a bit more deeper look)
src/Build/BackEnd/Components/RequestBuilder/IntrinsicTasks/PropertyGroupIntrinsicTask.cs
Outdated
Show resolved
Hide resolved
Co-authored-by: Jan Krivanek <[email protected]>
How do I enable the feature for testing? What setting value did you use for perf testing? |
There are two things I did to investigate the binlog size increase:
For diffing, pick a simple console application, and do an incremental build (not clean build), setting MsBuildLogPropertyTracking to the right value. What is the default value for it currently? Why are property reassignment messages even logged when the value is 0 (the current default)? |
Ah, I see: msbuild/src/Build/Evaluation/PropertyTrackingEvaluatorDataWrapper.cs Lines 320 to 323 in 4042363
|
I'm not quite sure, but I think we might have lost the location for property reassignment with #10102 (FYI @JanKrivanek) |
src/Build/BackEnd/Components/RequestBuilder/IntrinsicTasks/PropertyGroupIntrinsicTask.cs
Outdated
Show resolved
Hide resolved
src/Build/BackEnd/Components/RequestBuilder/IntrinsicTasks/PropertyGroupIntrinsicTask.cs
Outdated
Show resolved
Hide resolved
9ec7d4d
to
9a5ad3c
Compare
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.
Overall looks good.
Before I'm ready to sign-off I want to be sure that the labeling of property source feels sufficient (e.g. the distionction of globals from scripts) and that the conditions are done as they are meant to be.
Ping me once adjusted or commented here and I'll rereview
src/Build/BackEnd/Components/RequestBuilder/IntrinsicTasks/PropertyGroupIntrinsicTask.cs
Outdated
Show resolved
Hide resolved
I think it's mostly in a good shape, I left some minor comments. Since we're not changing the default mainline scenario I'm not worried about perf (which we can always tune in a separate PR). |
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.
Looks good as far as I can see!
Thanks so much for the perseverance.
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.
Awesome work!
Very helpful feature!!
Please as well add a mention of the opt-in env var somewhere into our docs
Fixes #2711
and connected to KirillOsenkov/MSBuildStructuredLog#839
Context
The feature is opted-out by default due to perf considerations !
This implementation covers cases:
Global
source)Also, the message formatting logic was changed for
PropertyReassignmentEventArgs
,PropertyInitialValueSetEventArgs
,UninitializedPropertyReadEventArgs
to have it optimized for existing deduplication logic (message is not passed as a part of event).The event save all the unique data and format it on the receiving side (e.g. LogViewer).
The measurements were taken for the latest OrchardCode