liveBook · Manning

Backup and restore

As explained in API Design Patterns

A backup is a preserved copy of data intended to support recovery or restoration of the original data.

A backup preserves a consistent snapshot of data, including unique identifiers, so the original state can be recovered or restored. section 23.3.4

Do not equate API export with backup. Export methods move data to external storage without consistency guarantees, atomic preservation, or complete restoration from a prior snapshot. section 23.3.4 section 23.4

Choose safeguards according to consistency and deletion requirements:

  • Use a storage system’s consistent snapshot support when available. section 23.3.4
  • If consistent snapshots are unavailable and inconsistent exports are unacceptable, temporarily disable resource modification during export. section 23.3.4
  • When permanent deletion is required, preserve recoverability through a deliberate backup strategy rather than soft deletion. section 25.4
Table 23.1 Export scenario with a smear of data (view table figure)

User action

Export action

Stored data

Exported data

Create A, B, C

 

A, B, C

 

 

Export A

A, B, C

A

Delete A

 

B, C

A

 

Export B

B, C

A, B

Create D

 

B, C, D

A, B

Delete C

 

B, D

A, B

 

Export D

B, D

A, B, D

The export sequence shows how creating, deleting, and exporting resources produces a partial, time-smeared result rather than one snapshot. section 23.3.4

How API Design Patterns covers it

How deep it goes
Distinguishes snapshots from exports and gives operational fallbacks, but does not specify backup implementation or restore procedures.
Examples
Uses an export sequence where resources are created, deleted, and exported at different times, producing smeared data.
What it assumes
Assumes familiarity with API resources and external storage; teaches the distinction between exporting data and backing it up.
What you can do after
Evaluate export designs and choose snapshot or operational safeguards for preserving recoverable API data.
How it connects
Ties backups to consistent snapshots, export, restore, soft deletion, and data loss.

Also explained in

Compare how 10 books explain backup and restore →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of API Design Patterns. The section links point to the parts of the book it draws on.