Build fluency in the vocabulary of restoring a database to any arbitrary past moment using a backup plus logs.
0 / 5 completed
1 / 5
At standup, a dev mentions restoring a database to its exact state at any arbitrary moment in the past, such as one minute before an accidental mass deletion, by replaying a base backup plus every write-ahead log record up to that moment. What is this capability called?
Point-in-time recovery is exactly this: it restores a database to its exact state at any arbitrary moment in the past, such as one minute before an accidental mass deletion, by replaying a base backup plus every write-ahead log record up to that specific moment. A hash collision is an unrelated hash-table concept about two keys sharing a bucket. This replay-backup-plus-logs-to-any-moment approach is exactly why point-in-time recovery can undo an accidental deletion without losing every other legitimate write that happened before it.
2 / 5
During a design review, the team enables continuous write-ahead log archiving alongside periodic base backups, specifically because point-in-time recovery needs the full log record up to the target moment, not just the most recent base backup. Which capability does this provide?
Continuous log archiving here provides recovery to any specific past moment, not just the last backup, since replaying archived logs on top of a base backup can reconstruct the database's exact state up to any moment covered by the log archive. Restoring only the most recent base backup with no log replay at all can only recover to whenever that backup was taken, losing every write made since. This replay-logs-on-top-of-a-backup behavior is exactly why point-in-time recovery requires continuous log archiving in addition to periodic base backups.
3 / 5
In a code review, a dev notices a database's backup strategy takes a periodic full snapshot but archives no write-ahead log records in between snapshots, meaning any restore can only land on the moment of the last snapshot rather than any arbitrary moment since then. What does this represent?
This is a missed point-in-time-recovery opportunity, since archiving the write-ahead log between snapshots would let a restore land on any specific moment instead of only the moment of the last full snapshot. A cache eviction policy is an unrelated concept about discarded cache entries. This snapshot-only-no-log-archiving pattern is exactly the kind of recovery-precision gap a reviewer flags once an accidental deletion could happen between two scheduled snapshots.
4 / 5
An incident report shows a team could only restore a database to the previous night's snapshot after an accidental mass deletion mid-afternoon, losing an entire day's legitimate writes, because the backup strategy archived no write-ahead log records between snapshots. What practice would prevent this?
Archiving the write-ahead log continuously alongside periodic snapshots lets a restore land on the exact moment just before the accidental deletion instead of only the previous night's snapshot. Continuing to take periodic snapshots with no write-ahead log archiving in between regardless of how many legitimate writes get lost after an accidental deletion is exactly what caused the data loss described in this incident. This continuous-log-archiving approach is the standard fix once recovery precision is confirmed to matter between scheduled snapshots.
5 / 5
During a PR review, a teammate asks why the team implements point-in-time recovery with continuous log archiving instead of simply taking full snapshots more frequently, given that more frequent snapshots also shrink the recovery gap. What is the reasoning?
Point-in-time recovery with continuous log archiving can restore to any exact moment covered by the log, while taking full snapshots more frequently only shrinks the gap to the nearest snapshot and still cannot land on an arbitrary moment between two snapshots, at a higher storage and performance cost from the extra full snapshots. This is exactly why continuous log archiving is the standard mechanism behind true point-in-time recovery, while more frequent snapshots remain a coarser, costlier approximation.