Mapping Span Names between Client/Service & Parent/Child spans #3616
Replies: 2 comments 4 replies
-
A follow up here: I was reading this PR: https://github.com/grafana/tempo/pull/3453/files and I am wondering if this is trying to solve a similar problem as I am describing above? It sounds to me like this would introduce a metric representing latency between services? |
Beta Was this translation helpful? Give feedback.
-
This had not occurred to me before, but there are cases where it would be difficult to match up a client and server span. I do think the PR you linked will give you a tool to answer the questions that you have. I will do my best to give it a final review to day. cc @adirmatzkin |
Beta Was this translation helpful? Give feedback.
-
Hi! I have a tempo service setup with the metrics-generator enabled, and I have been pretty impressed with what this can do
Rambling
However, I noticed a lot of the instrumentation for outbound HTTP requests typically does not include the request path in the span name, since to the client making that request its just some string (so technically cannot be accurately parameterized). Generally on the server receiving this request, I see those span names do tend to include a parameterized request path in the span name.
I've found it to be extremely valuable to correlate these two spans, so that I can compare the response time as reported by server vs client.
To work around this, I am trying to use some regex/string manipulation to be clever enough to include at least some info in the outbound requests span name, which is OK, but the Tempo-specific question I have is:
Question
Is it possible in Tempo to map the span name of a SERVER type span to the corresponding CLIENT type span, provided the SERVER span is the first child of the CLIENT span? I realize we would need to be pretty opinionated about how we decide if its OK to map these (http.route vs http.path vs http.target etc), but I find these server-server request comparisons to yield some pretty interesting stats
Example
Basically I am trying to make it easier to hone in on problems like these (durations are arbitrary here):
{ kind=client && duration > 500ms } > { kind=server && duration < 500ms}
Beta Was this translation helpful? Give feedback.
All reactions