Skip to content
This repository has been archived by the owner on Jan 24, 2023. It is now read-only.

implement "b3 single" header format #66

Closed
codefromthecrypt opened this issue Aug 29, 2018 · 5 comments
Closed

implement "b3 single" header format #66

codefromthecrypt opened this issue Aug 29, 2018 · 5 comments

Comments

@codefromthecrypt
Copy link

As discussed on openzipkin/b3-propagation#21 and first implemented here: https://github.com/openzipkin/brave/blob/master/brave/src/main/java/brave/propagation/B3SingleFormat.java https://github.com/openzipkin/brave/blob/master/brave/src/test/java/brave/propagation/B3SingleFormatTest.java

Let's support at least reading "b3" header from a single string, most commonly traceid-spanid-1
It would also be nice to support optionally writing this, especially in message providers or others with constrained environments.

Brave currently has a property like this, but its name could change with feedback:

    /**
     * When true, only writes a single {@link B3SingleFormat b3 header} for outbound propagation.
     *
     * <p>Use this to reduce overhead. Note: normal {@link Tracing#propagation()} is used to parse
     * incoming headers. The implementation must be able to read "b3" headers.
     */
    public Builder b3SingleFormat(boolean b3SingleFormat) {
      this.b3SingleFormat = b3SingleFormat;
      return this;
}
@Aaronontheweb
Copy link
Member

@adriancole good deal! I'll see if we can sneak this into v0.4.1

@Aaronontheweb Aaronontheweb added this to the v0.4.1 Release milestone Dec 31, 2018
Aaronontheweb added a commit to Aaronontheweb/Petabridge.Tracing.Zipkin that referenced this issue Dec 31, 2018
Aaronontheweb added a commit to Aaronontheweb/Petabridge.Tracing.Zipkin that referenced this issue Jan 2, 2019
@codefromthecrypt
Copy link
Author

codefromthecrypt commented Jan 2, 2019 via email

@Aaronontheweb
Copy link
Member

@adriancole thanks! We don't quite support the sampling flag the way you do in Brave though - we should probably make it into a nullable field so we can explicitly report "not sampled" instead of treating "not set" and "not sampled" as the same thing

@Aaronontheweb
Copy link
Member

Skipped implementing that in v.0.5.0 because it meant a bunch of API changes that I wasn't quite ready to bite off yet for this release.

@codefromthecrypt
Copy link
Author

codefromthecrypt commented Jan 2, 2019 via email

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants