Skip to content

Return extracted SpanContext when it is sampled but invalid#8634

Draft
thswlsqls wants to merge 1 commit into
open-telemetry:mainfrom
thswlsqls:fix/opentracing-shim-extract-sampled-spancontext
Draft

Return extracted SpanContext when it is sampled but invalid#8634
thswlsqls wants to merge 1 commit into
open-telemetry:mainfrom
thswlsqls:fix/opentracing-shim-extract-sampled-spancontext

Conversation

@thswlsqls

Copy link
Copy Markdown
Contributor

Fixes #5339

Description

Testing done

  • Added TracerShimTest#extract_invalidButSampledSpanContext: a test propagator extracts an invalid but sampled SpanContext, and extract returns a non-null, sampled SpanContextShim. Fails without the Propagation change.
  • ./gradlew :opentracing-shim:check — 84 tests passed.
  • Added a ## Unreleased CHANGELOG entry. Propagation is package-private and no public signature changed, so no apidiff update was generated.

@thswlsqls
thswlsqls force-pushed the fix/opentracing-shim-extract-sampled-spancontext branch from fb11ef4 to 8ffae0e Compare July 17, 2026 06:04
@codecov

codecov Bot commented Jul 17, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 91.64%. Comparing base (09d6c17) to head (8db6342).

Additional details and impacted files
@@            Coverage Diff            @@
##               main    #8634   +/-   ##
=========================================
  Coverage     91.64%   91.64%           
- Complexity    10348    10349    +1     
=========================================
  Files          1013     1013           
  Lines         27380    27382    +2     
  Branches       3218     3220    +2     
=========================================
+ Hits          25092    25094    +2     
  Misses         1558     1558           
  Partials        730      730           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@thswlsqls
thswlsqls force-pushed the fix/opentracing-shim-extract-sampled-spancontext branch from 8ffae0e to 8db6342 Compare July 18, 2026 01:00
@opentelemetry-pr-dashboard

Copy link
Copy Markdown

Pull request dashboard status

  • Waiting on: Author
  • Next step: Move out of draft to request review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[OpentracingShim] Support returning non-null SpanContextShim in Propagation.extractTextMap when traceId and SpanId are not present in OTel SpanContext

1 participant