A Worked Postmortem
This lesson walks through one fictional incident from raw timeline to finished postmortem, using the template from Blameless Postmortems. The service is the checkout from the earlier lessons: SLO 99.9% over 28 days, about 2.5 million requests a day.
The raw timeline
The scribe's log and the tools' timestamps are the raw material. The model turns them into the durations every postmortem reports, and the error budget the incident consumed:
EVENTS = [ # time (UTC), kind, text
("09:12", "change", "payment-client v3.8.0 rolled out to all regions (canary skipped: hotfix label)"),
("09:14", "impact", "checkout 5xx starts rising in eu-west and us-east"),
("09:23", "detect", "CheckoutErrorBudgetBurn page fires (1h/5m rule)"),
("09:27", "ack", "on-call (S. Park) acknowledges"),
("09:35", "declare", "SEV-2 declared, S. Park IC; M. Rossi ops lead"),
("09:48", "decide", "rollback of payment-client decided"),
("10:06", "mitigate", "rollback complete, error ratio back below 0.1%"),
("11:30", "resolve", "fix for connection-pool config merged and verified on canary"),
]
FAILED = {"09:14-10:06": 0.11} # share of checkout requests failing during the impact window
REQ_PER_MIN = 2_500_000 / (24 * 60)
BUDGET = 0.001 * 2_500_000 * 28
def minutes(hhmm):
h, m = map(int, hhmm.split(":"))
return h * 60 + m
t = {kind: minutes(ts) for ts, kind, _ in EVENTS}
print(f"time to detect (impact -> page) {t['detect'] - t['impact']:>3} min")
print(f"time to engage (page -> ack) {t['ack'] - t['detect']:>3} min")
print(f"time to mitigate (impact -> mitigated) {t['mitigate'] - t['impact']:>3} min")
print(f"time to resolve (impact -> resolved) {t['resolve'] - t['impact']:>3} min")
print(f"decision to roll back after the page {t['decide'] - t['detect']:>3} min, rollback took {t['mitigate'] - t['decide']} min")
impact_min = t["mitigate"] - t["impact"]
failed = impact_min * REQ_PER_MIN * FAILED["09:14-10:06"]
print(f"failed checkouts ~{failed:,.0f}; error budget used {failed / BUDGET:.0%} of 28 days")time to detect (impact -> page) 9 min
time to engage (page -> ack) 4 min
time to mitigate (impact -> mitigated) 52 min
time to resolve (impact -> resolved) 136 min
decision to roll back after the page 25 min, rollback took 18 min
failed checkouts ~9,931; error budget used 14% of 28 days
The numbers already point at the story: detection was reasonable (9 minutes), but it took 25 minutes from page to a rollback decision, and the rollback itself took 18 minutes. A single incident used 14% of the 28-day budget, and as a SEV-2 it requires a postmortem (Severity Levels).
The finished postmortem
# Postmortem: checkout failures after payment-client 3.8.0 (INC-2047)
**Status:** final **Owner:** S. Park **Date of incident:** 2026-03-09
**Authors:** S. Park, M. Rossi **Reviewers:** payments team, SRE **Severity:** SEV-2
## Summary
For 52 minutes on 2026-03-09, about 11% of checkout attempts in all regions failed with "Payment could not be
completed". A new version of the payment client reduced its connection pool from 50 to 5 connections per pod
through a changed default; under morning load, requests waited for a connection and timed out. Rolling back
the client restored service; the pool size is now set explicitly.
## Impact
- 09:14–10:06 UTC, all regions; ~9,900 failed checkout attempts (~11% of attempts in the window).
- 14% of the 28-day error budget for checkout availability.
- 212 support contacts; no data loss; customers could retry (most retries succeeded).
## Timeline (UTC)
| Time | Event |
|---|---|
| 09:12 | payment-client 3.8.0 deployed to all regions with the `hotfix` label, which skips the canary |
| 09:14 | 5xx ratio starts rising |
| 09:23 | CheckoutErrorBudgetBurn (1 h / 5 min) pages the on-call |
| 09:27 | on-call acknowledges, starts investigating database metrics (DB had a failover the day before) |
| 09:35 | SEV-2 declared; S. Park IC, M. Rossi ops lead |
| 09:44 | ops lead notices the errors began 2 minutes after the payment-client deploy |
| 09:48 | rollback decided |
| 09:51–10:06 | rollback: requires the pipeline's manual approval; approver reached at 09:58 |
| 10:06 | error ratio below 0.1%; incident mitigated |
| 11:30 | pool size set explicitly to 50, verified on canary, incident resolved |
## Detection, response and recovery
The burn-rate page fired 9 minutes after impact began, as designed for an 11% error ratio. Response was slowed
by a plausible but wrong lead (the previous day's DB failover) and because the deploy was not visible on the
checkout dashboard. The rollback needed the same manual approval as a forward deploy.
## Contributing factors
1. The client library changed a default (`max_connections` 50 → 5) in a minor release; the change was in the
changelog but not flagged as behaviour-changing.
2. The `hotfix` label skipped the canary for a change that was not a hotfix (it bundled a dependency update).
3. Deploys were not annotated on the SLO dashboard, so the correlation took 17 minutes to spot.
4. Rollback required a manual approval designed for forward deploys.
## What went well
- The burn-rate alert fired at the expected time and linked to a runbook.
- Clear IC and ops-lead roles once declared; status updates every 30 minutes.
## What went badly
- 8 minutes from acknowledgement to declaration; investigating alone first.
- The first hypothesis was anchored on yesterday's incident.
## Where we got lucky
- The failure was partial; retries mostly worked. With a pool of 1, checkout would have been down entirely.
## Action items
| Action | Type | Priority | Owner | Ticket | Due |
|---|---|---|---|---|---|
| Set pool size and timeouts explicitly in our config; fail CI if a library default changes them | prevent | P1 | S. Park | PAY-912 | 2026-03-16 |
| `hotfix` label requires a second approver and still runs a 5-minute canary | prevent | P1 | M. Rossi | REL-233 | 2026-03-20 |
| Deploy annotations on all SLO dashboards (Grafana annotations from the CD tool) | detect | P2 | P. Shah | OBS-118 | 2026-03-27 |
| Rollback to the previous release without manual approval | mitigate | P1 | M. Rossi | REL-234 | 2026-03-20 |
| Add "what changed in the last hour?" as step 1 of the checkout runbook | process | P2 | S. Park | PAY-913 | 2026-03-13 |
## Lessons learned
"Check recent changes first" beats "check the last thing that broke". Making the rollback path at least as fast as
the deploy path is the cheapest reliability work we have.Measuring incidents over time
Teams often report MTTR (mean time to restore) across all incidents. Be careful with means: incident durations have a long tail, so one long incident dominates the average and a quarter can look "worse" or "better" by chance. The model draws incident durations from a seeded long-tailed distribution and compares two quarters run by the same team with the same skill:
import random
import statistics
rng = random.Random(4)
def quarter(n=12):
return sorted(round(rng.lognormvariate(3.4, 1.0)) for _ in range(n)) # minutes to mitigate
for name in ("Q1", "Q2"):
d = quarter()
print(f"{name}: mean {statistics.mean(d):5.1f} min median {statistics.median(d):5.1f} min "
f"longest {d[-1]:>3} min durations {d}")Q1: mean 66.4 min median 29.5 min longest 463 min durations [9, 12, 16, 18, 24, 29, 30, 33, 52, 54, 57, 463]
Q2: mean 34.8 min median 26.5 min longest 155 min durations [11, 11, 13, 13, 15, 25, 28, 31, 34, 40, 41, 155]
Same team, same process, yet one quarter's mean is almost double the other's while the medians are close: the difference is mostly the single longest incident. Report medians and percentiles, look at individual incidents, and prefer measures you can act on: the detection time of burn-rate alerts, how long declaration and rollback take, and action items completed. DORA's "failed deployment recovery time" (DORA Metrics) has the same caveat.
Test yourself
In the worked example, which phase took longest between the page and mitigation?
- Detection
- Deciding to roll back (25 min) and the rollback itself (18 min)
- Acknowledging the page
- Writing the status update
Why is 'the developer changed the pool size' not listed as a contributing factor?
- Because nobody changed it on purpose: a library default changed, and the process let that through unnoticed
- Because it was the root cause
- Because postmortems don't list causes
- It is listed
Why can MTTR swing between quarters for the same team?
- Teams forget skills
- Incident durations are long-tailed, so a single long incident dominates the mean
- MTTR is always random
- Because of the SLO window