feat: Leverage Suppression Context in Sdk#2868
Merged
cijothomas merged 16 commits intoopen-telemetry:mainfrom Mar 28, 2025
Merged
feat: Leverage Suppression Context in Sdk#2868cijothomas merged 16 commits intoopen-telemetry:mainfrom
cijothomas merged 16 commits intoopen-telemetry:mainfrom
Conversation
cijothomas
commented
Mar 27, 2025
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2868 +/- ##
=======================================
+ Coverage 80.8% 81.1% +0.2%
=======================================
Files 124 124
Lines 23836 23927 +91
=======================================
+ Hits 19283 19410 +127
+ Misses 4553 4517 -36 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
lalitb
reviewed
Mar 27, 2025
utpilla
reviewed
Mar 27, 2025
utpilla
reviewed
Mar 27, 2025
utpilla
reviewed
Mar 27, 2025
utpilla
reviewed
Mar 27, 2025
utpilla
reviewed
Mar 27, 2025
utpilla
reviewed
Mar 27, 2025
Contributor
The regular instruments don't have to follow what bounded instrument does. They can easily accommodate the cost of doing the check, but we probably should have a consistent story for all metric instruments. |
utpilla
reviewed
Mar 27, 2025
utpilla
reviewed
Mar 27, 2025
utpilla
reviewed
Mar 27, 2025
utpilla
reviewed
Mar 27, 2025
utpilla
reviewed
Mar 27, 2025
utpilla
reviewed
Mar 27, 2025
utpilla
reviewed
Mar 27, 2025
Co-authored-by: Utkarsh Umesan Pillai <[email protected]>
utpilla
approved these changes
Mar 27, 2025
lalitb
reviewed
Mar 28, 2025
lalitb
reviewed
Mar 28, 2025
lalitb
reviewed
Mar 28, 2025
lalitb
approved these changes
Mar 28, 2025
Member
lalitb
left a comment
There was a problem hiding this comment.
Thanks for working on this., LGTM, with nit comments.
bantonsson
added a commit
to bantonsson/opentelemetry-rust
that referenced
this pull request
Apr 3, 2025
This reverts commit 62e43c5.
bantonsson
pushed a commit
to bantonsson/opentelemetry-rust
that referenced
this pull request
Oct 9, 2025
Co-authored-by: Utkarsh Umesan Pillai <[email protected]>
takumi-earth
pushed a commit
to earthlings-dev/opentelemetry-rust
that referenced
this pull request
Jan 27, 2026
Co-authored-by: Utkarsh Umesan Pillai <[email protected]>
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.
Fixes: #761
Continuing on top of #2821 , this PR modifies SDK's own components to suppress telemetry from its own operation using
Context::enter_telemetry_suppressed_scope. This is done in the dedicated thread created by BatchProcessors, PeriodicReader.Also modified Log SDK to respect this and ignore logs if under suppression.
I did not modify Trace SDK and Metrics SDK to do the same because:
Trace SDK (and API) need some refactoring to find the right spot to do this. This is better handled in its own PR.Edited: This is done in Sampler now. This could be moved even earlier after some refactoring outside of this PR.Note: This does not prevent logs from external crates like tonic, hyper being fed back to Otel, as they don't propagate Otel context. That also can be solved, but this PR is not attempting to solve that.
Basic tests added, design doc updated.