Observability & Performance
Learn to understand what a production system is doing, find the bottleneck, explain why it is slow, and prove that your change improved it. The goal is not to know monitoring tools — it is to stop guessing.
Your path through Observability & Performance
Start with these 5 lessons
Then follow the stages in order
Each stage builds on the ones before it. Labs and simulators sit right after the lessons they exercise. Open a stage to see its lessons. Full roadmap with goals →
Level 1 · Measure before you touch anything0 of 9 lessons done
- Observability Is Not a DashboardFoundation≈ 10 min
- Measure Before You OptimizeFoundation≈ 10 min
- From Symptom to Root CauseFoundation≈ 10 min
- Metrics, Logs, Traces, ProfilesFoundation≈ 10 min
- The Four Golden SignalsFoundation≈ 10 min
- RED: Rate, Errors, DurationFoundation≈ 10 min
- USE: Utilization, Saturation, ErrorsFoundation≈ 10 min
- Instrumentation: From Code to SignalFoundation≈ 10 min
- OpenTelemetry ConceptsFoundation≈ 10 min
Level 2 · Read the numbers honestly0 of 13 lessons done
- Four Metric Types, Four QuestionsFoundation≈ 10 min
- Counters: The Slope Is the SignalFoundation≈ 10 min
- Gauges: Blind Between ScrapesFoundation≈ 10 min
- Histograms: A Distribution You Can Afford to Keep ForeverFoundation≈ 15 min
- The Average Was Fine and Users Were NotFoundation≈ 10 min
- Percentiles: Which One, and How Many Users Is That?Foundation≈ 10 min
- Cardinality: The Label That Took Down MonitoringFoundation≈ 10 min
- Label Sets That Survive a YearFoundation≈ 10 min
- Structured Logging: Fields a Program Can ReadFoundation≈ 10 min
- Log Levels Are a Convention, Not a StandardFoundation≈ 10 min
- Correlation IDs: Turning Lines Into a StoryFoundation≈ 10 min
- What You Just Wrote Into a Log Half the Company Can ReadFoundation≈ 10 min
- The Log Bill and What It Is BuyingFoundation≈ 10 min
Level 3 · Find where the time goes0 of 14 lessons done
- Where the Request Actually WentFoundation≈ 15 min
- Trace, Span, Attribute, StatusFoundation≈ 10 min
- Parents, Children and LinksFoundation≈ 10 min
- Carrying the Trace Across the GapFoundation≈ 10 min
- Reading the WaterfallFoundation≈ 10 min
- The Critical Path Is the Only Path That PaysFoundation≈ 10 min
- The Comb: N+1 as a Visible ShapeFoundation≈ 10 min
- Sampling Without Throwing Away the EvidenceFoundation≈ 10 min
- When the Trace Runs Out of AnswersFoundation≈ 10 min
- Self Time, Total Time, and Where the CPU WentFoundation≈ 10 min
- Reading a Flame GraphFoundation≈ 15 min
- Allocation Rate Is a Cost Even Without a LeakFoundation≈ 10 min
- Computing or Waiting?Foundation≈ 10 min
- Always-On Profiling, and the Diff That Finds RegressionsFoundation≈ 10 min
Level 4 · Understand why loaded systems get slow0 of 9 lessons done
- Latency Is a Distribution, Not a NumberIntermediate≈ 10 min
- Tail Latency: Why p50 Being Fine Does Not HelpIntermediate≈ 10 min
- Latency Budgets: Spending 200 Milliseconds on PurposeIntermediate≈ 15 min
- Throughput: The Number That Means Nothing Without a Latency BoundIntermediate≈ 10 min
- Little's Law as Working IntuitionIntermediate≈ 15 min
- Queueing: Why Systems Get Slow Before They Get BrokenIntermediate≈ 15 min
- Saturation: The Reading Utilization Cannot Give YouIntermediate≈ 10 min
- Concurrency Limits: An Unbounded Server Is a Slower ServerIntermediate≈ 10 min
- Timeouts: The Latency Contract Nobody Writes DownIntermediate≈ 10 min
Level 5 · Identify the constrained resource0 of 8 lessons done
- What "CPU Is At 60%" Actually MeansIntermediate≈ 10 min
- CPU Saturation: When Cores Become the QueueIntermediate≈ 10 min
- Algorithmic Cost in a Request HandlerIntermediate≈ 10 min
- Reading Memory: RSS, Heap, Working Set and the Number on Your DashboardIntermediate≈ 10 min
- Memory Leaks: Growth That Does Not Come BackIntermediate≈ 15 min
- Leak or Unbounded Cache? The Question That Picks the FixIntermediate≈ 10 min
- Disk and Storage: Latency, Throughput, IOPS and the fsync TaxIntermediate≈ 10 min
- Network Signals: Is It the Network, or the Service on the Other End?Intermediate≈ 10 min
Level 6 · Diagnose the data layer0 of 15 lessons done
- Which Signal Actually Means "The Database Is Slow"Intermediate≈ 10 min
- The Slow Query WorkflowIntermediate≈ 15 min
- An Index Scan Is Not Automatically FasterIntermediate≈ 10 min
- When the Join Strategy Is the BottleneckIntermediate≈ 10 min
- Low CPU, High Latency: Lock ContentionIntermediate≈ 10 min
- Connection Pool Saturation: Waiting in Front of an Idle DatabaseIntermediate≈ 10 min
- Replication Lag: Reads That Are Correct and StaleIntermediate≈ 10 min
- A 95% Hit Rate Tells You Almost NothingIntermediate≈ 10 min
- Cache Stampede: Everyone Misses at OnceIntermediate≈ 15 min
- Hot Keys: When Aggregate Metrics Hide a Saturated NodeIntermediate≈ 10 min
- Six Queue Signals, Two That Wake You UpIntermediate≈ 15 min
- The Backlog Arithmetic: Four Levers and a Drain TimeIntermediate≈ 10 min
- Depth Is Not an Emergency; Age IsIntermediate≈ 10 min
- Retry Storms: The Load You Generated YourselfIntermediate≈ 10 min
- Twenty Workers, All Busy, Five Hundred WaitingIntermediate≈ 10 min
Level 7 · Know your runtime and your users0 of 12 lessons done
- Garbage Collection: Pause, Throughput, Footprint — Pick TwoAdvanced≈ 15 min
- Event-Loop Lag: One Callback, Everybody WaitsAdvanced≈ 10 min
- JavaScript Runtime Performance: V8 Where It CostsAdvanced≈ 10 min
- CPython Performance: The Interpreter Tax and the GILAdvanced≈ 10 min
- C++ Memory Performance: Allocation, Copies and LocalityAdvanced≈ 10 min
- JIT and Warm-Up: The First Thousand Requests Are a Different ProgramAdvanced≈ 10 min
- The Half of the Budget You Cannot See From the ServerAdvanced≈ 10 min
- Core Web Vitals as Signals, Not ScoresAdvanced≈ 10 min
- Reading the Browser WaterfallAdvanced≈ 10 min
- JavaScript Costs Four Times, Not OnceAdvanced≈ 10 min
- Images: The Largest Bytes, Rarely the Largest BlockAdvanced≈ 10 min
- Layout, Paint and the Main ThreadAdvanced≈ 10 min
Level 8 · Produce numbers that mean something0 of 13 lessons done
- Load Testing: What Question Is This Test Answering?Advanced≈ 10 min
- Load Test Shapes: The Shape Is the HypothesisAdvanced≈ 10 min
- Coordinated Omission: When the Load Generator LiesAdvanced≈ 10 min
- Benchmarking: Does This Number Answer My Question?Advanced≈ 10 min
- Benchmark Fallacies: Confident Numbers That Are WrongAdvanced≈ 10 min
- Microbenchmark or End-to-End: Why p99 Did Not MoveAdvanced≈ 10 min
- Regression or Tuesday? Telling a Real Change from NoiseAdvanced≈ 10 min
- Capacity Planning: Traffic to MachinesAdvanced≈ 15 min
- Headroom: The Capacity You Deliberately Do Not UseAdvanced≈ 10 min
- Autoscaling: Scaling on the Right SignalAdvanced≈ 10 min
- Autoscaling Lag: The Gap Where the Outage LivesAdvanced≈ 10 min
- Cost per Request: The Other Performance MetricAdvanced≈ 10 min
- Capacity or Efficiency: Which Problem Are You Solving?Advanced≈ 10 min
Level 9 · Run it in production, at scale0 of 26 lessons done
- SLIs: Measuring What the User Actually FeelsAdvanced≈ 10 min
- SLOs: A Target, a Window, and a ReasonAdvanced≈ 15 min
- SLAs: The Promise With Money AttachedAdvanced≈ 10 min
- Error Budgets: Unreliability You Are Allowed to SpendAdvanced≈ 10 min
- Alerts Worth Waking Someone ForAdvanced≈ 10 min
- Alert Fatigue: The Page Nobody ReadsAdvanced≈ 10 min
- Burn-Rate Alerts: How Fast Is the Budget Going?Advanced≈ 10 min
- Dashboards Built Around QuestionsAdvanced≈ 10 min
- What Changes When Work Crosses a MachineAdvanced≈ 10 min
- Fan-Out: Waiting for the Slowest of SevenAdvanced≈ 10 min
- Sequential or Parallel: Same Work, Different LatencyAdvanced≈ 10 min
- Cross-Region Latency Is Physics, Not ConfigurationAdvanced≈ 10 min
- Packet Loss Buys You a Timeout, Not a RetransmitAdvanced≈ 10 min
- Agreement Costs Round TripsAdvanced≈ 10 min
- Debugging an Incident in ProgressAdvanced≈ 10 min
- Correlation Is Not the Root CauseAdvanced≈ 10 min
- Reading a Timeline: Observation Order Is Not Causal OrderAdvanced≈ 10 min
- "What Changed?" — Deploy Markers and the Invisible DeploysAdvanced≈ 10 min
- The Bottleneck Moves After Every FixAdvanced≈ 15 min
- Every Optimization Buys Something and Sells SomethingAdvanced≈ 10 min
- Performance and Observability Anti-PatternsAdvanced≈ 10 min
- Where an Agent Run Actually Spends Its TimeAdvanced≈ 10 min
- Inside One Model Call: Queue, First Token, GenerationAdvanced≈ 10 min
- Reading an Agent Run as a TraceAdvanced≈ 15 min
- What One Agent Run Costs, and Which Term DominatesAdvanced≈ 10 min
- The Agent Returned 200 OK and the Answer Was WrongAdvanced≈ 10 min
What are you trying to diagnose?
Split request duration by endpoint and compare p50 against p99. One number for "the API" is not a measurement — it is an average over things that have nothing to do with each other.
The diagnostic loop
Every lesson and every lab returns to this chain. A fix that skipped a step is a guess that happened to work — or, more often, a guess that did not.
Flagship experiences
Learn → observe → measure → trace → profile → diagnose → optimize → validate → break → debug.
One 2.4-second checkout, peeled apart layer by layer until the bottleneck is exposed — then choose between five plausible fixes, only one of which addresses it.
A simulator with traffic, CPU, cache, pool, workers and retries. Find the knee, watch the bottleneck move, and cause a retry storm on purpose.
"Why is my system slow?" as a decision tree over measurements you can actually take, ending in a constraint and how to confirm it.
Six production incidents with timelines and evidence you pull up one item at a time. The first thing anyone noticed is never the cause.
Size a fleet from stated assumptions, then pick the load-test shape that answers the question you actually have.
Twelve sets of signals with no labels. Read the evidence, name the constraint, then check your reasoning against the path.
Learning modules
Understanding internal behavior from external signals. The measure-before-optimizing loop, what each signal type is actually good at, the golden signals, RED and USE, and how instrumentation reaches a backend at all.
Counters, gauges and histograms as different questions. Why the average hides the outage, how to read p50 against p99, and why a user id in a metric label can take down the monitoring system.
Discrete events with enough context to reconstruct a failure: structured fields over prose, levels that mean something, correlation ids that survive every hop, and the secrets that must never reach log storage.
Where a request spends its time across services. Spans and their relationships, context propagation through queues, the waterfall view, critical-path reasoning, and N+1 as a visible shape.
Where cost goes inside one process. CPU and allocation profiles, reading a flame graph without fooling yourself, and the CPU-bound versus I/O-bound distinction that decides which fix can possibly work.
The physics of a loaded system: tail latency, latency budgets, Little's Law as working intuition, why queueing makes systems slow long before they fail, and what saturation actually means.
The four resources a process competes for, the signal that identifies each as the constraint, and the difference between a memory leak and a cache nobody bounded.
Diagnosing the storage layer from the outside: slow-query workflow, scan versus index, lock waits with idle CPU, pool saturation, replication lag, hit rates that lie, stampedes and hot keys.
Arrival rate against service rate, why depth alone is the wrong alarm, oldest-message age as the honest signal, retry storms that feed themselves, and worker pools that saturate quietly.
Garbage collection, event-loop lag, interpreter overhead, allocation cost and warm-up — labelled per runtime, because none of this generalizes across JS, Python, Go, the JVM and C++.
The user's half of the latency budget: the browser waterfall, Core Web Vitals as user-experience signals, JavaScript cost beyond bytes, images, and layout work that blocks the first paint.
What changes when the work crosses machines: fan-out and tail amplification, sequential versus parallel dependency calls, cross-region propagation delay, jitter, and the cost of coordination.
How much load the system can take, how much headroom is left, whether autoscaling arrives in time, and what a request actually costs — capacity and efficiency as separate questions.
Producing numbers that mean something: load-test shapes, coordinated omission, benchmark hygiene, microbenchmark versus end-to-end, and telling a real regression from noise.
Turning user experience into a measurable objective: SLIs, SLOs and SLAs kept distinct, error budgets as a decision tool, alerts worth waking up for, burn rates, and dashboards built around questions.
Evidence-based diagnosis under pressure: reading a timeline, separating correlation from causation, watching the bottleneck move after every fix, and the trade-offs that make a system faster but worse.
The newest latency budget: time to first token, tool-call chains, step counts, retries and context size — where agent latency, cost and quality trade against each other.
Every number here is labelled
§163 — performance is workload-, runtime- and environment-sensitive, so a figure without conditions is folklore.
A real published measurement, with its conditions named.
Arithmetic from stated assumptions. Change one and the number changes.
Produced by a model in this app. Right shape, invented magnitudes.
Invented to teach a shape. The relationship is the lesson, not the number.
Simulated output is never presented as measurement. Runtime-, engine- and web-specific claims say which runtime, which engine, which platform — because "Python is slow" and "CPython's interpreter dispatch costs more per bytecode than a JIT" are not the same statement, and only one of them is useful.