Skip to content

feat: 'data:pg:migrate' interactive method selection (W-22585064)#3791

Open
sbosio wants to merge 1 commit into
mainfrom
sbosio/add-migration-method
Open

feat: 'data:pg:migrate' interactive method selection (W-22585064)#3791
sbosio wants to merge 1 commit into
mainfrom
sbosio/add-migration-method

Conversation

@sbosio

@sbosio sbosio commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

Summary

Adds an interactive prompt to the data:pg:migrate command that allows users to select a migration method (Snapshot or Streaming) when configuring a database migration. The prompt includes descriptions of each method to help users make an informed choice. When the --method flag is provided, the interactive prompt is skipped.

Type of Change

Feature Additions (minor semver update)

  • feat: Introduces a new feature to the codebase

Testing

Notes:

  • The --method flag no longer has a default value to enable detection of interactive vs. flag-based flow
  • Existing tests updated to explicitly pass --method=snapshot to maintain their original behavior
  • New test suite added to cover interactive method selection scenarios

Steps:

  1. Checkout this branch and run npm install && npm run build
  2. Run ./bin/run data:pg:migrate --app=<app-name> without the --method flag. The app is required to have at least two migreable Classic databases (standard-0 or higher, not Essential-tier).
  3. Select a source database
  4. Create a new database as target
  5. Verify the method selection prompt appears with Snapshot and Streaming options
  6. Select method and confirm the migration configuration
  7. Run ./bin/run data:pg:migrate --app=<app-name> --method=snapshot and verify the method prompt is skipped

Related Issues

GUS work item: W-22585064

@sbosio sbosio requested a review from a team as a code owner June 26, 2026 15:26
@sbosio sbosio temporarily deployed to AcceptanceTests June 26, 2026 15:26 — with GitHub Actions Inactive
@sbosio sbosio temporarily deployed to AcceptanceTests June 26, 2026 15:26 — with GitHub Actions Inactive
@sbosio sbosio temporarily deployed to AcceptanceTests June 26, 2026 15:26 — with GitHub Actions Inactive
@sbosio sbosio temporarily deployed to AcceptanceTests June 26, 2026 15:26 — with GitHub Actions Inactive

@tlowrimore-heroku tlowrimore-heroku left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM!

@sbosio

sbosio commented Jun 26, 2026

Copy link
Copy Markdown
Contributor Author

Do not merge yet. We'll be merging after @heicheng18 has reviewed the new strings introduced for the feature.

@sbosio sbosio requested a review from heicheng18 June 26, 2026 16:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants