You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by GitBox <gi...@apache.org> on 2021/06/18 21:12:49 UTC
[GitHub] [camel-quarkus] christian-morin commented on issue #2802: Ability to retrieve traceId for observability in routes
christian-morin commented on issue #2802:
URL: https://github.com/apache/camel-quarkus/issues/2802#issuecomment-863991230
Yes, that worked! The context on my OpenTracingSpanAdapter didn't have a toTraceId() method though, but casting the Span to a JaegerSpan made me able to retrieve it.
```
OpenTracingSpanAdapter adapter = (OpenTracingSpanAdapter) ActiveSpanManager.getSpan(exchange);
JaegerSpanContext spanCtx = ((JaegerSpan)adapter.getOpenTracingSpan()).context();
System.out.println("=======>" + spanCtx.getTraceId());
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org