Observability Monitoring And Incident Response
Deployment Success Verification And Watch Windows
A deploy is not done when the new code is running; it is done when you have confirmed the new code is working. Most production incidents are triggered by a change, which means the moments right after a deploy are the highest-risk window in the whole operational cycle — and the one where fast detection pays off most, because the cause is obvious (you just shipped) and the fix is at hand (roll back). This lesson is about closing the loop from "deployed" to "verified," and knowing quickly when to undo.
Verification Is Not "It Deployed"
"The deploy pipeline went green" means the code shipped, not that it works. Real verification checks behavior after the release:
- Smoke tests against production: a handful of automated checks — the health endpoint returns ready, the homepage loads, a critical API responds correctly, a synthetic login succeeds — run immediately post-deploy. These are the health and synthetic checks from the previous lesson, pointed at the freshly deployed release.
- Watch the golden signals for a regression: error rate, latency percentiles, and traffic, compared against the pre-deploy baseline. A deploy that doubles the error rate or the p99 is a failed deploy even if every smoke test passed, because smoke tests sample and metrics see everything.
- Confirm the version actually rolled out: the running release id matches what you shipped, on every instance — partial rollouts and cached old code are real failure modes.
The Watch Window
The watch window is a deliberate period after a deploy — typically 15 to 60 minutes — during which someone (or an automated watcher) actively watches the release's health before declaring success and moving on. It exists because many regressions do not appear instantly: a memory leak takes time to bite, a slow query only hurts under real load, an error only fires on a code path that a user reaches minutes later. Walking away the instant the pipeline goes green means discovering these from customer complaints an hour later instead of from your own dashboard at minute ten.
Practically, the watch window means: deploy, then keep the release's dashboard and error tracker in view (or have an automated canary analysis do it), with the person who shipped staying available to respond. The error tracker's release tagging earns its keep here — a spike of new errors tagged with the new release is the clearest possible "this deploy broke something" signal.
Progressive Delivery Shrinks The Blast Radius
You can make the watch window safer by exposing the new release to fewer users first:
- A canary sends a small fraction of traffic to the new release and compares its golden signals against the old one; if the canary's error rate or latency regresses, it is rolled back having affected only a few percent of users.
- Blue-green runs the new release alongside the old and switches traffic over once verified, keeping the old version warm for an instant rollback.
- Feature flags decouple deploy from release entirely: ship the code dark, then turn the feature on for a small cohort and widen gradually, with an off switch that needs no deploy.
All three serve the same goal — limit how many users a bad release can hurt, and make undoing it fast.
Rollback Is A First-Class Plan
The most important property of a deploy process is that it can be undone quickly. Define, before deploying, what "bad" looks like (error rate or latency crossing a threshold, smoke tests failing, the canary regressing) and what the rollback action is (revert to the previous release, flip the blue-green switch, kill the flag). Rollback should be a rehearsed one-command operation, not an improvisation invented during the incident — the same discipline the compromise playbooks apply to security, applied to deploys. A team that can roll back in two minutes can afford to ship often; a team that cannot treats every deploy as terrifying and ships rarely, which paradoxically makes each deploy bigger and riskier.
What To Check
Before moving on, make sure you can:
- explain why "the pipeline went green" is not deployment verification
- verify a release with smoke tests, golden-signal comparison, and version confirmation
- define a watch window and why regressions are often delayed
- describe canary, blue-green, and feature flags as blast-radius controls
- treat rollback as a pre-defined, rehearsed, one-command plan
What You Should Be Able To Do
After this lesson, you should be able to define what "verified" means for a deploy, run a watch window that catches delayed regressions, use progressive delivery to limit a bad release's reach, and make rollback a fast, rehearsed action rather than a panic.
Practice
Practice: Design Deploy Verification
Show solution
Watch window: a 30-minute period during which the release's dashboard (golden signals compared to the pre-deploy baseline) and the error tracker (filtered to the new release tag) are actively watched — by automated canary analysis where available, with the deploying engineer staying available. The window exists because leak/slow-query/rare-path regressions surface minutes later, not instantly.
Progressive delivery: a canary sends ~5% of traffic to the new release first; its error rate and p99 are compared to the stable release automatically, and it only widens to 100% after passing. Risky features additionally ship behind a flag, enabled for a small cohort before full rollout, so deploy and release are decoupled.
Rollback: defined before deploying. "Bad" = smoke test failure, canary error-rate or latency regression beyond threshold, or a new-release error spike in the tracker. Action = one command to revert to the previous release (kept warm), or flip the feature flag off, no redeploy required. It is rehearsed so it is a two-minute reflex, not an improvisation.
The net effect: several-times-daily deploys are safe because each is verified, watched, limited in blast radius, and instantly reversible.
Practice: Diagnose A Bad Deploy Gone Long
A Friday afternoon deploy passed CI and the team went home. A memory leak in the new release degraded the app over three hours; by evening, servers were OOM-killing and users saw errors. Nobody noticed until customer complaints. Rolling back took 40 minutes because nobody remembered the previous version or the process.
Task
Diagnose every process failure and what should have happened.
Show solution
The deploy was treated as finished when the pipeline went green, and every subsequent failure flows from that.
No verification beyond CI: "CI passed" means the code is shippable, not that the running release is healthy. Post-deploy smoke tests and a golden-signal comparison against baseline would have started the clock on detection immediately. CI cannot catch a memory leak that only manifests under real production load over time — only production observation can.
No watch window: the leak took hours to bite, which is exactly the delayed-regression case the watch window exists for. Walking away at green meant the only detector left was customers. Even a 30-minute active window would not have caught a three-hour leak by itself — but it would have caught the early memory-saturation trend, which is why watching the saturation golden signal (memory climbing steadily post-deploy) matters, and why the window should hand off to alerting, not just human attention.
No saturation alerting: memory climbing toward OOM is a textbook symptom alert. A "memory > 85% for 10m" page would have fired hours before the OOM kills, independent of anyone watching.
No rollback plan: 40 minutes to revert because the previous version and process were not at hand. Rollback must be a pre-defined, rehearsed one-command action with the prior release kept warm — target two minutes, not forty.
What should have happened: deploy → automated smoke tests → watch window with the deployer available → saturation alerting that fires on the memory trend → one-command rollback the moment it fires. The Friday-afternoon timing also argues for shipping when people are around to watch, or relying on canary + automated rollback if shipping late.
Practice: Define Deploy Verification Checks
Define the checks that keep deploy verification and rollback trustworthy.
Show solution
- Every deploy runs post-release smoke tests and a version-match check, and a failing smoke test automatically triggers rollback — verified by a periodic game-day that ships a deliberately broken canary and asserts it was auto-reverted.
- Golden-signal comparison against the pre-deploy baseline runs for the watch window, with regression thresholds wired to alert.
- Saturation alerts (memory, connections, disk) exist independently of the watch window so delayed regressions page even after humans move on.
Human, periodically:
- Rehearse rollback and time it; if it is not a fast one-command action with the previous release available, that is the finding. A rollback nobody has practiced is a rollback that takes 40 minutes.
- Review recent deploys: did each have a verified success signal, or are deploys being marked done on pipeline-green alone? Drift back toward "green = done" is the failure to catch.
- Confirm the canary/flag mechanisms still work and that risky changes actually used them, tying deploy safety to real behavior rather than intention.