-
Notifications
You must be signed in to change notification settings - Fork 10
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
Skip serializing parent-id when 0 #879
Conversation
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.
LGTM
BenchmarksComparisonBenchmark execution time: 2025-02-14 13:37:27 Comparing candidate commit 76894d8 in PR branch Found 2 performance improvements and 0 performance regressions! Performance is the same for 50 metrics, 2 unstable metrics. scenario:credit_card/is_card_number/378282246310005
CandidateCandidate benchmark detailsGroup 1
Group 2
Group 3
Group 4
Group 5
Group 6
Group 7
Group 8
Group 9
Group 10
Group 11
Group 12
Group 13
BaselineOmitted due to size. |
@@ -57,6 +57,7 @@ pub struct Span { | |||
pub r#type: BytesString, | |||
pub trace_id: u64, | |||
pub span_id: u64, | |||
#[serde(skip_serializing_if = "is_default")] |
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.
Like we are talking, probably a test case + making it Option<> would be nice.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #879 +/- ##
==========================================
- Coverage 71.66% 71.66% -0.01%
==========================================
Files 324 324
Lines 48248 48248
==========================================
- Hits 34576 34575 -1
- Misses 13672 13673 +1
|
What does this PR do?
Skip serializing parent-id when 0. The agent parses it in the same way wether it is defined or not.
Motivation
Dotnet snapshots are expecting the field to not be defined
Additional Notes
Anything else we should know when reviewing?
How to test the change?
Describe here in detail how the change can be validated.