Nest Engineering Docs
Processes

Schema migrations

How we plan, review, and apply Spanner schema changes.

Purpose

Ensure schema changes are safe, reversible, and zero-downtime.

Source of truth

  • All Spanner schema changes are managed via Liquibase under db/liquibase/.
  • Do not apply manual DDL changes outside Liquibase.

Approvals

Schema changes require approval from:

  • Akansh Divker
  • Joe Pardi
  • John Thomas

Requirements

  • All migrations must be reviewed and tested.
  • Zero-downtime is required for every change.
  • Breaking changes must remain backwards compatible until the full migration is complete.

Procedure

  1. Create or update Liquibase changesets in db/liquibase/changelogs/spanner/nest/.
  2. Validate locally or in lower environments using the Liquibase scripts.
  3. Obtain schema approvals before production rollout.
  4. Deploy schema changes through the standard Liquibase workflow.
  5. Verify application behavior after migration.

Rollbacks

  • Rollbacks for Spanner must be executed via Liquibase, not manual DDL.
  • Coordinate schema rollback with application rollback if needed.

Last updated on