Skip to content

Namespace the migrations under the pgml schema #524

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

Merged
merged 2 commits into from
Feb 8, 2023
Merged

Conversation

montanalow
Copy link
Contributor

This is a breaking change, from the last release, and needs review.

@montanalow montanalow requested a review from levkk February 1, 2023 02:15
@levkk
Copy link
Contributor

levkk commented Feb 1, 2023

Pretty sure this breaks migrations. Sqlx doesn't let you edit existing migrations and only allows writing new ones.

Copy link
Contributor

@levkk levkk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@montanalow
Copy link
Contributor Author

Given we're relatively recent since the original issue was merged, and that there haven't even been build instructions for the Rust dashboard since it was merged that would show how to run these migrations, I'm inclined to think the fallout from a breaking "fix" to avoid colliding with the public schema is worth dealing with the fallout for anyone running master.

There's no way for the dashboard application to enforce that the _sqlx_migrations table is moved into the pgml schema currently due to limitations in our upstream sqlx dependency, although there are open feature requests along these lines. That table will currently end up in the default search_path, wherever that happens to be. For developers, that will be the public schema, but deployements can set the default search path for the dashboard user to force it into pgml schema as well.

I've consolidated all the docs for application setup into the developer overview, and brought them up to date and inline with the current appropriate values. Most people will need to start there development environment over with this change. :(

@montanalow montanalow merged commit aa463a3 into master Feb 8, 2023
@montanalow montanalow deleted the montana/schema branch February 8, 2023 01:38
SilasMarvin pushed a commit that referenced this pull request Oct 5, 2023
Co-authored-by: Montana Low <montana.low@gmail.com>
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.

2 participants