DeadbearBot icon indicating copy to clipboard operation
DeadbearBot copied to clipboard

Database migration doesn't allow for rollback

Open atbrandt opened this issue 3 years ago • 0 comments

The current database migration script is very rudimentary. It simply checks to see if there's a migration sql script with a newer version than the current database version, then performs migration by executing the sql inside the script, then goes on with its life. We should ideally never be pushing migration scripts that cause problems, but it can be hard to account for every scenario, so we should offer the ability to roll back a database to at least one previous state before migration, in the case of catastrophic failure.

atbrandt avatar Dec 06 '20 20:12 atbrandt