-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
[OpenTracing Bridge] Support setting span kind tag after span is created #3953
Labels
enhancement
New feature or request
Comments
Hi, can I pick this up if this request makes sense? |
The workaround when sources can be changed is to specify span kind tag on creation which works for both Open Tracing and Open Telemetry bridge spans: opts := []ot.StartSpanOption{ot.Tags{
"span.kind": "client",
// etc
}}
if parentSpan := ot.SpanFromContext(req.Context()); parentSpan != nil {
opts = append(opts, ot.ChildOf(parentSpan.Context()))
}
span := tracer.StartSpan(spanName, opts...) |
AlexanderYastrebov
added a commit
to zalando/skipper
that referenced
this issue
Apr 24, 2024
OpenTelemetry-OpenTracing bridge span kind can not be changed after creation, see open-telemetry/opentelemetry-go#3953 The workaround is to specify span kind on creation which works for both Open Tracing and Open Telemetry bridge spans. For #2104 Signed-off-by: Alexander Yastrebov <[email protected]>
AlexanderYastrebov
added a commit
to zalando/skipper
that referenced
this issue
Apr 24, 2024
OpenTelemetry-OpenTracing bridge span kind can not be changed after creation, see open-telemetry/opentelemetry-go#3953 The workaround is to specify span kind on creation which works for both Open Tracing and Open Telemetry bridge spans. For #2104 Signed-off-by: Alexander Yastrebov <[email protected]>
AlexanderYastrebov
added a commit
to zalando/skipper
that referenced
this issue
Apr 24, 2024
OpenTelemetry-OpenTracing bridge span kind can not be changed after creation, see open-telemetry/opentelemetry-go#3953 The workaround is to specify span kind on creation which works for both Open Tracing and Open Telemetry bridge spans. For #2104 Signed-off-by: Alexander Yastrebov <[email protected]>
AlexanderYastrebov
added a commit
to zalando/skipper
that referenced
this issue
Apr 26, 2024
OpenTelemetry-OpenTracing bridge span kind can not be changed after creation, see open-telemetry/opentelemetry-go#3953 The workaround is to specify span kind on creation which works for both Open Tracing and Open Telemetry bridge spans. For #2104 Signed-off-by: Alexander Yastrebov <[email protected]>
AlexanderYastrebov
added a commit
to zalando/skipper
that referenced
this issue
Apr 26, 2024
OpenTelemetry-OpenTracing bridge span kind can not be changed after creation, see open-telemetry/opentelemetry-go#3953 The workaround is to specify span kind on creation which works for both Open Tracing and Open Telemetry bridge spans. For #2104 Signed-off-by: Alexander Yastrebov <[email protected]>
AlexanderYastrebov
added a commit
to zalando/skipper
that referenced
this issue
Apr 26, 2024
OpenTelemetry-OpenTracing bridge span kind can not be changed after creation, see open-telemetry/opentelemetry-go#3953 The workaround is to specify span kind on creation which works for both Open Tracing and Open Telemetry bridge spans. Note that this change removes non-standard "shedder" kind from spans created by `admissionControl` filter. Use operation name "admission_control" to query its spans instead if needed. For #2104 Signed-off-by: Alexander Yastrebov <[email protected]>
JanardhanSharma
pushed a commit
to JanardhanSharma/skipper
that referenced
this issue
Apr 26, 2024
OpenTelemetry-OpenTracing bridge span kind can not be changed after creation, see open-telemetry/opentelemetry-go#3953 The workaround is to specify span kind on creation which works for both Open Tracing and Open Telemetry bridge spans. Note that this change removes non-standard "shedder" kind from spans created by `admissionControl` filter. Use operation name "admission_control" to query its spans instead if needed. For zalando#2104 Signed-off-by: Alexander Yastrebov <[email protected]> Signed-off-by: Janardhan Sharma <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Problem Statement
Currently in OT Bridge, it does nothing when setting span kind tag.
opentelemetry-go/bridge/opentracing/bridge.go
Lines 158 to 170 in 271df1d
This cause some problem because the middle layers of some framework set span kind tag after a span is created, and we don't have control on those framework. Hence the spans are missing the span kind tag.
e.g. YAPRC: https://github.com/yarpc/yarpc-go/blob/600cb49cc6331d8d15f65c058615a7649447efa7/api/transport/propagation.go#L67
Is there any strong reason not to set span kind tags?
Proposed Solution
Support setting span kind tag.
The text was updated successfully, but these errors were encountered: