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

Add TCK #278

Open pavolloffay opened 6 years ago

pavolloffay commented 6 years ago

Implement TCK to verify correct tracer behavior.

The motivation is for example to avoid issues like https://github.com/opentracing/opentracing-java/issues/267#issuecomment-392853823. For example brave-ot implements OpenTracing but SpanManager.active().close() is noop.

yurishkuro commented 6 years ago

TCK?

pavolloffay commented 6 years ago

A Technology Compatibility Kit (TCK) is a suite of tests that at least nominally checks a particular alleged implementation of a Java Specification Request (JSR) for compliance.

Test suite to verify correct tracer implementation.

carlosalberto commented 6 years ago

Guess that's something similar to the harness submodule/test we have in Python, so implementations of Tracer/ScopeManager can be verified against the expected behavior. That would definitely be handy - and also something that could help us specification-wise ;)

codefromthecrypt commented 6 years ago

It would likely need to be far more specific than the harness in python or the go port which is not much more than a compile test.

Since OpenTracing doesn't provide a stable implementation, yet expects people to use unknown implementations, the TCK should be more strict like https://github.com/reactive-streams/reactive-streams-jvm/tree/master/tck

For example, it should verify things such as thread behavior. Even better to ensure the tracer doesn't block or becomes unloadable due to implementation problems. Most importantly, the features supported should be verifiable. For example, baggage, KV logging, etc.

This may be tricky for agents because very few will be using opentracing underneath, or exposing a "native" opentracer. This could imply some setup interest for example a runner that can affect the JVM launch parameters.

Above all, please engage the reactive streams TCK designers especially those who directly or indirectly support OT as they not only know how to do this, but probably their experience cost a long time to accrue.. IOTW, this should be done in a serious fashion by experts or by expert advice.