-
Notifications
You must be signed in to change notification settings - Fork 1.4k
tracing: fix buildx tracing delegation #3909
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
Conversation
before this change, the threadsafe wrapper would hide the delegate interface, which breaks the ability to send traces. after this change, tracing works again! fixes docker/buildx#1847 Signed-off-by: Nick Santos <[email protected]>
util/tracing/detect/threadsafe.go
Outdated
| } | ||
|
|
||
| func makeThreadSafe(exp sdktrace.SpanExporter) sdktrace.SpanExporter { | ||
| d, isDelegate := exp.(tracerDelegate) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe this should detect the *jaeger.Exporter instead and only make that thread-safe. Delegated exporter is already thread-safe.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Or actually just wrap it in jaegerExporter(), not in the detect pkg.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ya, maybe the real solution is to complain upstream about the jaeger exporter not being thread-safe. in any case, i moved this code into the jaeger package.
|
@jedevc We need to take this into v0.11 buildx |
Signed-off-by: Nick Santos <[email protected]>
do we need this for the 0.11 branch as well, for the docker builder? |
|
@thaJeztah |
|
@tonistiigi ah, gotcha. Disclaimer: haven't fully followed all things, but I knew @milas was working on OTEL support (which I expect would also be for the "docker" builder), hence wondering if this would be related (and needed). |
before this change, the threadsafe wrapper would hide the delegate interface, which breaks the ability
to send traces.
after this change, tracing works again!
fixes docker/buildx#1847