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

Traceid compatible brave #6168

Open
JathonKatu opened this issue Jan 23, 2024 · 3 comments
Open

Traceid compatible brave #6168

JathonKatu opened this issue Jan 23, 2024 · 3 comments
Labels
Feature Request Suggest an idea for this project

Comments

@JathonKatu
Copy link

Describe the bug:
ihave a old application, it trace by brave , now time i will use opentelemetry on new application.
But the traceId String size is tooLong about old application use package.

Steps to reproduce
I have a old application use brave, maven coordinate is:
<dependency> <groupId>com.github.kristofa</groupId> <artifactId>brave-http</artifactId> <version>3.5.0</version> </dependency>
and i use opentelemetry maven coordinate is:
<dependency> <groupId>io.opentelemetry</groupId> <artifactId>opentelemetry-api</artifactId> <version>1.32.0</version> </dependency>

and it have "com.github.kristofa.brave.IdConversion#convertToLong" ,i use it convert String Type to Long Type.but it have a check param code
if (id.length() == 0 || id.length() > 16) { throw new NumberFormatException( id + " should be a <=16 character lower-hex string with no prefix"); }
but opentelemetry package:io.opentelemtry.api.trace.TraceId set traceId String.length = 32

how can i do this time...

i have no idea ,pls help me

@JathonKatu JathonKatu added the Feature Request Suggest an idea for this project label Jan 23, 2024
@JathonKatu
Copy link
Author

worry pls help me

@JathonKatu
Copy link
Author

my old application trace is use zipkin

@breedx-splk
Copy link
Contributor

OpenTelemetry uses 16-byte trace IDs and 8 byte span IDs, which is consistent with the w3c trace context format for its default trace context propagation mechanism.

If you are using the OTel java api/sdk and wish to send traces using B3 context propagation, you can leverage the B3Propagator.

The version of Brave you are using is quite ancient (~8 years old, predates the OpenTelemetry project). 😁

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature Request Suggest an idea for this project
Projects
None yet
Development

No branches or pull requests

2 participants