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

feat: Add disableTransactions option to Migrator #1335

Open
wants to merge 2 commits into
base: v0.28
Choose a base branch
from

Conversation

reidswan
Copy link

Summary

Adds disableTransactions option to the Migrator.

This flag controls whether the migrator will run a migration in a transaction or not, for dialects that support a transactional DDL.

When true, migrations will not be run in a transaction, even if the dialect supports transactions in their DDL.

When false, migrations will be run in a transaction if that is supported by the dialect.

Testing

  • Added unit tests to test/node.
  • Tested manually by creating a postgres migration to CREATE INDEX CONCURRENTLY on a big table. This succeeded when disableTransactions was true, and failed (as expected) when disableTransactions was false.

Closes #352

Copy link

vercel bot commented Jan 28, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
kysely ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 28, 2025 7:00pm

Copy link

pkg-pr-new bot commented Jan 28, 2025

Open in Stackblitzkysely_koa_example

npm i https://pkg.pr.new/kysely-org/kysely@1335

commit: 6e63119

@igalklebanov igalklebanov changed the base branch from master to v0.28 January 28, 2025 19:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request migrations Related to migrations
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feature request: non-transactional migrations for concurrent index creation
2 participants