Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DM-47646: Rework Gafaelfawr schema management #1152

Merged
merged 1 commit into from
Nov 20, 2024
Merged

DM-47646: Rework Gafaelfawr schema management #1152

merged 1 commit into from
Nov 20, 2024

Conversation

rra
Copy link
Member

@rra rra commented Nov 19, 2024

Make Gafaelfawr's schema management match the new recommended practices in Safir, including a stack of schema migrations that create the database from scratch. This means that direct upgrades from versions earlier than 10.0.0 are no longer supported, since they will attempt to recreate the schema unless one carefully uses alembic stamp first. Document that.

Change the name of the SQLAlchemy declarative base to SchemaBase, matching the Safir documentation.

Switch to the Safir method of checking for unexpected schema changes, which is much simpler than the previous approach and doesn't require keeping around old copies of the schema.

Point to the Safir documentation for how to make schema migrations rather than duplicating that documentation here.

Make Gafaelfawr's schema management match the new recommended
practices in Safir, including a stack of schema migrations that
create the database from scratch. This means that direct upgrades
from versions earlier than 10.0.0 are no longer supported, since
they will attempt to recreate the schema unless one carefully uses
`alembic stamp` first. Document that.

Change the name of the SQLAlchemy declarative base to `SchemaBase`,
matching the Safir documentation.

Switch to the Safir method of checking for unexpected schema changes,
which is much simpler than the previous approach and doesn't require
keeping around old copies of the schema.

Point to the Safir documentation for how to make schema migrations
rather than duplicating that documentation here.
@rra rra merged commit 9b90db9 into main Nov 20, 2024
5 checks passed
@rra rra deleted the tickets/DM-47646 branch November 20, 2024 00:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant