Connect logs and traces
Logs and traces correlate through stable identifiers, not approximate timestamps alone. Keep the relevant request and span identifiers in diagnostic events.
Understand the pattern
Logs and traces correlate through stable identifiers, not approximate timestamps alone. Keep the relevant request and span identifiers in diagnostic events.
Interpret the evidence
Join the log and trace for req-14 rather than the unrelated req-99 event.
A tempting mistake
Timestamp proximity is enough to join every log to a trace.
All names, measurements, prices, versions, and thresholds in this exercise are fictional training data. The evidence supports this bounded scenario, not a claim about a live provider.
Worked example and expected result
$ cat /opt/ai-lab/cases/aiops-observability-tracing-008.json{
"fixture": "Fictional training data; not a live measurement.",
"log_request_id": "req-14",
"trace_request_id": "req-14",
"other_log_id": "req-99"
}Exit status: 0. The command completed successfully in the training fixture.
$ jq .log_request_id /opt/ai-lab/cases/aiops-observability-tracing-008.json"req-14"
Exit status: 0. The command completed successfully in the training fixture.
$ printf '%s\n' 'join-req-14' > /home/learner/lab/aiops-observability-tracing-008-decision.txt(no output; exit 0)
Exit status: 0. The command completed successfully in the training fixture.
Explain it
Apply it elsewhere
Keep the momentum.
Complete the lab, then explain and apply the pattern.
Next: Inspect token metricsTry an incident drillAnonymous lesson and mastery progress lasts for this session. Sign in to keep synced lesson XP between sessions; mastery stays device-local. No speed bonus, lost lives, or hint penalties.
Keep learning
- 01Find a slow spanCompare span duration with the total trace and distinguish sequential from overlapping work. A long span is a starting point for investigation, not automatic proof of CPU saturation.Practice
- 02Inspect token metricsToken metrics help distinguish input growth from output growth. A cost or latency increase can follow a longer context even when the response length remains stable.Practice
- 03Review model saturationSaturation combines utilization, queueing and service time. High utilization without queue growth can mean useful work; a growing queue gives the observation operational context.Practice