Skip to content
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

B3 propagator package does not confirm to spec. #1821

Closed
owais opened this issue May 6, 2021 · 0 comments · Fixed by #1823
Closed

B3 propagator package does not confirm to spec. #1821

owais opened this issue May 6, 2021 · 0 comments · Fixed by #1823
Assignees
Labels
bug Something isn't working triaged

Comments

@owais
Copy link
Contributor

owais commented May 6, 2021

According to the spec, OTEL_PROPAGATORS env var should support two types of B3 propagators, b3 and b3multi.

b3 is supposed to inject a single header with - separate values. https://github.com/openzipkin/b3-propagation#single-header
b3multi is supposed to inject one header per value. https://github.com/openzipkin/b3-propagation#multiple-headers

Currently, we have a single implement at opentelemetry.propgators.b3.B3Format which actually is the multi-header implementation.

This implementation is exposed as an propagator entry-point with the name b3 instead of b3multi.

This means setting OTEL_PROPAGATORS=b3 will actually use a multi-header B3 propagator instead of single header while as setting OTEL_PROPAGATORS=b3multi will raise an exception.

IMO, this is a bug and should be fixed as follows:

  1. Add two new propagators called B3SingleFormat and B3MultiFormat.
  2. Deprecate the existing B3Format propagator without changing behavior. Deprecation notice should recommend using B3MultiFormat.
  3. Change b3 entrypoint to point to B3SingleFormat implementation (breaking behavioral change).
  4. Add a new b3multi entrypoint to point to B3MultiFormat implementation.
@owais owais added the bug Something isn't working label May 6, 2021
@owais owais self-assigned this May 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working triaged
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants