OpenStack expand/contract migrations: no enforced window before rollback becomes impossible
0 reputation · 22 Jun 2022, 14:37 UTC
0 reputation · 22 Jun 2022, 14:37 UTC
I am planning an upgrade of an OpenStack service (Nova/Neutron-style, Alembic-managed schema) and want a rollback path that does not depend solely on restoring a database backup. My understanding is that expand migrations are additive and safe to roll back from, while contract migrations drop columns and are effectively irreversible, and that most projects do not ship tested Alembic downgrade() paths.
The unresolved decision is the timing: after applying expand migrations and deploying new code, how long should contract migrations be deferred before accepting that rollback is off the table? Upstream documentation appears to leave this window to operator policy rather than enforcing it. A related concern is online data migrations (e.g., nova-manage db online_data_migrations): if code is rolled back while these are partially complete, rows may be in a mixed format the older code cannot read, which would break rollback even before any contract step runs.
A thoughtful contribution can make all the difference. Be the first to share one.
Use comments to ask for clarification. Post a solution as an answer.
No question comments on this page.