The idea
Treat schema changes as production deployments. Design for zero downtime and reversible steps.
The approach
- Add columns as nullable first
- Backfill in batches
- Switch reads, then writes
- Remove old columns after traffic settles
Guardrails
Track migration time, lock time, and rollbacks like you track deploys.