Get Current Context - OpenTelemetry Java #5313
Unanswered
Akrammousselmal
asked this question in
Q&A
Replies: 1 comment
-
The current context is accessible via A global |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
I currently have a service that runs automated instrumentation configured using ENV variable in java. I am now receiving traceParent/Tracestate from another service through pub/sub messaging and would like to create a new span using this context to enable distributed tracing for some transactions. My issue here is that we never used manual instrumentation with OpenTelemetry in this legacy project. (We are using version 0.15.0)
How can I get the current context/OpenTelemetry object without creating it from scratch like explained here https://opentelemetry.io/docs/instrumentation/java/manual/
I would have expected the auto-instrumentation to have some sort of a singleton when switching to both auto/manual instrumentation.
Beta Was this translation helpful? Give feedback.
All reactions