Skip to content

refactor: use sdk for addons commands - #3850

Open
jdodson wants to merge 9 commits into
v12.0.0from
jbd_addons_topic_sdk_migration
Open

refactor: use sdk for addons commands#3850
jdodson wants to merge 9 commits into
v12.0.0from
jbd_addons_topic_sdk_migration

Conversation

@jdodson

@jdodson jdodson commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Summary

Migrates addons to use the SDK

  • upgrade — fixed double new HerokuSDK() (single instance)
  • destroyplatform.addOn.destroyAndWait; CLI keeps the pg error copy
  • waitwaitForProvisioning + new pollAddonUntilDeprovisioned helper

Type of Change

Breaking Changes (major semver update)

  • Add a ! after your change type to denote a change that breaks current behavior

Feature Additions (minor semver update)

  • feat: Introduces a new feature to the codebase

Patch Updates (patch semver update)

  • fix: Bug fix
  • deps: Dependency upgrade
  • revert: Revert a previous commit
  • chore: Change that does not affect production code
  • refactor: Refactoring existing code without changing behavior
  • test: Add/update/remove tests

Testing

SDK reads netrc, so log in with HEROKU_NETRC_WRITE=true. Throwaway app; last step is destructive. Keep the order — upgrade/attach mutate the add-on, destroy removes it.

Setup

  • npm i && npm run build
  • HEROKU_NETRC_WRITE=true ./bin/run login
  • ./bin/run apps:create APP
  • ./bin/run addons:create heroku-postgresql:essential-0 --app APP --wait — note the add-on name (ADDON)

Run each migrated command

  • ./bin/run addons:wait --app APP — lists status
  • ./bin/run addons:upgrade ADDON heroku-postgresql:essential-1 --app APP — plan changes
  • ./bin/run addons:docs ADDON --app APP --show-url — prints docs URL
  • ./bin/run addons:open ADDON --app APP --show-url — prints dashboard URL
  • ./bin/run addons:attach ADDON --app APP --as MYDB — attaches, prints done, v<N>
  • ./bin/run addons:destroy ADDON --app APP --confirm APPDestroying ADDON on ⬢ APP... done

Cleanup

  • ./bin/run apps:destroy --app APP --confirm APP

Screenshots (if applicable)

Related Issues

GUS work item: https://gus.lightning.force.com/lightning/r/ADM_Work__c/a07EE00002eHU1qYAG/view

@jdodson
jdodson requested a review from a team as a code owner August 4, 2026 16:10
@jdodson
jdodson changed the base branch from main to v12.0.0 August 4, 2026 16:11
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 16:40 — with GitHub Actions Inactive
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 16:40 — with GitHub Actions Inactive
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 16:40 — with GitHub Actions Inactive
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 16:40 — with GitHub Actions Inactive
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 17:14 — with GitHub Actions Inactive
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 17:14 — with GitHub Actions Inactive
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 17:14 — with GitHub Actions Inactive
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 17:14 — with GitHub Actions Inactive
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 17:32 — with GitHub Actions Inactive
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 17:32 — with GitHub Actions Inactive
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 17:32 — with GitHub Actions Inactive
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 17:32 — with GitHub Actions Inactive
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 22:34 — with GitHub Actions Inactive
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 22:34 — with GitHub Actions Inactive
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 22:34 — with GitHub Actions Inactive
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 22:34 — with GitHub Actions Inactive
@jdodson
jdodson deployed to AcceptanceTests August 4, 2026 23:28 — with GitHub Actions Active
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 23:28 — with GitHub Actions Inactive
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 23:28 — with GitHub Actions Inactive
@jdodson
jdodson temporarily deployed to AcceptanceTests August 4, 2026 23:28 — with GitHub Actions Inactive
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.

1 participant