Architecture & Patterns: Observability + Tracing¶
Production Patterns¶
Architecture View¶
graph LR
A[Request ID] --> B[Step traces]
B --> C[Latency and cost metrics]
C --> D[SLO dashboard]
D --> E[Alert policy]
Common Failure Modes¶
Common Failure Modes¶
- Missing request-id propagation across steps.
- Logging totals only without per-step detail.
- Alert thresholds not tied to business impact.
Interview Q&A¶
Q: Interview Q: What belongs in a minimum viable trace record?
Include request id, step name, duration, status, and error metadata. Cost estimates are also useful when model usage is significant.
Q: Interview Q: How do you set realistic SLO thresholds?
Start from user-facing latency targets, then align error budget to acceptable failure impact. Tune thresholds using historical distributions.