Propagate 8 bits of W3C trace context flags #5030
Labels
blocked:specification
Waiting on clarification of the OpenTelemetry specification before progress can be made
bug
Something isn't working
Milestone
Description
The W3C trace context propagator currently masks unknown trace flags bits, here:
opentelemetry-go/propagation/trace_context.go
Line 50 in da2949b
Expected behavior
Nothing in the specification explicitly says what the SDKs are meant to do here, but I believe the expectation for W3C trace context propagation is that all flags are propagated, even the unrecognized ones. The W3C specification says there are 8 flags, and I think they should all propagate.
When SDKs do not propagate unknown flags, it makes it difficult for new flags to be deployed in a timely manner. In particular, the Sampling SIG is advising OpenTelemetry not to strictly enforce the new W3C Trace Context Level 2 Random flag until this fix is widely deployed.
See open-telemetry/opentelemetry-specification#3924, https://github.com/open-telemetry/oteps/blob/main/text/trace/0235-sampling-threshold-in-trace-state.md, open-telemetry/opentelemetry-specification#3910 where I am drafting proposed sampler changes, hence I discovered this issue. I have a draft with changes that would address the proposed-clarified specification here: main...jmacd:opentelemetry-go:jmacd/randomness but I want to make sure the spec change is generally agreed to before submitting.
The text was updated successfully, but these errors were encountered: