Definition
- Detect – Automated monitoring on user-facing SLIs fires an alert that pages the on-call engineer.
- Triage – Assess severity and scope: what is broken, for how many users, since when, and is it getting worse.
- Respond – Assemble a team with clear roles: incident commander, responders, and communicator.
- Fix – Mitigate first to restore service (rollback, flag flip, failover), then do root-cause analysis after the system is stable.
- Postmortem – A blameless written review documenting what happened, the timeline, impact, and concrete action items to prevent recurrence.
Imagine a fire alarm process at the National Bank of India. First a smoke detector goes off (detect). Someone quickly judges how bad it is: a small bin fire or the whole vault (triage). The right people are called and customers are told what is happening (respond). The priority is to put the fire out and get the branch working, not to immediately figure out who left the stove on (fix: mitigate first). Only after everyone is safe does the bank calmly review what happened without blaming any single person (blameless postmortem).
Understanding the Concepts
What is incident management?
Incident management is the structured process for detecting, responding to, and resolving unplanned disruptions to a production service. It follows a repeatable lifecycle so that each incident both restores service quickly and makes the system more resilient afterward.
# The five-step lifecycle:
# 1. DETECT -> alert fires on user-facing SLIs
# 2. TRIAGE -> assess severity and scope
# 3. RESPOND -> assemble team, assign roles, communicate
# 4. FIX -> mitigate first, root-cause later
# 5. POSTMORTEM -> blameless review with action items
How does detection work?
Detection is the entry point, and it must be automated and tied to user-facing signals. Monitoring systems watch SLIs like error rate and latency and fire an alert when a threshold or burn rate is crossed.
# Prometheus alert rule: transfer API error rate spikes
groups:
- name: transfer-api-alerts
rules:
- alert: TransferAPIHighErrorRate
expr: |
rate(http_requests_total{app="transfer-api",status=~"5.."}[5m])
/ rate(http_requests_total{app="transfer-api"}[5m]) > 0.05
for: 2m
labels:
severity: critical
annotations:
summary: "Transfer API error rate > 5% for 2 minutes"
# Good detection: alerts on symptoms users feel
# "Error rate > 5%" -> customers are seeing failures
# Bad detection: alerts on internal metrics
# "Pod CPU > 80%" -> may not affect users at all
# Result: alert fatigue, engineers ignore the pager
How does triage work?
The responder confirms and sizes the impact using dashboards and user-facing signals, then assigns a severity level that drives the response.
# Triage questions:
# 1. What exactly is broken? (transfers failing, login down, reports slow)
# 2. For how many users? (all, 50%, specific segment)
# 3. Since when? (5 minutes ago, 2 hours ago)
# 4. Is it getting worse or stabilizing?
# Severity levels at National Bank of India:
# SEV1: Full outage or money movement broken for >25% of users
# -> page everyone, war room, 15-min status updates
# SEV2: Degraded but working, or <25% of users affected
# -> page on-call, 30-min status updates
# SEV3: Minor issue, workaround available
# -> ticket, fix during business hours
How does the response phase work?
For a significant incident, assign clear roles to prevent chaos.
# Incident roles:
# Incident Commander (IC): coordinates, makes decisions, does NOT debug
# Responder(s): investigate, diagnose, execute fixes
# Communicator: updates stakeholders, status page, customers
# Example at National Bank of India:
# IC: Pankaj (architect) -> "Rajesh, check the transfer-api logs.
# Priya, update the status page every 15 minutes."
# Responder: Rajesh -> checks logs, finds the root cause
# Communicator: Priya -> posts updates to status.nationalbank.in
# Automated incident channel creation (PagerDuty/Opsgenie)
# When SEV1 fires:
# 1. PagerDuty pages the on-call (Rajesh)
# 2. Creates Slack channel: #incident-2024-01-15-transfer-api
# 3. Invites IC, responders, communicator
# 4. Posts the alert details and dashboard link
How does the fix phase work? (mitigate first)
The cardinal rule: mitigate first to stop the impact, root-cause later. The goal is to restore service by the fastest safe means.
# Mitigation options (fastest first):
# 1. Roll back the last release
kubectl rollout undo deployment/transfer-api -n banking
# 2. Flip a feature flag off
curl -X PATCH https://flags.nationalbank.in/api/flags/new-transfer-flow \
-d '{"enabled": false}'
# 3. Scale out to absorb load
kubectl scale deployment/transfer-api --replicas=10 -n banking
# 4. Fail over to a healthy region
aws route53 change-resource-record-sets --hosted-zone-id Z123 \
--change-batch file://failover-to-secondary.json
# Why mitigate before root-cause:
# 1. Every minute of outage costs customers and money
# 2. Investigating under pressure is slow and error-prone
# 3. A stable system can be investigated calmly and thoroughly
# 4. Rollback does not require understanding the bug
How does the blameless postmortem work?
After resolution, the team writes a document that focuses on systems, not people.
# Postmortem structure:
# 1. Summary: one-paragraph description
# 2. Impact: users affected, duration, business impact
# 3. Timeline: timestamped events from detection to resolution
# 4. Root cause: what went wrong and why (systemic, not personal)
# 5. What went well: good practices that helped
# 6. What got lucky: near-misses that could have been worse
# 7. Action items: concrete, owned, with due dates
# Example action items:
# [Rajesh, 2024-01-22] Add index-presence check to CI pipeline
# [Priya, 2024-01-29] Set up canary with auto-rollback for transfer-api
# [Pankaj, 2024-02-05] Add database latency alert to Grafana
What are common mistakes in incident management?
# WRONG: No clear roles during the incident
# Everyone debugs at once. Nobody communicates. Nobody decides.
# Two people run conflicting fixes simultaneously.
# CORRECT: Assign IC, responders, communicator immediately.
# IC says: "Rajesh, investigate. Priya, communicate. I coordinate."
# WRONG: Root-causing during the outage
# "Let me read the code diff before rolling back..."
# 30 minutes pass. Customers still cannot transfer.
# CORRECT: Roll back first, investigate later.
# Service restored in 60 seconds. Root cause found in a calm postmortem.
What should a senior engineer know?
Mature incident management tracks metrics like time-to-detect (TTD) and time-to-resolve (TTR) to improve the process itself, maintains runbooks so responders have step-by-step guidance for common problems, and uses on-call rotations with sustainable load so responders are rested and effective.
# Incident metrics to track:
# TTD (Time to Detect): how long from failure to alert
# TTA (Time to Acknowledge): how long from alert to human response
# TTM (Time to Mitigate): how long from response to service restored
# TTR (Time to Resolve): how long from detection to full resolution
# Goal: reduce each metric over time through process improvements
Visual Overview
Incident Management Lifecycle
==============================
┌─────────────┐
│ 1. DETECT │ Prometheus alert fires
│ (alert) │ Pages on-call via PagerDuty
└──────┬──────┘
│
▼
┌─────────────┐
│ 2. TRIAGE │ What is broken? How many users?
│ (severity) │ SEV1 / SEV2 / SEV3
└──────┬──────┘
│
▼
┌─────────────┐
│ 3. RESPOND │ IC + Responders + Communicator
│ (team up) │ Slack channel, war room
└──────┬──────┘
│
▼
┌─────────────┐
│ 4. FIX │ MITIGATE FIRST: rollback, flag off
│ (mitigate) │ Root-cause AFTER service is stable
└──────┬──────┘
│
▼
┌─────────────┐
│ 5. POSTMORT │ Blameless review
│ (learn) │ Concrete action items + owners + dates
└─────────────┘
Key Takeaway
Incident management is a five-step lifecycle designed to restore service fast and then learn from what happened. Detection fires on user-facing SLIs so a page always means something real. Triage sizes the impact and assigns severity. Response assembles a team with clear roles: an incident commander who coordinates, responders who investigate, and a communicator who keeps stakeholders informed. The fix follows the cardinal rule: mitigate first by the fastest safe means (rollback, flag flip, failover), and do root-cause analysis only after service is stable.
The blameless postmortem is the final and most important step for long-term improvement. It documents what happened, the timeline, impact, root cause, and concrete action items with owners and due dates, focusing on systemic causes rather than individual blame. At the National Bank of India, when a deploy spiked the transfer-api error rate, the lifecycle ran exactly: the alert paged on-call, triage assessed it as SEV1, the IC coordinated while comms updated the status page, the team mitigated by rolling back in minutes, and the blameless postmortem produced action items like a CI index check and canary with auto-rollback.
Remember one sentence: detect, triage, respond with clear roles, mitigate first before root-causing, and write a blameless postmortem with owned action items so every incident leaves the system more resilient.
---