What problem does it solve?
Database migrations are a leading cause of production incidents, irreversible data loss, and application downtime due to their high-risk nature and potential for unrecoverable schema or data changes.
Core Features & Use Cases
- Dangerous Pattern Detection: Flags high-risk migration patterns including adding NOT NULL constraints without prior backfills, dropping columns/tables, unbatched large table updates, and adding unique constraints without duplicate checks.
- Zero-Downtime Migration Guidance: Implements the expand-contract pattern to deploy destructive schema changes like column type changes or removals without application downtime.
- Pre-Release Validation & Rollback Planning: Provides checklists to verify migration safety, confirm rollback paths exist, and document irreversible changes before production deployment.
- Use Case Example: Use this skill when preparing a migration to add a new non-null column to a 10M row user table, ensuring you follow safe backfill steps instead of locking the table for hours.
Quick Start
Use the migration-safety skill to review your upcoming user table schema migration for dangerous patterns and generate a complete rollback plan before deploying to production.