Closed rishabhc closed 2 years ago
We can use this instead - https://github.com/opentracing/lua-bridge-tracer And simply write the lua code to create the needed data for the tracer. It can be inside https://github.com/apache/trafficserver-ingress-controller/blob/master/pluginats/connect_redis.lua and called as part of the request handling mechanism. of course, tracing is optional, so we should have mechanism to allow us to turn it on and off.
pls make sure you use lua5.1 when building these opentracing libraries.
also I find that you need opentracing-cpp-1.5.1 & lua-bridge-tracer-0.1.1 to make it work . latest opentracing-cpp-1.6.0 does not work with lua-bridge-tracer yet.
I tried using jaeger-client-cpp 0.4.2 as the tracer for the above. It is hard to get them to work with ATS. It is because both ATS and jaeger-client-cpp is using YAML library and they don't work well together.
perhaps I should try to use zipkin or lightstep instead
I think I resolve the problem with using jaeger-client-cpp by opting to the plugin.so provided in the release.
I wrote a small example with instructions here to show how to integrate ATS with jaeger/opentracing/lua_bridge_tracer https://github.com/shukitchan/ats_lua_scripts/blob/master/tracer_example.lua
We should be moving to use opentelemetry instead now. I am working on this.
New plugin is added - https://github.com/apache/trafficserver/tree/master/plugins/experimental/otel_tracer
Once it is released, we can add updates here.
I mentioned this in issue #20. So jaeger by itself is incomplete. We will have to use opentracing apis for any traces to be generated which can then be managed using jaeger. To trace the requests going through ATS, we'll have to use the opentracing API with ATS. Something like this: https://github.com/opentracing-contrib/nginx-opentracing This is something that needs more discussion.