Command Palette

Search for a command to run...

PHASE 14Advanced ~7 min· topic 1 of 8

Topic 14.1

Reliability

In one line

Failover, redundancy, replication and health checks — the mechanisms that make downtime an exception, not a feature.

0/8 · 0%

Think of it like this

A car built with a spare tyre, an airbag, and a warning light for low oil — it's designed assuming SOMETHING will eventually go wrong, and plans for that instead of pretending nothing ever will.

Key ideas

  1. 01

    Failover: automatic role switch when a node fails (primary → replica promotion, LB → live nodes).

  2. 02

    Redundancy: N+1 copies of critical components so no single failure is fatal (multi-AZ!).

  3. 03

    Replication: copies of data (primary/standby) — the durability + availability half (Phase 8).

  4. 04

    Health checks: the sensor network — L7 /healthz, readiness vs liveness, circuit breakers on dependencies.

  5. 05

    The availability math: 99.9% = 8.7h/yr; 99.99% = 52min/yr; each 9 doubles the engineering bill roughly.

  6. 06

    Reliability design = pre-mortem + chaos: assume every component fails; rehearse the failure (chaos engineering).

  7. 07

    Interview: 'stateful tiers get replication + failover; stateless tiers get redundancy + LB health checks'.

Code & diagrams

FailoverSequencediagram

The minute-by-minute picture of what actually happens when a primary dies at 2am.

Rendering diagram…

Explain without notes

01

A DB primary dies at 2am. Walk the minutes: detection, failover, cutover, and what clients see.

Practice

01

Design the failover runbook for your app: LB health, DB promotion, cache reconnect, and the 10-minute budget.

Trade-offs

  • ↔

    Redundancy costs run-time money and adds coordination; MTTF pushes your SLA only when measured and rehearsed.

Run it in production

Completion checklist

  • I can name failover/redundancy/replication/health as four distinct reliability levers.

Back to phase