grafana / loki

Like Prometheus, but for logs.
https://grafana.com/loki
GNU Affero General Public License v3.0
23.29k stars 3.38k forks source link

tracing: Jaeger/Opentracing are deprecated, use open-telemetry for instrumentation instead #6812

Open kavirajk opened 2 years ago

kavirajk commented 2 years ago

Currently Loki is instrumented with opentracing/jaeger client libraries for tracing.

This instrumentation comes from weaveworks/common package and dskit's spanlogger package.

Those client libraries(opentracing, jaeger) are deprecated in the favor of opentelemetry client sdk. It's better to migrate.

I hope, It should be completely possible to migrate underlying dependencies without changing any API of those packages.

Example of using otel tracing client libraries for instrumentation in Go is here.

mateuszdrab commented 1 year ago

Looking forward to see this implemented, I realized that Grafana sends trace headers in w3c format to Loki which it can't support due to the feature not being implemented in the jaeger libraries. OCD was triggered as I wanted Grafana, Loki and Thanos to all support tracing.

davidspek commented 3 months ago

Just wanted to note that weaveworks/common isn't being used anymore and that https://github.com/grafana/dskit/pull/385 is the PR needed to migrate to OTEL.