Repository navigation
Record deployment history for bundle deployment unbind - #8204
Draft
shreyas-goenka wants to merge 5 commits into
Draft
shreyas-goenka wants to merge 5 commits into
shreyas-goenka wants to merge 5 commits into
Conversation
Unbind now records a version with one UPDATE operation per removed state entry (the resource and its permissions/grants), each carrying no state, which is how the service learns the resource left the deployment. Recording is best effort and runs after the state commit, as bind's does; a failed history upload warns and fails the version, not the unbind. The workspace resources are untouched, and an already-unbound resource records no version. direct.Unbind returns the removed entries and the serial so the phase can record them, mirroring Bind's DMSBindMetadata. Co-authored-by: Isaac <no-reply@databricks.com>
Co-authored-by: Isaac <no-reply@databricks.com>
Co-authored-by: Isaac <no-reply@databricks.com>
Contributor
Regression test report ✅Commit: Selected 13 changed tests (limit=20, 0 not selected) 19 tests: regression=9 unreleased=0 coverage=10 failing=0
TestAccept/bundle/deployment/bind/feature_spec/DMS=true/OUTPUT_MODE=recorded: branch ✅ | main (c137506) ❌ | latest (v1.28.0) ❌main (c137506): latest (v1.28.0): TestAccept/bundle/dms/bind-immutable/DMS=true: branch ✅ | main (c137506) ❌ | latest (v1.28.0) ❌main (c137506): latest (v1.28.0): same output as main (c137506) TestAccept/bundle/dms/bind-unbind/DMS=true: branch ✅ | main (c137506) ❌ | latest (v1.28.0) ❌main (c137506): latest (v1.28.0): TestAccept/bundle/dms/bind-upload-failure/DMS=true: branch ✅ | main (c137506) ❌ | latest (v1.28.0) ❌main (c137506): latest (v1.28.0): TestAccept/bundle/dms_fault/complete_version/DMS=true: branch ✅ | main (c137506) ❌ | latest (v1.28.0) ❌main (c137506): latest (v1.28.0): 4 more failure details omitted, see the full report in the run. |
Finalize is what bumps the serial, so reading it beforehand numbered the version one below the serial the state file carries. Bind already reads it after its commit. Co-authored-by: Isaac <no-reply@databricks.com>
Collaborator
✅ Integration test reportCommit: d6839ea
Top 3 slowest tests (at least 2 minutes):
|
Co-authored-by: Isaac <no-reply@databricks.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
Record
bundle deployment unbindin deployment history: a version with oneUPDATEoperation per removed state entry (the resource plus its permissions/grants), each carrying no state, which is how the service drops the resource from the deployment. Recording is best effort and runs after the state commit, as bind's does: a failed history upload warns and fails the version, not the unbind. The workspace resources are untouched. An already-unbound resource records no version. A resource type the service does not know (such asfeature_specs) unbinds as before and warns.Why
Bind records history (#7817) but unbind did not, so a bind followed by an unbind left the service believing the resource was still managed. This completes the pair using the helpers from #8201.
Tests
dms/bind-unbind: unbind records a version whose operation carries no state,list-resourcesthen shows the resource gone, and an already-unbound resource records nothing.dms/bind-upload-failure: a failed history upload warns, fails the version, and the resource is still out of remote state.dms_fault/*: each injected fault now also warns on the unbind step, and the unbind still succeeds.This pull request and its description were written by Isaac.