diff --git a/acceptance/bundle/deployment/bind/alert/out.test.toml b/acceptance/bundle/deployment/bind/alert/out.test.toml index f68b4a89c36..0f167effef1 100644 --- a/acceptance/bundle/deployment/bind/alert/out.test.toml +++ b/acceptance/bundle/deployment/bind/alert/out.test.toml @@ -1,2 +1,2 @@ Cloud = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/catalog/out.test.toml b/acceptance/bundle/deployment/bind/catalog/out.test.toml index f68b4a89c36..0f167effef1 100644 --- a/acceptance/bundle/deployment/bind/catalog/out.test.toml +++ b/acceptance/bundle/deployment/bind/catalog/out.test.toml @@ -1,2 +1,2 @@ Cloud = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/cluster/out.test.toml b/acceptance/bundle/deployment/bind/cluster/out.test.toml index f68b4a89c36..0f167effef1 100644 --- a/acceptance/bundle/deployment/bind/cluster/out.test.toml +++ b/acceptance/bundle/deployment/bind/cluster/out.test.toml @@ -1,2 +1,2 @@ Cloud = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/dashboard/out.test.toml b/acceptance/bundle/deployment/bind/dashboard/out.test.toml index de136de256d..7a62f726f25 100644 --- a/acceptance/bundle/deployment/bind/dashboard/out.test.toml +++ b/acceptance/bundle/deployment/bind/dashboard/out.test.toml @@ -1,3 +1,3 @@ Cloud = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/deployment/bind/dashboard/recreation/out.test.toml b/acceptance/bundle/deployment/bind/dashboard/recreation/out.test.toml index de136de256d..7a62f726f25 100644 --- a/acceptance/bundle/deployment/bind/dashboard/recreation/out.test.toml +++ b/acceptance/bundle/deployment/bind/dashboard/recreation/out.test.toml @@ -1,3 +1,3 @@ Cloud = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/deployment/bind/dashboard/recreation/output.txt b/acceptance/bundle/deployment/bind/dashboard/recreation/output.txt index 0b06a0a6d0c..a10b214a712 100644 --- a/acceptance/bundle/deployment/bind/dashboard/recreation/output.txt +++ b/acceptance/bundle/deployment/bind/dashboard/recreation/output.txt @@ -3,7 +3,7 @@ Successfully bound dashboard with an id '[DASHBOARD_ID]' Run 'bundle deploy' to deploy changes to your workspace ->>> print_state.py +>>> print_state.py --no-dms [ETAG] >>> [CLI] bundle plan diff --git a/acceptance/bundle/deployment/bind/dashboard/recreation/script b/acceptance/bundle/deployment/bind/dashboard/recreation/script index 9d9f5cacf2f..c9656879b7e 100644 --- a/acceptance/bundle/deployment/bind/dashboard/recreation/script +++ b/acceptance/bundle/deployment/bind/dashboard/recreation/script @@ -13,7 +13,7 @@ cleanupRemoveDashboard() { trap cleanupRemoveDashboard EXIT trace $CLI bundle deployment bind dashboard1 "${DASHBOARD_ID}" --auto-approve -trace print_state.py > out.state_after_bind.json +trace print_state.py --no-dms > out.state_after_bind.json ETAG=$(jq '.state["resources.dashboards.dashboard1"].state.etag // .resources[0].instances[0].attributes.etag // "no-etag"' < out.state_after_bind.json) echo $ETAG add_repl $ETAG ETAG diff --git a/acceptance/bundle/deployment/bind/database_instance/out.test.toml b/acceptance/bundle/deployment/bind/database_instance/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/database_instance/out.test.toml +++ b/acceptance/bundle/deployment/bind/database_instance/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/experiment/out.test.toml b/acceptance/bundle/deployment/bind/experiment/out.test.toml index f68b4a89c36..0f167effef1 100644 --- a/acceptance/bundle/deployment/bind/experiment/out.test.toml +++ b/acceptance/bundle/deployment/bind/experiment/out.test.toml @@ -1,2 +1,2 @@ Cloud = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/external_location/out.test.toml b/acceptance/bundle/deployment/bind/external_location/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/external_location/out.test.toml +++ b/acceptance/bundle/deployment/bind/external_location/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/feature/out.test.toml b/acceptance/bundle/deployment/bind/feature/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/feature/out.test.toml +++ b/acceptance/bundle/deployment/bind/feature/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/genie_space/out.test.toml b/acceptance/bundle/deployment/bind/genie_space/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/genie_space/out.test.toml +++ b/acceptance/bundle/deployment/bind/genie_space/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/job/already-managed-different/out.test.toml b/acceptance/bundle/deployment/bind/job/already-managed-different/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/job/already-managed-different/out.test.toml +++ b/acceptance/bundle/deployment/bind/job/already-managed-different/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/job/already-managed-same/out.test.toml b/acceptance/bundle/deployment/bind/job/already-managed-same/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/job/already-managed-same/out.test.toml +++ b/acceptance/bundle/deployment/bind/job/already-managed-same/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/job/engine-from-config/out.test.toml b/acceptance/bundle/deployment/bind/job/engine-from-config/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/job/engine-from-config/out.test.toml +++ b/acceptance/bundle/deployment/bind/job/engine-from-config/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/job/generate-and-bind/out.test.toml b/acceptance/bundle/deployment/bind/job/generate-and-bind/out.test.toml index f68b4a89c36..0f167effef1 100644 --- a/acceptance/bundle/deployment/bind/job/generate-and-bind/out.test.toml +++ b/acceptance/bundle/deployment/bind/job/generate-and-bind/out.test.toml @@ -1,2 +1,2 @@ Cloud = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/job/job-abort-bind/out.test.toml b/acceptance/bundle/deployment/bind/job/job-abort-bind/out.test.toml index f68b4a89c36..0f167effef1 100644 --- a/acceptance/bundle/deployment/bind/job/job-abort-bind/out.test.toml +++ b/acceptance/bundle/deployment/bind/job/job-abort-bind/out.test.toml @@ -1,2 +1,2 @@ Cloud = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/job/job-spark-python-task/out.test.toml b/acceptance/bundle/deployment/bind/job/job-spark-python-task/out.test.toml index f68b4a89c36..0f167effef1 100644 --- a/acceptance/bundle/deployment/bind/job/job-spark-python-task/out.test.toml +++ b/acceptance/bundle/deployment/bind/job/job-spark-python-task/out.test.toml @@ -1,2 +1,2 @@ Cloud = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/job/noop-job/out.test.toml b/acceptance/bundle/deployment/bind/job/noop-job/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/job/noop-job/out.test.toml +++ b/acceptance/bundle/deployment/bind/job/noop-job/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/job/noop-job/script b/acceptance/bundle/deployment/bind/job/noop-job/script index 325a38f4726..adafb1c4da4 100644 --- a/acceptance/bundle/deployment/bind/job/noop-job/script +++ b/acceptance/bundle/deployment/bind/job/noop-job/script @@ -6,4 +6,4 @@ trace $CLI bundle deployment bind job_1 $job_id --auto-approve trace $CLI bundle deploy # there is a difference: in terraform there is also run_as entry -trace $CLI jobs get $job_id --output json > out.job.json +trace $CLI jobs get $job_id --output json | nostamp > out.job.json diff --git a/acceptance/bundle/deployment/bind/job/python-job/out.test.toml b/acceptance/bundle/deployment/bind/job/python-job/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/job/python-job/out.test.toml +++ b/acceptance/bundle/deployment/bind/job/python-job/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/job/python-job/script b/acceptance/bundle/deployment/bind/job/python-job/script index b915a7243f0..48a5536e337 100644 --- a/acceptance/bundle/deployment/bind/job/python-job/script +++ b/acceptance/bundle/deployment/bind/job/python-job/script @@ -7,4 +7,4 @@ trace $UV_RUN $CLI bundle deployment bind job_1 $job_id --auto-approve trace $UV_RUN $CLI bundle deploy -trace $CLI jobs get $job_id --output json > out.job.json +trace $CLI jobs get $job_id --output json | nostamp > out.job.json diff --git a/acceptance/bundle/deployment/bind/job/stale-state/out.test.toml b/acceptance/bundle/deployment/bind/job/stale-state/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/job/stale-state/out.test.toml +++ b/acceptance/bundle/deployment/bind/job/stale-state/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/job/unreadable-state/out.test.toml b/acceptance/bundle/deployment/bind/job/unreadable-state/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/job/unreadable-state/out.test.toml +++ b/acceptance/bundle/deployment/bind/job/unreadable-state/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/mcp_service/out.test.toml b/acceptance/bundle/deployment/bind/mcp_service/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/mcp_service/out.test.toml +++ b/acceptance/bundle/deployment/bind/mcp_service/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/model-serving-endpoint/out.test.toml b/acceptance/bundle/deployment/bind/model-serving-endpoint/out.test.toml index f68b4a89c36..0f167effef1 100644 --- a/acceptance/bundle/deployment/bind/model-serving-endpoint/out.test.toml +++ b/acceptance/bundle/deployment/bind/model-serving-endpoint/out.test.toml @@ -1,2 +1,2 @@ Cloud = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/model_provider_service/out.test.toml b/acceptance/bundle/deployment/bind/model_provider_service/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/model_provider_service/out.test.toml +++ b/acceptance/bundle/deployment/bind/model_provider_service/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/model_service/out.test.toml b/acceptance/bundle/deployment/bind/model_service/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/model_service/out.test.toml +++ b/acceptance/bundle/deployment/bind/model_service/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/pipelines/recreate/out.test.toml b/acceptance/bundle/deployment/bind/pipelines/recreate/out.test.toml index f68b4a89c36..0f167effef1 100644 --- a/acceptance/bundle/deployment/bind/pipelines/recreate/out.test.toml +++ b/acceptance/bundle/deployment/bind/pipelines/recreate/out.test.toml @@ -1,2 +1,2 @@ Cloud = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/pipelines/recreate/output.txt b/acceptance/bundle/deployment/bind/pipelines/recreate/output.txt index f114763c887..e837de7f5f0 100644 --- a/acceptance/bundle/deployment/bind/pipelines/recreate/output.txt +++ b/acceptance/bundle/deployment/bind/pipelines/recreate/output.txt @@ -34,4 +34,4 @@ Recreated pipelines.foo Files: 0 uploaded, 0 deleted Resources: 1 created, 0 changed, 1 deleted, 0 unchanged ->>> print_requests.py ^//workspace/ ^//telemetry-ext +>>> print_requests.py --nostamp ^//workspace/ ^//telemetry-ext diff --git a/acceptance/bundle/deployment/bind/pipelines/recreate/script b/acceptance/bundle/deployment/bind/pipelines/recreate/script index 8d02246da3b..a8cddf2dc5f 100644 --- a/acceptance/bundle/deployment/bind/pipelines/recreate/script +++ b/acceptance/bundle/deployment/bind/pipelines/recreate/script @@ -19,4 +19,4 @@ trace musterr $CLI bundle deploy rm -f "$OUT_REQUESTS" trace $CLI bundle deploy --auto-approve -trace print_requests.py '^//workspace/' '^//telemetry-ext' > out.deploy.requests.json +trace print_requests.py --nostamp '^//workspace/' '^//telemetry-ext' > out.deploy.requests.json diff --git a/acceptance/bundle/deployment/bind/pipelines/update/out.test.toml b/acceptance/bundle/deployment/bind/pipelines/update/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/pipelines/update/out.test.toml +++ b/acceptance/bundle/deployment/bind/pipelines/update/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/pipelines/update/output.txt b/acceptance/bundle/deployment/bind/pipelines/update/output.txt index 732d4b8795c..29e3c78f22b 100644 --- a/acceptance/bundle/deployment/bind/pipelines/update/output.txt +++ b/acceptance/bundle/deployment/bind/pipelines/update/output.txt @@ -19,4 +19,4 @@ Updated pipelines.foo Files: 6 uploaded, 0 deleted Resources: 0 created, 1 changed, 0 deleted, 0 unchanged ->>> print_requests.py ^//workspace/import ^//workspace/delete ^//telemetry-ext +>>> print_requests.py --nostamp ^//workspace/import ^//workspace/delete ^//telemetry-ext diff --git a/acceptance/bundle/deployment/bind/pipelines/update/script b/acceptance/bundle/deployment/bind/pipelines/update/script index 36c80f00f5d..68d98a43e6b 100644 --- a/acceptance/bundle/deployment/bind/pipelines/update/script +++ b/acceptance/bundle/deployment/bind/pipelines/update/script @@ -14,4 +14,4 @@ trace $CLI bundle plan rm -f "$OUT_REQUESTS" trace $CLI bundle deploy --auto-approve -trace print_requests.py '^//workspace/import' '^//workspace/delete' '^//telemetry-ext' > out.deploy.requests.json +trace print_requests.py --nostamp '^//workspace/import' '^//workspace/delete' '^//telemetry-ext' > out.deploy.requests.json diff --git a/acceptance/bundle/deployment/bind/postgres_database/out.test.toml b/acceptance/bundle/deployment/bind/postgres_database/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/postgres_database/out.test.toml +++ b/acceptance/bundle/deployment/bind/postgres_database/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/postgres_role/out.test.toml b/acceptance/bundle/deployment/bind/postgres_role/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/postgres_role/out.test.toml +++ b/acceptance/bundle/deployment/bind/postgres_role/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/postgres_snapshot_schedule/out.test.toml b/acceptance/bundle/deployment/bind/postgres_snapshot_schedule/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/postgres_snapshot_schedule/out.test.toml +++ b/acceptance/bundle/deployment/bind/postgres_snapshot_schedule/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/quality-monitor/out.test.toml b/acceptance/bundle/deployment/bind/quality-monitor/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/quality-monitor/out.test.toml +++ b/acceptance/bundle/deployment/bind/quality-monitor/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/registered-model/out.test.toml b/acceptance/bundle/deployment/bind/registered-model/out.test.toml index f68b4a89c36..0f167effef1 100644 --- a/acceptance/bundle/deployment/bind/registered-model/out.test.toml +++ b/acceptance/bundle/deployment/bind/registered-model/out.test.toml @@ -1,2 +1,2 @@ Cloud = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/schema/out.test.toml b/acceptance/bundle/deployment/bind/schema/out.test.toml index f68b4a89c36..0f167effef1 100644 --- a/acceptance/bundle/deployment/bind/schema/out.test.toml +++ b/acceptance/bundle/deployment/bind/schema/out.test.toml @@ -1,2 +1,2 @@ Cloud = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/secret-scope/out.test.toml b/acceptance/bundle/deployment/bind/secret-scope/out.test.toml index f68b4a89c36..0f167effef1 100644 --- a/acceptance/bundle/deployment/bind/secret-scope/out.test.toml +++ b/acceptance/bundle/deployment/bind/secret-scope/out.test.toml @@ -1,2 +1,2 @@ Cloud = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/sql_warehouse/out.test.toml b/acceptance/bundle/deployment/bind/sql_warehouse/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/bind/sql_warehouse/out.test.toml +++ b/acceptance/bundle/deployment/bind/sql_warehouse/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/test.toml b/acceptance/bundle/deployment/bind/test.toml deleted file mode 100644 index b693e4ded26..00000000000 --- a/acceptance/bundle/deployment/bind/test.toml +++ /dev/null @@ -1,2 +0,0 @@ -# Bind operations are not yet supported by the Deployment Metadata Service (DMS) -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/vector_search_endpoint/out.test.toml b/acceptance/bundle/deployment/bind/vector_search_endpoint/out.test.toml index f68b4a89c36..0f167effef1 100644 --- a/acceptance/bundle/deployment/bind/vector_search_endpoint/out.test.toml +++ b/acceptance/bundle/deployment/bind/vector_search_endpoint/out.test.toml @@ -1,2 +1,2 @@ Cloud = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/vector_search_index/out.test.toml b/acceptance/bundle/deployment/bind/vector_search_index/out.test.toml index c32648754d8..8bfa768b35b 100644 --- a/acceptance/bundle/deployment/bind/vector_search_index/out.test.toml +++ b/acceptance/bundle/deployment/bind/vector_search_index/out.test.toml @@ -1,3 +1,3 @@ Cloud = true CloudSlow = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/bind/volume/out.test.toml b/acceptance/bundle/deployment/bind/volume/out.test.toml index f68b4a89c36..0f167effef1 100644 --- a/acceptance/bundle/deployment/bind/volume/out.test.toml +++ b/acceptance/bundle/deployment/bind/volume/out.test.toml @@ -1,2 +1,2 @@ Cloud = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/unbind/engine-from-config/out.test.toml b/acceptance/bundle/deployment/unbind/engine-from-config/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/unbind/engine-from-config/out.test.toml +++ b/acceptance/bundle/deployment/unbind/engine-from-config/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/unbind/grants/out.test.toml b/acceptance/bundle/deployment/unbind/grants/out.test.toml index f68b4a89c36..0f167effef1 100644 --- a/acceptance/bundle/deployment/unbind/grants/out.test.toml +++ b/acceptance/bundle/deployment/unbind/grants/out.test.toml @@ -1,2 +1,2 @@ Cloud = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/unbind/job/out.test.toml b/acceptance/bundle/deployment/unbind/job/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/unbind/job/out.test.toml +++ b/acceptance/bundle/deployment/unbind/job/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/unbind/job/script b/acceptance/bundle/deployment/unbind/job/script index 061aadcfabf..657d3a0b34b 100644 --- a/acceptance/bundle/deployment/unbind/job/script +++ b/acceptance/bundle/deployment/unbind/job/script @@ -6,4 +6,4 @@ trace $CLI bundle deployment unbind job_1 --var "job_name=My Job" trace $CLI bundle deploy --var "job_name=Updated Job" -trace $CLI jobs get $job_id --output json +trace $CLI jobs get $job_id --output json | nostamp diff --git a/acceptance/bundle/deployment/unbind/permissions/out.test.toml b/acceptance/bundle/deployment/unbind/permissions/out.test.toml index f68b4a89c36..0f167effef1 100644 --- a/acceptance/bundle/deployment/unbind/permissions/out.test.toml +++ b/acceptance/bundle/deployment/unbind/permissions/out.test.toml @@ -1,2 +1,2 @@ Cloud = true -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/unbind/python-job/out.test.toml b/acceptance/bundle/deployment/unbind/python-job/out.test.toml index 19b5b15d11f..a927a5fbc06 100644 --- a/acceptance/bundle/deployment/unbind/python-job/out.test.toml +++ b/acceptance/bundle/deployment/unbind/python-job/out.test.toml @@ -1,2 +1,2 @@ Cloud = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deployment/unbind/python-job/script b/acceptance/bundle/deployment/unbind/python-job/script index c3b4dba3417..59abe80d8a5 100644 --- a/acceptance/bundle/deployment/unbind/python-job/script +++ b/acceptance/bundle/deployment/unbind/python-job/script @@ -8,4 +8,4 @@ trace $UV_RUN $CLI bundle deployment unbind job_1 --var "job_name=My Job" trace $UV_RUN $CLI bundle deploy --var "job_name=Updated Job" -trace $CLI jobs get $job_id --output json +trace $CLI jobs get $job_id --output json | nostamp diff --git a/acceptance/bundle/deployment/unbind/test.toml b/acceptance/bundle/deployment/unbind/test.toml deleted file mode 100644 index 9f5f5d49a05..00000000000 --- a/acceptance/bundle/deployment/unbind/test.toml +++ /dev/null @@ -1,2 +0,0 @@ -# Unbind operations are not yet supported by the Deployment Metadata Service (DMS) -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/dms/bind-unbind-unsupported/output.txt b/acceptance/bundle/dms/bind-unbind-unsupported/output.txt deleted file mode 100644 index e2781fef6fb..00000000000 --- a/acceptance/bundle/dms/bind-unbind-unsupported/output.txt +++ /dev/null @@ -1,20 +0,0 @@ - -=== bind is refused while recording deployment history ->>> musterr [CLI] bundle deployment bind foo [JOB_ID] -Error: bind is not supported for a bundle target that records deployment history - - -=== Unbind is allowed for file-backed history state ->>> [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/dms-bind-unbind-[UNIQUE_NAME]/default/files... -Created jobs.foo -Files: 2 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged - ->>> [CLI] bundle deployment unbind foo - ->>> jq {features, state} .databricks/bundle/default/resources.json -{ - "features": null, - "state": {} -} diff --git a/acceptance/bundle/dms/bind-unbind-unsupported/script b/acceptance/bundle/dms/bind-unbind-unsupported/script deleted file mode 100644 index 7437d908eb2..00000000000 --- a/acceptance/bundle/dms/bind-unbind-unsupported/script +++ /dev/null @@ -1,15 +0,0 @@ -envsubst < databricks.yml.tmpl > databricks.yml - -# The gate that refuses bind while recording deployment history is on the config, so it fires -# before any deploy. Create a real workspace job so bind gets past fetching the resource and -# reaches the gate, instead of failing because the resource does not exist. -title "bind is refused while recording deployment history" -job_id=$($CLI jobs create --json '{"name": "bind-target-'$UNIQUE_NAME'"}' | jq -r '.job_id') -add_repl "$job_id" JOB_ID -trace musterr $CLI bundle deployment bind foo "$job_id" - -# File state remains writable even when it carries the history marker. -title "Unbind is allowed for file-backed history state" -trace $CLI bundle deploy -trace $CLI bundle deployment unbind foo -trace jq '{features, state}' .databricks/bundle/default/resources.json diff --git a/acceptance/bundle/dms/bind-unbind-unsupported/test.toml b/acceptance/bundle/dms/bind-unbind-unsupported/test.toml deleted file mode 100644 index 140ee938238..00000000000 --- a/acceptance/bundle/dms/bind-unbind-unsupported/test.toml +++ /dev/null @@ -1,4 +0,0 @@ -RecordRequests = false -# bind/unbind refusal is a client-side gate on the recording config; it needs no real -# workspace, so this stays local-only rather than inheriting the suite's cloud run. -Cloud = false diff --git a/acceptance/bundle/dms/bind-unbind-unsupported/databricks.yml.tmpl b/acceptance/bundle/dms/bind-unbind/databricks.yml.tmpl similarity index 100% rename from acceptance/bundle/dms/bind-unbind-unsupported/databricks.yml.tmpl rename to acceptance/bundle/dms/bind-unbind/databricks.yml.tmpl diff --git a/acceptance/bundle/dms/bind-unbind-unsupported/out.test.toml b/acceptance/bundle/dms/bind-unbind/out.test.toml similarity index 100% rename from acceptance/bundle/dms/bind-unbind-unsupported/out.test.toml rename to acceptance/bundle/dms/bind-unbind/out.test.toml diff --git a/acceptance/bundle/dms/bind-unbind/output.txt b/acceptance/bundle/dms/bind-unbind/output.txt new file mode 100644 index 00000000000..d6d3fcd36e6 --- /dev/null +++ b/acceptance/bundle/dms/bind-unbind/output.txt @@ -0,0 +1,63 @@ + +=== Bind an existing job with deployment history enabled +>>> [CLI] bundle deployment bind foo [JOB_ID] --auto-approve +Successfully bound job with an id '[JOB_ID]' +Run 'bundle deploy' to deploy changes to your workspace + +=== Deploy keeps the bound job ID and enables shadow history +>>> [CLI] bundle deploy +Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/dms-bind-unbind-[UNIQUE_NAME]/default/files... +Updated jobs.foo +Files: 2 uploaded, 0 deleted +Resources: 0 created, 1 changed, 0 deleted, 0 unchanged + +>>> jq {features, resource_id: .state["resources.jobs.foo"].__id__} .databricks/bundle/default/resources.json +{ + "features": { + "deployment_history_shadow": {} + }, + "resource_id": "[JOB_ID]" +} + +=== Unbind preserves the shadow history marker and leaves the job intact +>>> [CLI] bundle deployment unbind foo + +>>> jq {features, state} .databricks/bundle/default/resources.json +{ + "features": { + "deployment_history_shadow": {} + }, + "state": {} +} + +>>> [CLI] jobs get [JOB_ID] +{ + "job_id": [JOB_ID] +} + +=== Rebind preserves the existing shadow history marker +>>> [CLI] bundle deployment bind foo [JOB_ID] --auto-approve +Successfully bound job with an id '[JOB_ID]' +Run 'bundle deploy' to deploy changes to your workspace + +>>> jq {features, resource_id: .state["resources.jobs.foo"].__id__} .databricks/bundle/default/resources.json +{ + "features": { + "deployment_history_shadow": {} + }, + "resource_id": "[JOB_ID]" +} + +=== A subsequent deploy continues managing the same job +>>> [CLI] bundle deploy +Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/dms-bind-unbind-[UNIQUE_NAME]/default/files... +Files: 0 uploaded, 0 deleted +Resources: 0 created, 0 changed, 0 deleted, 1 unchanged + +>>> jq {features, resource_id: .state["resources.jobs.foo"].__id__} .databricks/bundle/default/resources.json +{ + "features": { + "deployment_history_shadow": {} + }, + "resource_id": "[JOB_ID]" +} diff --git a/acceptance/bundle/dms/bind-unbind/script b/acceptance/bundle/dms/bind-unbind/script new file mode 100644 index 00000000000..32fab5aa0e8 --- /dev/null +++ b/acceptance/bundle/dms/bind-unbind/script @@ -0,0 +1,23 @@ +envsubst < databricks.yml.tmpl > databricks.yml + +title "Bind an existing job with deployment history enabled" +job_id=$($CLI jobs create --json '{"name": "bind-target-'$UNIQUE_NAME'"}' | jq -r '.job_id') +add_repl "$job_id" JOB_ID +trace $CLI bundle deployment bind foo "$job_id" --auto-approve + +title "Deploy keeps the bound job ID and enables shadow history" +trace $CLI bundle deploy +trace jq '{features, resource_id: .state["resources.jobs.foo"].__id__}' .databricks/bundle/default/resources.json + +title "Unbind preserves the shadow history marker and leaves the job intact" +trace $CLI bundle deployment unbind foo +trace jq '{features, state}' .databricks/bundle/default/resources.json +trace $CLI jobs get "$job_id" | jq '{job_id}' + +title "Rebind preserves the existing shadow history marker" +trace $CLI bundle deployment bind foo "$job_id" --auto-approve +trace jq '{features, resource_id: .state["resources.jobs.foo"].__id__}' .databricks/bundle/default/resources.json + +title "A subsequent deploy continues managing the same job" +trace $CLI bundle deploy +trace jq '{features, resource_id: .state["resources.jobs.foo"].__id__}' .databricks/bundle/default/resources.json diff --git a/acceptance/bundle/dms/bind-unbind/test.toml b/acceptance/bundle/dms/bind-unbind/test.toml new file mode 100644 index 00000000000..f620acda97e --- /dev/null +++ b/acceptance/bundle/dms/bind-unbind/test.toml @@ -0,0 +1,3 @@ +RecordRequests = false +# Verify shadow history markers and resource IDs across bind, deploy, unbind, and rebind. +Cloud = false diff --git a/acceptance/bundle/resources/postgres_databases/replace_existing/out.test.toml b/acceptance/bundle/resources/postgres_databases/replace_existing/out.test.toml index a026907d175..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_databases/replace_existing/out.test.toml +++ b/acceptance/bundle/resources/postgres_databases/replace_existing/out.test.toml @@ -1,4 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_databases/replace_existing/test.toml b/acceptance/bundle/resources/postgres_databases/replace_existing/test.toml deleted file mode 100644 index f77da87a11f..00000000000 --- a/acceptance/bundle/resources/postgres_databases/replace_existing/test.toml +++ /dev/null @@ -1,3 +0,0 @@ -# `bundle unbind` does not yet drop the resource from what the deployment metadata service -# reports, so the plan after the unbind still sees the database as tracked. -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/resources/postgres_roles/inherited-role-bind/out.test.toml b/acceptance/bundle/resources/postgres_roles/inherited-role-bind/out.test.toml index 18f5005f731..0faf51e59a4 100644 --- a/acceptance/bundle/resources/postgres_roles/inherited-role-bind/out.test.toml +++ b/acceptance/bundle/resources/postgres_roles/inherited-role-bind/out.test.toml @@ -1,4 +1,4 @@ Cloud = false CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_roles/inherited-role-bind/test.toml b/acceptance/bundle/resources/postgres_roles/inherited-role-bind/test.toml index 18dc918d1e1..fdd5a81bc55 100644 --- a/acceptance/bundle/resources/postgres_roles/inherited-role-bind/test.toml +++ b/acceptance/bundle/resources/postgres_roles/inherited-role-bind/test.toml @@ -7,7 +7,3 @@ RecordRequests = false Cloud = false # bind/deploy are engine-agnostic here; run on direct for a single stable output. - -# bind and unbind refuse to run when deployment history recording is on, so the -# escape hatch this test covers is not available there yet. -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/resources/postgres_roles/inherited-role-conflict/out.test.toml b/acceptance/bundle/resources/postgres_roles/inherited-role-conflict/out.test.toml index 18f5005f731..0faf51e59a4 100644 --- a/acceptance/bundle/resources/postgres_roles/inherited-role-conflict/out.test.toml +++ b/acceptance/bundle/resources/postgres_roles/inherited-role-conflict/out.test.toml @@ -1,4 +1,4 @@ Cloud = false CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_roles/inherited-role-conflict/test.toml b/acceptance/bundle/resources/postgres_roles/inherited-role-conflict/test.toml index 02597575447..bdc5c5a9da5 100644 --- a/acceptance/bundle/resources/postgres_roles/inherited-role-conflict/test.toml +++ b/acceptance/bundle/resources/postgres_roles/inherited-role-conflict/test.toml @@ -5,7 +5,3 @@ Badness = "Reproduces the conflict a bundle hits when it declares a Postgres rol Cloud = false # Deploy error wording differs between engines; the conflict itself is engine-agnostic. - -# `bundle unbind` does not yet drop the resource from what the deployment metadata service -# reports, so the role staged above still looks tracked. -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/resources/postgres_roles/replace_existing/out.test.toml b/acceptance/bundle/resources/postgres_roles/replace_existing/out.test.toml index a026907d175..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_roles/replace_existing/out.test.toml +++ b/acceptance/bundle/resources/postgres_roles/replace_existing/out.test.toml @@ -1,4 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DMS = [""] +EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_roles/replace_existing/test.toml b/acceptance/bundle/resources/postgres_roles/replace_existing/test.toml deleted file mode 100644 index ca4bbbef122..00000000000 --- a/acceptance/bundle/resources/postgres_roles/replace_existing/test.toml +++ /dev/null @@ -1,3 +0,0 @@ -# `bundle unbind` does not yet drop the resource from what the deployment metadata service -# reports, so the plan after the unbind still sees the role as tracked. -EnvMatrix.DMS = [""] diff --git a/bundle/direct/bind.go b/bundle/direct/bind.go index 7b4aca63ee6..7fbf7ede662 100644 --- a/bundle/direct/bind.go +++ b/bundle/direct/bind.go @@ -2,7 +2,6 @@ package direct import ( "context" - "errors" "fmt" "os" "strings" @@ -63,8 +62,6 @@ type BindResult struct { // Call Finalize to commit the state or Cancel to discard. func (b *DeploymentBundle) Bind(ctx context.Context, client *databricks.WorkspaceClient, configRoot *config.Root, statePath, resourceKey, resourceID string) (*BindResult, error) { // Check if the resource is already managed (bound to a different ID) - // The state is opened without a DMS client, so the writes below record nothing; - // phases.Bind and phases.Unbind refuse to run at all when recording is enabled. var checkStateDB dstate.DeploymentState if err := checkStateDB.Open(ctx, statePath, dstate.ReadingFile, dstate.WithRecovery(true), dstate.OpenDmsArgs{}); err != nil { // State that cannot be read is not the same as state without a binding: @@ -95,11 +92,15 @@ func (b *DeploymentBundle) Bind(ctx context.Context, client *databricks.Workspac } // Open temp state - err := b.StateDB.Open(ctx, tmpStatePath, dstate.WritingFile, dstate.WithRecovery(false), dstate.OpenDmsArgs{}) + err := b.StateDB.Open(ctx, tmpStatePath, dstate.ReadingFile, dstate.WithRecovery(false), dstate.OpenDmsArgs{}) if err != nil { os.Remove(tmpStatePath) return nil, err } + if err := b.StateDB.UpgradeToWrite(); err != nil { + os.Remove(tmpStatePath) + return nil, err + } // Save state with ID and empty state (like migrate does) err = b.StateDB.SaveState(ctx, resourceKey, resourceID, struct{}{}, nil) @@ -167,11 +168,15 @@ func (b *DeploymentBundle) Bind(ctx context.Context, client *databricks.Workspac return nil, fmt.Errorf("compacting state: %w", err) } - err = b.StateDB.Open(ctx, tmpStatePath, dstate.WritingFile, dstate.WithRecovery(true), dstate.OpenDmsArgs{}) + err = b.StateDB.Open(ctx, tmpStatePath, dstate.ReadingFile, dstate.WithRecovery(true), dstate.OpenDmsArgs{}) if err != nil { os.Remove(tmpStatePath) return nil, err } + if err := b.StateDB.UpgradeToWrite(); err != nil { + os.Remove(tmpStatePath) + return nil, err + } err = b.StateDB.SaveState(ctx, resourceKey, resourceID, compacted, dependsOn) if err != nil { @@ -237,16 +242,15 @@ func (result *BindResult) Cancel() { // Unbind removes a resource from direct engine state without deleting // the workspace resource. Also removes associated permissions/grants entries. func (b *DeploymentBundle) Unbind(ctx context.Context, statePath, resourceKey string) error { - err := b.StateDB.Open(ctx, statePath, dstate.WritingFile, dstate.WithRecovery(true), dstate.OpenDmsArgs{}) - if err != nil { - if errors.Is(err, dstate.ErrUnsettingRecording) { - return errors.New("unbind is not supported for a bundle target that records deployment history") - } + if err := b.StateDB.Open(ctx, statePath, dstate.ReadingFile, dstate.WithRecovery(true), dstate.OpenDmsArgs{}); err != nil { + return err + } + if err := b.StateDB.UpgradeToWrite(); err != nil { return err } // Delete the main resource - err = b.StateDB.DeleteState(ctx, resourceKey, false) + err := b.StateDB.DeleteState(ctx, resourceKey, false) if err != nil { return err } diff --git a/bundle/phases/bind.go b/bundle/phases/bind.go index 7646735f903..36c4fcf56b4 100644 --- a/bundle/phases/bind.go +++ b/bundle/phases/bind.go @@ -12,7 +12,6 @@ import ( "github.com/databricks/cli/bundle/config/engine" "github.com/databricks/cli/bundle/deploy/lock" "github.com/databricks/cli/bundle/deployplan" - bundleenv "github.com/databricks/cli/bundle/env" "github.com/databricks/cli/bundle/statemgmt" "github.com/databricks/cli/libs/agent" "github.com/databricks/cli/libs/cmdio" @@ -48,15 +47,6 @@ func Bind(ctx context.Context, b *bundle.Bundle, opts *BindOptions, stateDesc *s return } - var configured *bool - if b.Config.Experimental != nil { - configured = b.Config.Experimental.DeploymentHistory - } - if stateDesc.IsDMS() || bundleenv.RecordsDeploymentHistory(ctx, configured) { - logdiag.LogError(ctx, errors.New("bind is not supported for a bundle target that records deployment history")) - return - } - // Direct engine: import into temp state, run plan, check for changes. resourceKey := fmt.Sprintf("resources.%s.%s", opts.Group, opts.ResourceKey) _, statePath := b.StateFilenameDirect(ctx)