Skip to content

direct: tolerate DELETING apps at apply-time delete#6061

Open
denik wants to merge 2 commits into
mainfrom
denik/apps-delete-deleting-apply
Open

direct: tolerate DELETING apps at apply-time delete#6061
denik wants to merge 2 commits into
mainfrom
denik/apps-delete-deleting-apply

Conversation

@denik

@denik denik commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

Follow-up to #6045, which consulted the new IsGone hook only at plan time. A saved plan (deploy --plan) records Gone=false if the app was still ACTIVE when planned; if it enters DELETING before apply — a concurrent delete, or an interrupted destroy — apply calls DoDelete on the stale entry and the backend rejects the second delete with 400 BAD_REQUEST.

On an otherwise-fatal delete error, re-read the resource and consult IsGone (and IsMissing); treat it as already deleted if so. Applies to both Delete and Recreate. Detection re-reads rather than matching the error because the backend returns a generic 400 with no distinct SDK sentinel.

IsGone is consulted at plan time, but a saved plan (deploy --plan) records
Gone=false if the app was still ACTIVE when planned. If the app enters
DELETING before apply -- a concurrent delete, or an interrupted destroy --
apply calls DoDelete on the stale entry and the backend rejects the second
delete with 400 BAD_REQUEST.

On an otherwise-fatal delete error, re-read the resource and consult IsGone
(and IsMissing); treat it as already deleted if so. Applies to both Delete
(destroy / delete-by-removal) and Recreate. Detection re-reads rather than
matching the error because the backend returns a generic 400 with no
distinct SDK sentinel.

Co-authored-by: Isaac
@eng-dev-ecosystem-bot

eng-dev-ecosystem-bot commented Jul 24, 2026

Copy link
Copy Markdown
Collaborator

Integration test report

Commit: 94fe0da

Run: 30194336216

Env 💚​RECOVERED 🙈​SKIP ✅​pass 🙈​skip Time
💚​ aws linux 4 4 322 1061 5:11
💚​ aws windows 4 4 324 1059 7:37
💚​ azure linux 4 4 322 1060 5:08
💚​ azure windows 4 4 324 1058 7:29
💚​ gcp linux 1 5 321 1062 5:01
💚​ gcp windows 1 5 323 1060 7:37
8 interesting tests: 4 RECOVERED, 4 SKIP
Test Name aws linux aws windows azure linux azure windows gcp linux gcp windows
💚​ TestAccept 💚​R 💚​R 💚​R 💚​R 💚​R 💚​R
🙈​ TestAccept/bundle/invariant/no_drift 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/vector_search_endpoints/drift/recreated_same_name 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/vector_search_indexes/recreate/embedding_dimension 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/ssh/connection 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
💚​ TestFetchRepositoryInfoAPI_FromRepo 💚​R 💚​R 💚​R 💚​R 🙈​S 🙈​S
💚​ TestFetchRepositoryInfoAPI_FromRepo/root 💚​R 💚​R 💚​R 💚​R
💚​ TestFetchRepositoryInfoAPI_FromRepo/subdir 💚​R 💚​R 💚​R 💚​R
Top 6 slowest tests (at least 2 minutes):
duration env testname
6:28 gcp windows TestAccept
6:27 azure windows TestAccept
6:25 aws windows TestAccept
2:59 aws linux TestAccept
2:53 gcp linux TestAccept
2:52 azure linux TestAccept

Avoid duplicating the bundle/workspace stanza between the deploy config and
the inline delete config; both now assemble databricks.yml from a shared
databricks_header.yml.tmpl.

Co-authored-by: Isaac
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.

3 participants