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

Provide a "reset" command, so users can quickly be able to restart pgbelt migrations #561

Open
vjeeva opened this issue Sep 18, 2024 · 1 comment

Comments

@vjeeva
Copy link
Contributor

vjeeva commented Sep 18, 2024

Problem:

  • Users encounter errors. Sometimes due to pgbelt bugs, sometimes due to dataset issues on their end, etc.
  • Whenever any sort of issue occurs, they need to restart their migration jobs
  • They can't just teardown and run setup again since data exists in their destination DBs.

Proposed Solution

  • Provide a command like reset that can only work on a destination database.
  • In full migrations, truncate all the destination tables, ensure sequences are set to 0, and ensure no FKs exist
  • In exodus migrations, truncate all destination tables that are in the config, ensure sequences from the config are set to 0, and ensure no FKs exist in the tables from the config
@Mk-d-law
Copy link

Does the reset feature works on when the migration is interrupted and resume the migration from source to destination without causing issues or duplicates it will also be good when we can handle as like a resume migration on case of interruption.

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

No branches or pull requests

2 participants