Open Sam-Kruglov opened 5 years ago
@pavolloffay any input on this?
The OpenTracing API 0.32.0 added getters for trace/span IDs so now it should be doable. However we haven't implemented it yet. It will be done as part of this ticket https://github.com/opentracing-contrib/java-spring-cloud/issues/92#issue-295123607
Feel free to submit a PR for it if you are interested.
We have done so by writing an interceptor which gets the trace and span IDs using opentracing api and add them to MDC.
We are soon going to remove the interceptor and use AOP instead
Regarding this issue https://stackoverflow.com/questions/51929412/add-jaeger-trace-id-and-span-id-to-log4j2-logs
I couldn't find any other way to do it. Would be better to use jaeger API directly, rather than through zipkin adapter