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

Add option :migrations-table-exists-sql for SQL backed migrations #158

Merged

Conversation

mbezjak
Copy link
Contributor

@mbezjak mbezjak commented Aug 10, 2023

Closes #157

@mbezjak

This comment was marked as outdated.

@mbezjak mbezjak force-pushed the migrations-table-exists-sql branch from 8e86a41 to e247bfd Compare January 4, 2024 11:00
@mbezjak
Copy link
Contributor Author

mbezjak commented Jan 4, 2024

Implemented the same thing in jdbc project. The PR should be complete now.

@weavejester Let me know what you think. Especially about the comment above.

Copy link
Owner

@weavejester weavejester left a comment

Choose a reason for hiding this comment

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

Thanks for the updated PR. Can you ensure all lines are 80 characters or less?

@mbezjak
Copy link
Contributor Author

mbezjak commented Jan 4, 2024

Updated as per comments. Thanks for looking into this. 😄

Can you ensure all lines are 80 characters or less?

Done. Although, there are some prior lines not respecting it.

$ grep -R '.\{81\}' next-jdbc/src/ jdbc/src/
next-jdbc/src/ragtime/next_jdbc.clj:      ;; Returns unqualified maps as some databases (e.g. Oracle) can only return them
next-jdbc/src/ragtime/next_jdbc.clj:      (rs/datafiable-result-set conn {:builder-fn rs/as-unqualified-lower-maps})))
next-jdbc/src/ragtime/next_jdbc.clj:  ;; Remove db quote around the schema and table name; ex.: "\"schema\".\"table\""

@mbezjak mbezjak requested a review from weavejester January 4, 2024 14:58
@mbezjak
Copy link
Contributor Author

mbezjak commented Oct 8, 2024

Ping 😄

@weavejester
Copy link
Owner

Apologies for the delay, this PR seems to have slipped through my inbox.

Copy link
Owner

@weavejester weavejester left a comment

Choose a reason for hiding this comment

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

I have some minor formatting suggestions. Once they're done could you squash down your commits and give them an appropriate commit message. Once again, apologies for not getting around to reviewing this.

@mbezjak mbezjak force-pushed the migrations-table-exists-sql branch from 4f8048c to 04668be Compare October 11, 2024 08:46
@mbezjak mbezjak requested a review from weavejester October 11, 2024 08:46
@mbezjak
Copy link
Contributor Author

mbezjak commented Oct 11, 2024

Done! Thanks for looking at this. 😄

@weavejester
Copy link
Owner

Thanks! Can you change the commit message to:

Add :migrations-table-exists-sql option

Add a :migrations-table-exists-sql option in order to more efficiently
check for the Ragtime migrations table. Using database metadata lookups
via JDBC can be slow depending on the size of the database.

Fixes #157.

This is to ensure it adheres to the contributing guidelines. Once that's done I'll merge and cut a release. Thanks again for your patience.

Add a :migrations-table-exists-sql option in order to more efficiently
check for the Ragtime migrations table. Using database metadata lookups
via JDBC can be slow depending on the size of the database.

Fixes weavejester#157.
@mbezjak mbezjak force-pushed the migrations-table-exists-sql branch from 04668be to 120b75b Compare November 6, 2024 08:36
@mbezjak
Copy link
Contributor Author

mbezjak commented Nov 6, 2024

Done! Thanks!

@weavejester weavejester merged commit 624da4c into weavejester:master Nov 6, 2024
1 check passed
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.

Optimize performance of ragtime.next-jdbc/ensure-migrations-table-exists
2 participants