Build the mental model
Production systems fail in ways local dev never has to consider: a server dies, a database corrupts, a region goes down, or credentials leak. Preparing for that is the job, not pessimism.
| Term | Meaning + example |
|---|---|
| RPO | How much data loss is tolerable, in time. RPO 1 hour -> back up at least hourly. |
| RTO | How fast the system must be back up after a failure. RTO 30 min -> resolve the outage within 30 minutes. |
An untested backup is not a real backup
A backup that has never been restored is an unverified guess. Treat restoring it and confirming it works as a recurring, scheduled task, not a one-time setup step.
High availability removes single points of failure before they fail: multiple instances, redundant databases with failover, traffic routed away from anything unhealthy.
Rolling back a bad deploy is the fastest recovery — reach for it immediately rather than forward-fixing under pressure. See CI/CD's deployment-strategies lessons for blue-green/canary mechanics.
- RPO
- Recovery Point Objective — the maximum acceptable amount of data loss, measured in time.
- RTO
- Recovery Time Objective — the maximum acceptable time to restore the system after a failure.
- High Availability
- System design that removes single points of failure so the service keeps running through individual component failures.
BACKUP-RESTORE CYCLE AND HIGH AVAILABILITY
------------------------------------------
BACKUP-RESTORE CYCLE AND HIGH AVAILABILITY
----------------------------------------------
BACKUP CYCLE HIGH AVAILABILITY
-------------- -------------------
[ LIVE DATA ] [ LOAD BALANCER ]
| / | \
| backup (every X min) v v v
v [inst-1] [inst-2] [inst-3]
[ BACKUP STORE ] X (one fails)
|
| disaster happens traffic still flows
v through inst-2, inst-3
[ RESTORE ] <-- test this (no single point
| regularly! of failure)
v
[ DATA IS BACK ]Connect it to a real scenario
Meeting RPO is one comparison: is the backup interval less than or equal to the RPO target?
| Scenario | Result |
|---|---|
| Daily backups, RPO 1 hour | Fails badly — worst case is a full day of data loss. |
| Every 15 min, RPO 1 hour | Passes comfortably. |
| Hourly, RPO 1 hour | Passes exactly at the boundary — zero margin. |
Real RPO planning builds in slack rather than targeting the boundary precisely, because a backup job that runs a few minutes late is common.
An untested backup is not a real backup
Schedule regular restore tests. A backup you have never restored is a guess, and disaster is the worst time to find out it does not work.
Try the working example
function meetsRpoTarget(backupIntervalMinutes, rpoTargetMinutes) {
const meetsTarget = backupIntervalMinutes <= rpoTargetMinutes;
return {
backupIntervalMinutes,
rpoTargetMinutes,
worstCaseDataLossMinutes: backupIntervalMinutes,
meetsTarget,
};
}
const scenarios = [
{ label: "daily backups, RPO 1 hour", interval: 24 * 60, rpo: 60 },
{ label: "every 15 min, RPO 1 hour", interval: 15, rpo: 60 },
{ label: "hourly backups, RPO 1 hour", interval: 60, rpo: 60 },
];
for (const s of scenarios) {
const result = meetsRpoTarget(s.interval, s.rpo);
console.log(`${s.label}: ${JSON.stringify(result)}`);
}daily backups, RPO 1 hour: {"backupIntervalMinutes":1440,"rpoTargetMinutes":60,"worstCaseDataLossMinutes":1440,"meetsTarget":false}
every 15 min, RPO 1 hour: {"backupIntervalMinutes":15,"rpoTargetMinutes":60,"worstCaseDataLossMinutes":15,"meetsTarget":true}
hourly backups, RPO 1 hour: {"backupIntervalMinutes":60,"rpoTargetMinutes":60,"worstCaseDataLossMinutes":60,"meetsTarget":true}5-minute try-it
Write a meetsRtoTarget function with the same shape, taking a measured recovery time and an RTO target. Test it against a scenario that passes and one that fails.
One important caution
Setting up automated backups once and never actually restoring one to confirm the process works end to end.
Treating a single-instance deployment as production-ready, then losing the whole app the moment that one server has a problem.
AWS Well-Architected — Reliability pillar (RPO/RTO) — Cloud & Deployment