tower-rs / tower-http

HTTP specific Tower utilities.
707 stars 165 forks source link

`tower_http::trace` doc clarification regarding ingestion of parent spans from incoming requests #508

Open lcmgh opened 2 months ago

lcmgh commented 2 months ago

Does https://docs.rs/tower-http/latest/tower_http/trace/index.html also take care of ingesting the parent span/trace id from incoming requests to basically enable cross-service tracing?

That is not clear to me when reading the docs.

jplatte commented 2 months ago

No, it doesn't.

lcmgh commented 2 months ago

okay, that's probably why https://github.com/davidB/tracing-opentelemetry-instrumentation-sdk/tree/main/tonic-tracing-opentelemetry exists

What I understand is that tower_http::trace exists to get request/response traces and tonic-tracing-opentelemetry crate exists to get the span connection to parent trace ids from incoming requests and not to log request/Response data?