How would you use distributed tracing to debug a deployment latency issue?
This tests causal request-path analysis beyond aggregate metrics. A strong answer filters traces by the new version, finds the exact regressed span, and compares it to a pre-deployment baseline.
What's really being asked
This question probes whether you understand the observability signal hierarchy and when distributed tracing is the right tool for regression analysis. Metrics tell you that latency increased and logs tell you that something happened, but only traces let you follow a single causal request across service boundaries to find exactly where time was lost. The interviewer wants to see that you think in terms of request paths, not just dashboards.
The full answer
Four things in order. First, isolation: you narrow the investigation to the new deployment by filtering traces using deployment tags, version attributes, or timestamps aligned with the rollout. Second, localization: you identify the specific service and span where duration increased relative to a pre-deployment baseline, looking at span self-time versus child time to distinguish network latency from processing latency. Third, comparison: you explain that metrics only show aggregate percentiles and cannot isolate individual anomalous requests, while logs are uncoordinated events that lack timing context across services; traces provide the end-to-end waterfall view that connects both. Fourth, action: once the regressed span is found, you link it back to the code change, configuration diff, or downstream dependency introduced in the deployment.
The mistakes people make
Treating traces as just structured logs with trace IDs is a major red flag; it misses the parent-child timing relationships that make traces valuable. Another mistake is saying you would look at the P99 metric and then grep logs for errors, which ignores the fact that latency spikes often occur without errors. Some candidates also forget to mention baseline comparison, leaving no way to prove the new deployment caused the regression. Finally, confusing span self-time with total span time can lead to blaming the wrong service.
What usually comes next
How do you handle high-cardinality trace data in production without breaking the bank? What sampling strategy would you use if the latency issue only affects one in a thousand requests? How do you correlate traces with logs and metrics without context switching? Can you walk through a real trace waterfall and explain what each bar means?
A concrete example
Imagine a checkout service deploys at 14:00 and P99 latency jumps from 200 ms to 800 ms. Metrics show the spike but not the cause. Logs show no errors. Using distributed tracing, you filter for traces tagged with version 2.3.1 and find that every slow request spends 600 ms in the payment service authorization span. Comparing to a pre-deployment trace from version 2.3.0, that same span took 50 ms. You drill into the span attributes and see a new retry policy was added with an aggressive timeout. The trace gives you the exact line of code and the downstream impact, while metrics only alerted you and logs only confirmed the service received requests.
Interview question
When using distributed tracing to debug a deployment-related latency spike, which approach most effectively isolates the regressed component?
- a.Filter traces to the new deployment version, compare span durations against a pre-deployment baseline, and examine span self-time to distinguish processing delays from downstream latency.Correct
- b.Check the P99 latency metric for the affected service, then grep application logs for error messages occurring during the deployment window.
- c.Filter traces by the new version and identify which service shows the largest total span duration in the trace waterfall.
- d.Extract trace IDs from the deployment window and use them to correlate and sequence log entries across services.
Why? this is the answer
The correct approach isolates the new deployment, compares against a baseline to prove causation, and uses span self-time to pinpoint whether the delay is local or downstream. Option C is tempting because it correctly filters by version, but looking only at total span duration without a baseline or self-time analysis can incorrectly blame a parent service for a child's latency.
Just read this? Test yourself on what you have been reading.
Read the original → opentelemetry.io
- #observability
- #distributed-tracing
- #deployment
- #latency-debugging
- #sre
Put your scrolling time to good use
Learn one idea, try a quiz and save useful cards for revision. Tezvyn makes it easy to learn and stay current in your tech field, a few minutes at a time.
The iPhone app is on the way
We are building it. Until it lands, nothing here is held back from you: every interview card, your saved cards, streaks and the job board all work in Safari, plus hundreds of free practice quizzes of thirty questions each. Sign in and it all carries over to the app the day it arrives.
Want it as an icon? Tap Share at the bottom of Safari, then Add to Home Screen. It opens full screen and the cards you have read stay available offline.
We are hiring for this. Open roles that interview on observability — each one lists the topics its interview covers.
See open roles