You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currenty we cannot revert a database migration in case anything goes wrong.
This causes a lot of deployment stabilization efforts when a mistake was made, including manual intervention into production db.
Experiment, if up/down migrations, offered by sqlx migrate commands, can help improving this aspect:
sqlx migrate add -r: If true, creates a pair of up and down migration files with same version else creates a single sql file
sqlx migrate revert: Revert the latest migration with a down file
It's assumed that any migration would require creating a reverse-migration to achieve the desired goal.
Open question: what do we do with the existing already applied migrations.
The text was updated successfully, but these errors were encountered:
Currenty we cannot revert a database migration in case anything goes wrong.
This causes a lot of deployment stabilization efforts when a mistake was made, including manual intervention into production db.
Experiment, if up/down migrations, offered by
sqlx migrate
commands, can help improving this aspect:sqlx migrate add -r
: If true, creates a pair of up and down migration files with same version else creates a single sql filesqlx migrate revert
: Revert the latest migration with a down fileIt's assumed that any migration would require creating a reverse-migration to achieve the desired goal.
Open question: what do we do with the existing already applied migrations.
The text was updated successfully, but these errors were encountered: