Repository navigation
Conversation
Treat an unsampled parent threshold as consistent only when it matches R >= T, omit sampling-intent attributes on DROP, and apply tracestate updates to the parentTraceState argument.
Pull request dashboard statusWaiting on reviewers · refreshed 2026-11-22 10:18 UTC Review the latest changes. Status above doesn't look right?
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #9050 +/- ##
============================================
- Coverage 90.45% 90.44% -0.01%
Complexity 11182 11182
============================================
Files 1032 1032
Lines 30508 30510 +2
Branches 3992 3992
============================================
- Hits 27596 27595 -1
- Misses 1935 1938 +3
Partials 977 977 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
ComposableParentThresholdSamplertreats a parent threshold as consistent only when the sampled flag matchesR >= T. An unsampled parent withth <= Rnow returns an invalid threshold, soCompositeSamplerdrops the child instead of sampling it. A consistent unsampled parent (rv < th, including the existingrv=1,th=10case) still keeps that threshold.CompositeSampler.getAttributes()returns empty attributes onDROP. Intent attributes are added only on a positive decision, so an annotating sampler no longer leaks them onto a dropped span.getUpdatedTraceStateapplies the intent updater to itsparentTraceStateargument, then still overwrites theotkey with the threshold computed inshouldSample.Fixes #9047.
Test plan
JDK 25 (Temurin 25.0.4+7):
ComposableParentThresholdSamplerTest9/9 andCompositeSamplerTest20/20 passed.