Index

Free, with Google

Keep going, free.

A free account opens lessons 2 and 3 of every track, 33 more lessons, and keeps your progress and review cards on every device.

Start free with Google

A chalk plan

Open everything on chalk.

Every lesson, board, video, lab and paper, and the full review decks. Yearly is $39/year.

See plansStart free instead

Module 12 · System Design · The questions that keep coming up · about 17 min to read

Watch: Replication: the copy clerks
▶ VideoPlay it as a journeyTutor comes with a plan

Backups and the day you need them (RPO, RTO, and the restore nobody tested)

The Copy Clerks
The Copy Clerks · Open board

The copy clerks, a second book that follows the first. This lesson asks the question the drawing leaves open: what do you do when the first book is wrong and the clerks have faithfully copied it?

Before you start. You need the six steps from Design the Whole Thing (the interview, assembled): ask, estimate, design, with a number paying for every box. The copy clerks (database replication) gave you the replica, a second database that applies every change the first one makes. Changing the engine in flight (live schema and data migrations) showed how to change a live system in small, reversible steps, and a restore needs the same care. The operator’s side of this story, a real restore on a real Postgres, is The Restore Nobody Tested. This lesson is the design side: what you promise, and what that promise costs.

Lesson 70 of 115 in System Design

The rest of this lesson is part of a plan.

A plan opens every lesson, board, video, lab and paper on chalk. Yearly is $39/year.

See plansAlready a member? Sign in

Or start free: a free account opens lessons 2 and 3 of every track.

In this lesson

  • 31 January 2017: four ways back, and an empty bucket
  • RPO: how much recent work you agree to lose
  • RTO: how long the doors stay shut
  • Full, incremental: how a copy gets cheaper
  • WAL shipping: closing the gap to seconds
  • Cross-region: the copy that is not in the burning building
  • The restore drill: pulling the pin
  • Step 1, requirements
  • Step 2, out of scope
  • Step 3, targets
  • Step 4, estimates that change the design
  • Step 5, entities and API
  • Step 6, storage, with the trade said plainly
  • Step 7, the design, one requirement at a time
  • Step 8, deep dives
  • What each level adds
  • The follow-up: the business now wants an RPO of zero

Terms it explains: recovery point objective, recovery time objective, full backup, incremental backup, WAL archiving, restore drill, Common mistakes.

Lab

You pay your tab at stall A and walk to stall B. What do they say you owe?

Stay on Copy later, press Play next moment fourteen times, then raise Moments the clerks run behind and watch the stale answers count.

Open The copy clerks

Related papers

Review System Design