opentracing / opentracing-java

OpenTracing API for Java. 🛑 This library is DEPRECATED! https://github.com/opentracing/specification/issues/163
http://opentracing.io
Apache License 2.0
1.68k stars 344 forks source link

Overriding timestamp on spans #366

Closed devinbost closed 4 years ago

devinbost commented 4 years ago

We're building a messaging system where we have messages containing timestamps that need to be reported to Jaeger via OpenTracing. Is there a way to override the timestamps on a Span so that the timestamps aren't hardcoded to when the spans are started or ended but instead can represent the timestamps expressed on the messages?

whiskeysierra commented 4 years ago

Would Jaeger even support that?

yurishkuro commented 4 years ago

https://github.com/opentracing/opentracing-java/blob/2df2a8983e35dff23c4fb894e5f5ae3f98f1cf7b/opentracing-api/src/main/java/io/opentracing/Tracer.java#L195-L196

https://github.com/opentracing/opentracing-java/blob/2df2a8983e35dff23c4fb894e5f5ae3f98f1cf7b/opentracing-api/src/main/java/io/opentracing/Span.java#L167

devinbost commented 4 years ago

@yurishkuro You rock. Thanks!