ロールバックマイグレーション - CI/CD用語集の定義
ロールバックマイグレーション(「down」方向)は、以前のマイグレーションを取り消し、それが追加したカラムやテーブルを削除して、スキーマを以前のバージョンに戻します。
なぜリスクが高いのか
「down」マイグレーションはデータを破壊することがあり(カラムを削除するとその値が失われる)、多くの本番チームはこれを避けて前進(roll forward)を好みます。CIは、使い捨てのデータに対して「down」スクリプトを試す安全な場所です。
関連ガイド
Forward Migration - CI/CD Glossary DefinitionForward Migration: A forward migration (the "up" direction) advances the schema to a newer version, applying…
Database Migration - CI/CD Glossary DefinitionDatabase Migration: A database migration is a versioned, ordered change to a database schema or data, applied…