diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index d7582249906..b0e084950c2 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -111,16 +111,14 @@ jobs: runner: labels: macos-latest - # Each cell runs the suite once. envfilter picks the variants it covers: without the - # recording filter, the direct cell would run every bundle test twice, since - # bundle/test.toml matrixes deployment-history recording on top of the engine. + # Each cell runs the suite once. envfilter picks the variants it covers: the plain + # cell excludes the deployment-history recording variant (DMS=true), which the + # directdms cell covers, so bundle/test.toml's DMS matrix does not run every test twice. deployment: - - name: "terraform" - envfilter: "DATABRICKS_BUNDLE_ENGINE=terraform" - name: "direct" - envfilter: "DATABRICKS_BUNDLE_ENGINE=direct,DMS=" + envfilter: "DMS=" - name: "directdms" - envfilter: "DATABRICKS_BUNDLE_ENGINE=direct,DMS=true" + envfilter: "DMS=true" # Include "event_name" in the matrix so we can include/exclude based on it. event: diff --git a/.nextchanges/notable-changes/remove-terraform-engine.md b/.nextchanges/notable-changes/remove-terraform-engine.md new file mode 100644 index 00000000000..2e7398f8eda --- /dev/null +++ b/.nextchanges/notable-changes/remove-terraform-engine.md @@ -0,0 +1 @@ +* Remove the Terraform deployment engine. Bundles pinning `engine: terraform` (or `DATABRICKS_BUNDLE_ENGINE=terraform`) now error and should either move to the direct engine or downgrade to CLI v1.18.x. ([#6746](https://github.com/databricks/cli/pull/6746)) diff --git a/NOTICE b/NOTICE index 4b9c9991f20..c0810b6fa32 100644 --- a/NOTICE +++ b/NOTICE @@ -25,22 +25,10 @@ hashicorp/go-version - https://github.com/hashicorp/go-version Copyright 2014 HashiCorp, Inc. License - https://github.com/hashicorp/go-version/blob/main/LICENSE -hashicorp/hc-install - https://github.com/hashicorp/hc-install -Copyright 2020 HashiCorp, Inc. -License - https://github.com/hashicorp/hc-install/blob/main/LICENSE - -hashicorp/terraform-exec - https://github.com/hashicorp/terraform-exec -Copyright 2020 HashiCorp, Inc. -License - https://github.com/hashicorp/terraform-exec/blob/main/LICENSE - hashicorp/terraform-json - https://github.com/hashicorp/terraform-json Copyright 2019 HashiCorp, Inc. License - https://github.com/hashicorp/terraform-json/blob/main/LICENSE -hashicorp/terraform - https://github.com/hashicorp/terraform -Copyright 2014 HashiCorp, Inc. -License - https://github.com/hashicorp/terraform/blob/v1.5.5/LICENSE - --- This Software contains code from the following open source projects, licensed under the BSD (2-clause) license: diff --git a/acceptance/apps/deploy/bundle-no-args-with-flags/out.test.toml b/acceptance/apps/deploy/bundle-no-args-with-flags/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/apps/deploy/bundle-no-args-with-flags/out.test.toml +++ b/acceptance/apps/deploy/bundle-no-args-with-flags/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/apps/deploy/bundle-no-args-with-flags/test.toml b/acceptance/apps/deploy/bundle-no-args-with-flags/test.toml index 8cbeae3f70f..8573990ba90 100644 --- a/acceptance/apps/deploy/bundle-no-args-with-flags/test.toml +++ b/acceptance/apps/deploy/bundle-no-args-with-flags/test.toml @@ -4,7 +4,6 @@ Ignore = [ '.databricks', ] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] [[Server]] Pattern = "POST /api/2.0/apps/myapp/deployments" diff --git a/acceptance/apps/deploy/bundle-no-args/out.test.toml b/acceptance/apps/deploy/bundle-no-args/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/apps/deploy/bundle-no-args/out.test.toml +++ b/acceptance/apps/deploy/bundle-no-args/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/apps/deploy/bundle-no-args/test.toml b/acceptance/apps/deploy/bundle-no-args/test.toml index 8cbeae3f70f..8573990ba90 100644 --- a/acceptance/apps/deploy/bundle-no-args/test.toml +++ b/acceptance/apps/deploy/bundle-no-args/test.toml @@ -4,7 +4,6 @@ Ignore = [ '.databricks', ] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] [[Server]] Pattern = "POST /api/2.0/apps/myapp/deployments" diff --git a/acceptance/apps/deploy/bundle-with-appname/out.test.toml b/acceptance/apps/deploy/bundle-with-appname/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/apps/deploy/bundle-with-appname/out.test.toml +++ b/acceptance/apps/deploy/bundle-with-appname/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/apps/deploy/no-bundle-no-args/out.test.toml b/acceptance/apps/deploy/no-bundle-no-args/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/apps/deploy/no-bundle-no-args/out.test.toml +++ b/acceptance/apps/deploy/no-bundle-no-args/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/apps/deploy/no-bundle-with-appname/out.test.toml b/acceptance/apps/deploy/no-bundle-with-appname/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/apps/deploy/no-bundle-with-appname/out.test.toml +++ b/acceptance/apps/deploy/no-bundle-with-appname/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/auth/bundle_and_profile/out.test.toml b/acceptance/auth/bundle_and_profile/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/auth/bundle_and_profile/out.test.toml +++ b/acceptance/auth/bundle_and_profile/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/auth/bundle_default_profile/out.test.toml b/acceptance/auth/bundle_default_profile/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/auth/bundle_default_profile/out.test.toml +++ b/acceptance/auth/bundle_default_profile/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/auth/credentials/basic/out.test.toml b/acceptance/auth/credentials/basic/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/auth/credentials/basic/out.test.toml +++ b/acceptance/auth/credentials/basic/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/auth/credentials/oauth/out.test.toml b/acceptance/auth/credentials/oauth/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/auth/credentials/oauth/out.test.toml +++ b/acceptance/auth/credentials/oauth/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/auth/credentials/pat/out.test.toml b/acceptance/auth/credentials/pat/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/auth/credentials/pat/out.test.toml +++ b/acceptance/auth/credentials/pat/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/auth/host-metadata-cache/out.test.toml b/acceptance/auth/host-metadata-cache/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/auth/host-metadata-cache/out.test.toml +++ b/acceptance/auth/host-metadata-cache/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/bin/print_state.py b/acceptance/bin/print_state.py index 7eb9ea89c79..3bbd80f972c 100755 --- a/acceptance/bin/print_state.py +++ b/acceptance/bin/print_state.py @@ -220,9 +220,10 @@ def main(): for filename in get_state_files(args.target, args.backup): if not os.path.exists(filename): continue - # Recording only applies to the direct engine, so a terraform run prints the file as-is. + # Recording only applies to direct-engine state; a terraform state file + # (e.g. one awaiting migration) is printed as-is. recording = os.environ.get("DATABRICKS_BUNDLE_DEPLOYMENT_HISTORY") == "true" - terraform = os.environ.get("DATABRICKS_BUNDLE_ENGINE") == "terraform" + terraform = "terraform.tfstate" in filename if recording and not terraform and not args.no_dms: print_recorded_state(filename, args.target) else: diff --git a/acceptance/bin/read_state.py b/acceptance/bin/read_state.py index 9751fbb6f54..98bd74b4607 100755 --- a/acceptance/bin/read_state.py +++ b/acceptance/bin/read_state.py @@ -79,7 +79,5 @@ def print_resource_recorded(group, name, *attrs): if os.environ.get("DATABRICKS_BUNDLE_DEPLOYMENT_HISTORY") == "true": print_resource_recorded(*sys.argv[1:]) -elif os.environ.get("DATABRICKS_BUNDLE_ENGINE", "").startswith("direct"): - print_resource_direct(*sys.argv[1:]) else: - print_resource_terraform(*sys.argv[1:]) + print_resource_direct(*sys.argv[1:]) diff --git a/acceptance/bundle/apps/app_yaml/out.test.toml b/acceptance/bundle/apps/app_yaml/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/apps/app_yaml/out.test.toml +++ b/acceptance/bundle/apps/app_yaml/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/apps/artifact_and_app_same_path/out.test.toml b/acceptance/bundle/apps/artifact_and_app_same_path/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/apps/artifact_and_app_same_path/out.test.toml +++ b/acceptance/bundle/apps/artifact_and_app_same_path/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/apps/compute_size/out.test.toml b/acceptance/bundle/apps/compute_size/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/apps/compute_size/out.test.toml +++ b/acceptance/bundle/apps/compute_size/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/apps/compute_size/out.update.terraform.txt b/acceptance/bundle/apps/compute_size/out.update.terraform.txt deleted file mode 100644 index d852c5bef2e..00000000000 --- a/acceptance/bundle/apps/compute_size/out.update.terraform.txt +++ /dev/null @@ -1,23 +0,0 @@ - ->>> errcode [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/app-compute-size-[UNIQUE_NAME]/files... -Error: terraform apply: exit status 1 - -Error: failed to update app - - with databricks_app.my_app, - on bundle.tf.json line 20, in resource.databricks_app.my_app: - 20: } - -Compute size updates are not supported in this update API. Please use the new -update API instead. - - -Files: 3 uploaded, 0 deleted - -Exit code: 1 - ->>> [CLI] apps get app-[UNIQUE_NAME] -{ - "compute_size": "LARGE" -} diff --git a/acceptance/bundle/apps/compute_size/out.update.direct.txt b/acceptance/bundle/apps/compute_size/out.update.txt similarity index 100% rename from acceptance/bundle/apps/compute_size/out.update.direct.txt rename to acceptance/bundle/apps/compute_size/out.update.txt diff --git a/acceptance/bundle/apps/compute_size/script b/acceptance/bundle/apps/compute_size/script index 5f4714ae8df..9c993bc9e28 100644 --- a/acceptance/bundle/apps/compute_size/script +++ b/acceptance/bundle/apps/compute_size/script @@ -17,4 +17,4 @@ sed -i.bak 's/compute_size: LARGE/compute_size: MEDIUM/' databricks.yml { trace errcode $CLI bundle deploy trace $CLI apps get "app-$UNIQUE_NAME" | jq '{compute_size: .compute_size}' -} &> out.update.$DATABRICKS_BUNDLE_ENGINE.txt +} &> out.update.txt diff --git a/acceptance/bundle/apps/delete_deleting/out.test.toml b/acceptance/bundle/apps/delete_deleting/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/apps/delete_deleting/out.test.toml +++ b/acceptance/bundle/apps/delete_deleting/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/apps/delete_deleting/test.toml b/acceptance/bundle/apps/delete_deleting/test.toml index e1884c34253..8b5a8c72095 100644 --- a/acceptance/bundle/apps/delete_deleting/test.toml +++ b/acceptance/bundle/apps/delete_deleting/test.toml @@ -2,6 +2,5 @@ Cloud = false RecordRequests = false # Saved-plan deploy (`--plan`) and the IsGone gone-detection are direct-engine only. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [".databricks", "databricks.yml", "plan_delete.json"] diff --git a/acceptance/bundle/apps/git_source/out.test.toml b/acceptance/bundle/apps/git_source/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/apps/git_source/out.test.toml +++ b/acceptance/bundle/apps/git_source/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/apps/job_permissions/out.after_first_deploy.terraform.txt b/acceptance/bundle/apps/job_permissions/out.after_first_deploy.terraform.txt deleted file mode 100644 index 27ba77ddaf6..00000000000 --- a/acceptance/bundle/apps/job_permissions/out.after_first_deploy.terraform.txt +++ /dev/null @@ -1 +0,0 @@ -true diff --git a/acceptance/bundle/apps/job_permissions/out.test.toml b/acceptance/bundle/apps/job_permissions/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/apps/job_permissions/out.test.toml +++ b/acceptance/bundle/apps/job_permissions/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/apps/job_permissions/script b/acceptance/bundle/apps/job_permissions/script index 50d92015c51..0acd6454365 100644 --- a/acceptance/bundle/apps/job_permissions/script +++ b/acceptance/bundle/apps/job_permissions/script @@ -13,7 +13,7 @@ has_manage_run() { } title "After first deploy" -trace has_manage_run > out.after_first_deploy.$DATABRICKS_BUNDLE_ENGINE.txt +trace has_manage_run > out.after_first_deploy.txt # This is flaky on direct, because there are (at least) two ways to complete deployment: # sequence 1: # job is deployed @@ -24,7 +24,7 @@ trace has_manage_run > out.after_first_deploy.$DATABRICKS_BUNDLE_ENGINE.txt # app is deployed, updates job permissions # job permissions are deployed # (It does not appear flaky on TF, maybe there is enough delay in one of the resources) -rm -f out.after_first_deploy.direct.txt +rm -f out.after_first_deploy.txt title "After second deploy" trace $CLI bundle deploy -qq diff --git a/acceptance/bundle/apps/job_permissions/test.toml b/acceptance/bundle/apps/job_permissions/test.toml index 24db2fe87cc..c7fc201902b 100644 --- a/acceptance/bundle/apps/job_permissions/test.toml +++ b/acceptance/bundle/apps/job_permissions/test.toml @@ -1,4 +1,2 @@ Cloud = true RecordRequests = false - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/bundle/apps/job_permissions_warning/out.test.toml b/acceptance/bundle/apps/job_permissions_warning/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/apps/job_permissions_warning/out.test.toml +++ b/acceptance/bundle/apps/job_permissions_warning/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/apps/source_code_path_update/out.test.toml b/acceptance/bundle/apps/source_code_path_update/out.test.toml index f9f4880725d..8bfa768b35b 100644 --- a/acceptance/bundle/apps/source_code_path_update/out.test.toml +++ b/acceptance/bundle/apps/source_code_path_update/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/apps/source_code_path_update/test.toml b/acceptance/bundle/apps/source_code_path_update/test.toml index 7238560f6d4..e774ab2c55d 100644 --- a/acceptance/bundle/apps/source_code_path_update/test.toml +++ b/acceptance/bundle/apps/source_code_path_update/test.toml @@ -4,7 +4,6 @@ RecordRequests = false # This regression is in the direct engine only (the bug is in InitForApply # which is only called for bundle deploy --plan on the direct engine). -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [".databricks", "databricks.yml", "databricks.yml.bak", "plan.json", "LOG.*"] diff --git a/acceptance/bundle/apps/value_from_warning/out.test.toml b/acceptance/bundle/apps/value_from_warning/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/apps/value_from_warning/out.test.toml +++ b/acceptance/bundle/apps/value_from_warning/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/ai_runtime_code_source/out.test.toml b/acceptance/bundle/artifacts/ai_runtime_code_source/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/ai_runtime_code_source/out.test.toml +++ b/acceptance/bundle/artifacts/ai_runtime_code_source/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/ai_runtime_code_source/test.toml b/acceptance/bundle/artifacts/ai_runtime_code_source/test.toml index 012e71b09e7..38ccc5f3fb2 100644 --- a/acceptance/bundle/artifacts/ai_runtime_code_source/test.toml +++ b/acceptance/bundle/artifacts/ai_runtime_code_source/test.toml @@ -6,4 +6,3 @@ Ignore = [ # The Terraform provider dropped `code_source_path` from `ai_runtime_task` in # v1.122.0, so this feature is only exercisable via the direct engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/artifacts/artifact_path_with_volume/volume_doesnot_exist/out.test.toml b/acceptance/bundle/artifacts/artifact_path_with_volume/volume_doesnot_exist/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/artifacts/artifact_path_with_volume/volume_doesnot_exist/out.test.toml +++ b/acceptance/bundle/artifacts/artifact_path_with_volume/volume_doesnot_exist/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/artifact_path_with_volume/volume_not_deployed/out.test.toml b/acceptance/bundle/artifacts/artifact_path_with_volume/volume_not_deployed/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/artifacts/artifact_path_with_volume/volume_not_deployed/out.test.toml +++ b/acceptance/bundle/artifacts/artifact_path_with_volume/volume_not_deployed/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/artifact_upload_for_volumes/out.test.toml b/acceptance/bundle/artifacts/artifact_upload_for_volumes/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/artifact_upload_for_volumes/out.test.toml +++ b/acceptance/bundle/artifacts/artifact_upload_for_volumes/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/artifact_upload_for_workspace/out.test.toml b/acceptance/bundle/artifacts/artifact_upload_for_workspace/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/artifact_upload_for_workspace/out.test.toml +++ b/acceptance/bundle/artifacts/artifact_upload_for_workspace/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/artifact_upload_with_no_library_reference/out.test.toml b/acceptance/bundle/artifacts/artifact_upload_with_no_library_reference/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/artifact_upload_with_no_library_reference/out.test.toml +++ b/acceptance/bundle/artifacts/artifact_upload_with_no_library_reference/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/artifacts_dynamic_version/out.test.toml b/acceptance/bundle/artifacts/artifacts_dynamic_version/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/artifacts_dynamic_version/out.test.toml +++ b/acceptance/bundle/artifacts/artifacts_dynamic_version/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/build_and_files/out.test.toml b/acceptance/bundle/artifacts/build_and_files/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/build_and_files/out.test.toml +++ b/acceptance/bundle/artifacts/build_and_files/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/build_and_files_whl/out.test.toml b/acceptance/bundle/artifacts/build_and_files_whl/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/build_and_files_whl/out.test.toml +++ b/acceptance/bundle/artifacts/build_and_files_whl/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/glob_exact_whl/out.test.toml b/acceptance/bundle/artifacts/glob_exact_whl/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/glob_exact_whl/out.test.toml +++ b/acceptance/bundle/artifacts/glob_exact_whl/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/globs_in_files/out.test.toml b/acceptance/bundle/artifacts/globs_in_files/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/globs_in_files/out.test.toml +++ b/acceptance/bundle/artifacts/globs_in_files/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/globs_in_files_in_include/out.test.toml b/acceptance/bundle/artifacts/globs_in_files_in_include/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/globs_in_files_in_include/out.test.toml +++ b/acceptance/bundle/artifacts/globs_in_files_in_include/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/globs_invalid/out.test.toml b/acceptance/bundle/artifacts/globs_invalid/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/globs_invalid/out.test.toml +++ b/acceptance/bundle/artifacts/globs_invalid/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/issue_3109/out.test.toml b/acceptance/bundle/artifacts/issue_3109/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/issue_3109/out.test.toml +++ b/acceptance/bundle/artifacts/issue_3109/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/nil_artifacts/out.test.toml b/acceptance/bundle/artifacts/nil_artifacts/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/nil_artifacts/out.test.toml +++ b/acceptance/bundle/artifacts/nil_artifacts/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/same_name_libraries/out.test.toml b/acceptance/bundle/artifacts/same_name_libraries/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/same_name_libraries/out.test.toml +++ b/acceptance/bundle/artifacts/same_name_libraries/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/shell/bash/out.test.toml b/acceptance/bundle/artifacts/shell/bash/out.test.toml index 56f228d004e..8c2cb31de53 100644 --- a/acceptance/bundle/artifacts/shell/bash/out.test.toml +++ b/acceptance/bundle/artifacts/shell/bash/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/shell/basic/out.test.toml b/acceptance/bundle/artifacts/shell/basic/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/shell/basic/out.test.toml +++ b/acceptance/bundle/artifacts/shell/basic/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/shell/cmd/out.test.toml b/acceptance/bundle/artifacts/shell/cmd/out.test.toml index d20c1278e95..fee5005f692 100644 --- a/acceptance/bundle/artifacts/shell/cmd/out.test.toml +++ b/acceptance/bundle/artifacts/shell/cmd/out.test.toml @@ -1,5 +1,4 @@ Cloud = false GOOS.darwin = false GOOS.linux = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/shell/default/out.test.toml b/acceptance/bundle/artifacts/shell/default/out.test.toml index 56f228d004e..8c2cb31de53 100644 --- a/acceptance/bundle/artifacts/shell/default/out.test.toml +++ b/acceptance/bundle/artifacts/shell/default/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/shell/err-bash/out.test.toml b/acceptance/bundle/artifacts/shell/err-bash/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/shell/err-bash/out.test.toml +++ b/acceptance/bundle/artifacts/shell/err-bash/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/shell/err-sh/out.test.toml b/acceptance/bundle/artifacts/shell/err-sh/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/shell/err-sh/out.test.toml +++ b/acceptance/bundle/artifacts/shell/err-sh/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/shell/invalid/out.test.toml b/acceptance/bundle/artifacts/shell/invalid/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/shell/invalid/out.test.toml +++ b/acceptance/bundle/artifacts/shell/invalid/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/shell/sh/out.test.toml b/acceptance/bundle/artifacts/shell/sh/out.test.toml index 56f228d004e..8c2cb31de53 100644 --- a/acceptance/bundle/artifacts/shell/sh/out.test.toml +++ b/acceptance/bundle/artifacts/shell/sh/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/unique_name_libraries/out.test.toml b/acceptance/bundle/artifacts/unique_name_libraries/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/unique_name_libraries/out.test.toml +++ b/acceptance/bundle/artifacts/unique_name_libraries/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/upload_multiple_libraries/out.test.toml b/acceptance/bundle/artifacts/upload_multiple_libraries/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/upload_multiple_libraries/out.test.toml +++ b/acceptance/bundle/artifacts/upload_multiple_libraries/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/whl_change_version/out.test.toml b/acceptance/bundle/artifacts/whl_change_version/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/whl_change_version/out.test.toml +++ b/acceptance/bundle/artifacts/whl_change_version/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/whl_dbfs/out.test.toml b/acceptance/bundle/artifacts/whl_dbfs/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/whl_dbfs/out.test.toml +++ b/acceptance/bundle/artifacts/whl_dbfs/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/whl_dynamic/out.plan_create.direct.json b/acceptance/bundle/artifacts/whl_dynamic/out.plan_create.json similarity index 100% rename from acceptance/bundle/artifacts/whl_dynamic/out.plan_create.direct.json rename to acceptance/bundle/artifacts/whl_dynamic/out.plan_create.json diff --git a/acceptance/bundle/artifacts/whl_dynamic/out.plan_create.terraform.json b/acceptance/bundle/artifacts/whl_dynamic/out.plan_create.terraform.json deleted file mode 100644 index d69cba6e8a6..00000000000 --- a/acceptance/bundle/artifacts/whl_dynamic/out.plan_create.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.test_job": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/artifacts/whl_dynamic/out.plan_update.direct.json b/acceptance/bundle/artifacts/whl_dynamic/out.plan_update.json similarity index 100% rename from acceptance/bundle/artifacts/whl_dynamic/out.plan_update.direct.json rename to acceptance/bundle/artifacts/whl_dynamic/out.plan_update.json diff --git a/acceptance/bundle/artifacts/whl_dynamic/out.plan_update.terraform.json b/acceptance/bundle/artifacts/whl_dynamic/out.plan_update.terraform.json deleted file mode 100644 index 843e48dca81..00000000000 --- a/acceptance/bundle/artifacts/whl_dynamic/out.plan_update.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.test_job": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/artifacts/whl_dynamic/out.test.toml b/acceptance/bundle/artifacts/whl_dynamic/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/whl_dynamic/out.test.toml +++ b/acceptance/bundle/artifacts/whl_dynamic/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/whl_dynamic/script b/acceptance/bundle/artifacts/whl_dynamic/script index 1744ce38e47..de6821397a3 100644 --- a/acceptance/bundle/artifacts/whl_dynamic/script +++ b/acceptance/bundle/artifacts/whl_dynamic/script @@ -6,7 +6,7 @@ cp -r $TESTDIR/../whl_prebuilt_multiple/dist/lib/other_test_code-0.0.1-py3-none- trace $CLI bundle validate -o json | nostamp | jq .artifacts -$CLI bundle plan -o json | nostamp > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan_create.json trace $CLI bundle deploy title "There are 2 original wheels and 2 patched ones" @@ -25,7 +25,7 @@ rm "$OUT_REQUESTS" title "Updating the local wheel and deploying again\n" touch my_test_code/src/new_module.py -$CLI bundle plan -o json | nostamp > out.plan_update.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan_update.json trace $CLI bundle deploy title "Verify contents, it should now have new_module.py" diff --git a/acceptance/bundle/artifacts/whl_explicit/out.test.toml b/acceptance/bundle/artifacts/whl_explicit/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/whl_explicit/out.test.toml +++ b/acceptance/bundle/artifacts/whl_explicit/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/whl_implicit/out.test.toml b/acceptance/bundle/artifacts/whl_implicit/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/whl_implicit/out.test.toml +++ b/acceptance/bundle/artifacts/whl_implicit/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/whl_implicit_custom_path/out.test.toml b/acceptance/bundle/artifacts/whl_implicit_custom_path/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/whl_implicit_custom_path/out.test.toml +++ b/acceptance/bundle/artifacts/whl_implicit_custom_path/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/whl_implicit_notebook/out.test.toml b/acceptance/bundle/artifacts/whl_implicit_notebook/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/whl_implicit_notebook/out.test.toml +++ b/acceptance/bundle/artifacts/whl_implicit_notebook/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/whl_multiple/out.test.toml b/acceptance/bundle/artifacts/whl_multiple/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/whl_multiple/out.test.toml +++ b/acceptance/bundle/artifacts/whl_multiple/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/whl_no_cleanup/out.test.toml b/acceptance/bundle/artifacts/whl_no_cleanup/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/whl_no_cleanup/out.test.toml +++ b/acceptance/bundle/artifacts/whl_no_cleanup/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/whl_prebuilt_multiple/out.test.toml b/acceptance/bundle/artifacts/whl_prebuilt_multiple/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/whl_prebuilt_multiple/out.test.toml +++ b/acceptance/bundle/artifacts/whl_prebuilt_multiple/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/whl_prebuilt_outside/out.test.toml b/acceptance/bundle/artifacts/whl_prebuilt_outside/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/whl_prebuilt_outside/out.test.toml +++ b/acceptance/bundle/artifacts/whl_prebuilt_outside/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/whl_prebuilt_outside_dynamic/out.test.toml b/acceptance/bundle/artifacts/whl_prebuilt_outside_dynamic/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/whl_prebuilt_outside_dynamic/out.test.toml +++ b/acceptance/bundle/artifacts/whl_prebuilt_outside_dynamic/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/whl_via_environment_key/out.test.toml b/acceptance/bundle/artifacts/whl_via_environment_key/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/whl_via_environment_key/out.test.toml +++ b/acceptance/bundle/artifacts/whl_via_environment_key/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/artifacts/whl_via_environment_key_extras/out.test.toml b/acceptance/bundle/artifacts/whl_via_environment_key_extras/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/artifacts/whl_via_environment_key_extras/out.test.toml +++ b/acceptance/bundle/artifacts/whl_via_environment_key_extras/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/benchmarks/deploy/out.test.toml b/acceptance/bundle/benchmarks/deploy/out.test.toml index 56f228d004e..8c2cb31de53 100644 --- a/acceptance/bundle/benchmarks/deploy/out.test.toml +++ b/acceptance/bundle/benchmarks/deploy/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/benchmarks/plan/out.test.toml b/acceptance/bundle/benchmarks/plan/out.test.toml index 56f228d004e..8c2cb31de53 100644 --- a/acceptance/bundle/benchmarks/plan/out.test.toml +++ b/acceptance/bundle/benchmarks/plan/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/benchmarks/validate/out.test.toml b/acceptance/bundle/benchmarks/validate/out.test.toml index 56f228d004e..8c2cb31de53 100644 --- a/acceptance/bundle/benchmarks/validate/out.test.toml +++ b/acceptance/bundle/benchmarks/validate/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/bundle_tag/id/out.test.toml b/acceptance/bundle/bundle_tag/id/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/bundle_tag/id/out.test.toml +++ b/acceptance/bundle/bundle_tag/id/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/bundle_tag/url/out.test.toml b/acceptance/bundle/bundle_tag/url/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/bundle_tag/url/out.test.toml +++ b/acceptance/bundle/bundle_tag/url/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/bundle_tag/url_ref/out.deploy-requests.terraform.txt b/acceptance/bundle/bundle_tag/url_ref/out.deploy-requests.terraform.txt deleted file mode 100644 index 0a9a51c98b7..00000000000 --- a/acceptance/bundle/bundle_tag/url_ref/out.deploy-requests.terraform.txt +++ /dev/null @@ -1,34 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.2/jobs/create", - "body": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "Untitled", - "queue": { - "enabled": true - } - } -} -{ - "method": "POST", - "path": "/api/2.2/jobs/create", - "body": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "Untitled", - "queue": { - "enabled": true - } - } -} diff --git a/acceptance/bundle/bundle_tag/url_ref/out.deploy-requests.direct.txt b/acceptance/bundle/bundle_tag/url_ref/out.deploy-requests.txt similarity index 100% rename from acceptance/bundle/bundle_tag/url_ref/out.deploy-requests.direct.txt rename to acceptance/bundle/bundle_tag/url_ref/out.deploy-requests.txt diff --git a/acceptance/bundle/bundle_tag/url_ref/out.deploy.terraform.txt b/acceptance/bundle/bundle_tag/url_ref/out.deploy.terraform.txt deleted file mode 100644 index 1cf3ea7c01a..00000000000 --- a/acceptance/bundle/bundle_tag/url_ref/out.deploy.terraform.txt +++ /dev/null @@ -1,8 +0,0 @@ -Warning: "resources.jobs.foo.url": Terraform-only field; this reference will not work with the direct engine - in databricks.yml:11:12 - -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created jobs.bar -Created jobs.foo -Files: 6 uploaded, 0 deleted -Resources: 2 created, 0 changed, 0 deleted, 0 unchanged diff --git a/acceptance/bundle/bundle_tag/url_ref/out.deploy.direct.txt b/acceptance/bundle/bundle_tag/url_ref/out.deploy.txt similarity index 100% rename from acceptance/bundle/bundle_tag/url_ref/out.deploy.direct.txt rename to acceptance/bundle/bundle_tag/url_ref/out.deploy.txt diff --git a/acceptance/bundle/bundle_tag/url_ref/out.destroy-requests.terraform.txt b/acceptance/bundle/bundle_tag/url_ref/out.destroy-requests.terraform.txt deleted file mode 100644 index 756c38d7555..00000000000 --- a/acceptance/bundle/bundle_tag/url_ref/out.destroy-requests.terraform.txt +++ /dev/null @@ -1,14 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.2/jobs/delete", - "body": { - "job_id": [NUMID] - } -} -{ - "method": "POST", - "path": "/api/2.2/jobs/delete", - "body": { - "job_id": [NUMID] - } -} diff --git a/acceptance/bundle/bundle_tag/url_ref/out.destroy-requests.direct.txt b/acceptance/bundle/bundle_tag/url_ref/out.destroy-requests.txt similarity index 100% rename from acceptance/bundle/bundle_tag/url_ref/out.destroy-requests.direct.txt rename to acceptance/bundle/bundle_tag/url_ref/out.destroy-requests.txt diff --git a/acceptance/bundle/bundle_tag/url_ref/out.destroy.terraform.txt b/acceptance/bundle/bundle_tag/url_ref/out.destroy.terraform.txt deleted file mode 100644 index 34801cda18f..00000000000 --- a/acceptance/bundle/bundle_tag/url_ref/out.destroy.terraform.txt +++ /dev/null @@ -1,10 +0,0 @@ -Warning: "resources.jobs.foo.url": Terraform-only field; this reference will not work with the direct engine - in databricks.yml:11:12 - -The following resources will be deleted: - delete resources.jobs.bar - delete resources.jobs.foo - -All files and directories at the following location will be deleted: /Workspace/Users/[USERNAME]/.bundle/test-bundle/default - -Destroy: 2 deleted diff --git a/acceptance/bundle/bundle_tag/url_ref/out.destroy.direct.txt b/acceptance/bundle/bundle_tag/url_ref/out.destroy.txt similarity index 100% rename from acceptance/bundle/bundle_tag/url_ref/out.destroy.direct.txt rename to acceptance/bundle/bundle_tag/url_ref/out.destroy.txt diff --git a/acceptance/bundle/bundle_tag/url_ref/out.plan.terraform.txt b/acceptance/bundle/bundle_tag/url_ref/out.plan.terraform.txt deleted file mode 100644 index c00bfef5275..00000000000 --- a/acceptance/bundle/bundle_tag/url_ref/out.plan.terraform.txt +++ /dev/null @@ -1,7 +0,0 @@ -Warning: "resources.jobs.foo.url": Terraform-only field; this reference will not work with the direct engine - in databricks.yml:11:12 - -create jobs.bar -create jobs.foo - -Plan: 2 to add, 0 to change, 0 to delete, 0 unchanged diff --git a/acceptance/bundle/bundle_tag/url_ref/out.plan.direct.txt b/acceptance/bundle/bundle_tag/url_ref/out.plan.txt similarity index 100% rename from acceptance/bundle/bundle_tag/url_ref/out.plan.direct.txt rename to acceptance/bundle/bundle_tag/url_ref/out.plan.txt diff --git a/acceptance/bundle/bundle_tag/url_ref/out.summary.terraform.txt b/acceptance/bundle/bundle_tag/url_ref/out.summary.terraform.txt deleted file mode 100644 index 49a32e67b4a..00000000000 --- a/acceptance/bundle/bundle_tag/url_ref/out.summary.terraform.txt +++ /dev/null @@ -1,16 +0,0 @@ -Warning: "resources.jobs.foo.url": Terraform-only field; this reference will not work with the direct engine - in databricks.yml:11:12 - -Name: test-bundle -Target: default -Workspace: - User: [USERNAME] - Path: /Workspace/Users/[USERNAME]/.bundle/test-bundle/default -Resources: - Jobs: - bar: - Name: Untitled - URL: [DATABRICKS_URL]/jobs/[NUMID]?w=[NUMID] - foo: - Name: Untitled - URL: [DATABRICKS_URL]/jobs/[NUMID]?w=[NUMID] diff --git a/acceptance/bundle/bundle_tag/url_ref/out.summary.direct.txt b/acceptance/bundle/bundle_tag/url_ref/out.summary.txt similarity index 100% rename from acceptance/bundle/bundle_tag/url_ref/out.summary.direct.txt rename to acceptance/bundle/bundle_tag/url_ref/out.summary.txt diff --git a/acceptance/bundle/bundle_tag/url_ref/out.test.toml b/acceptance/bundle/bundle_tag/url_ref/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/bundle_tag/url_ref/out.test.toml +++ b/acceptance/bundle/bundle_tag/url_ref/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/bundle_tag/url_ref/out.validate.terraform.txt b/acceptance/bundle/bundle_tag/url_ref/out.validate.terraform.txt deleted file mode 100644 index 51628046009..00000000000 --- a/acceptance/bundle/bundle_tag/url_ref/out.validate.terraform.txt +++ /dev/null @@ -1,45 +0,0 @@ -Warning: "resources.jobs.foo.url": Terraform-only field; this reference will not work with the direct engine - in databricks.yml:11:12 - -Name: test-bundle -Target: default -Workspace: - User: [USERNAME] - Path: /Workspace/Users/[USERNAME]/.bundle/test-bundle/default - -Found 1 warning -Warning: "resources.jobs.foo.url": Terraform-only field; this reference will not work with the direct engine - in databricks.yml:11:12 - -{ - "jobs": { - "bar": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "Untitled", - "queue": { - "enabled": true - }, - "url": "${resources.jobs.foo.url}" - }, - "foo": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "Untitled", - "queue": { - "enabled": true - }, - "url": "my_job_url" - } - } -} diff --git a/acceptance/bundle/bundle_tag/url_ref/out.validate.direct.txt b/acceptance/bundle/bundle_tag/url_ref/out.validate.txt similarity index 100% rename from acceptance/bundle/bundle_tag/url_ref/out.validate.direct.txt rename to acceptance/bundle/bundle_tag/url_ref/out.validate.txt diff --git a/acceptance/bundle/bundle_tag/url_ref/script b/acceptance/bundle/bundle_tag/url_ref/script index 0be0b08467b..6d2efe44d62 100644 --- a/acceptance/bundle/bundle_tag/url_ref/script +++ b/acceptance/bundle/bundle_tag/url_ref/script @@ -1,10 +1,10 @@ -errcode $CLI bundle validate &> out.validate.$DATABRICKS_BUNDLE_ENGINE.txt -errcode $CLI bundle validate -o json > out.validate.json.tmp 2>> out.validate.$DATABRICKS_BUNDLE_ENGINE.txt -jq .resources out.validate.json.tmp >> out.validate.$DATABRICKS_BUNDLE_ENGINE.txt +errcode $CLI bundle validate &> out.validate.txt +errcode $CLI bundle validate -o json > out.validate.json.tmp 2>> out.validate.txt +jq .resources out.validate.json.tmp >> out.validate.txt rm out.validate.json.tmp -errcode $CLI bundle plan &> out.plan.$DATABRICKS_BUNDLE_ENGINE.txt -errcode $CLI bundle deploy &> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt -errcode print_requests.py //jobs &> out.deploy-requests.$DATABRICKS_BUNDLE_ENGINE.txt -errcode $CLI bundle summary &> out.summary.$DATABRICKS_BUNDLE_ENGINE.txt -errcode $CLI bundle destroy --auto-approve &> out.destroy.$DATABRICKS_BUNDLE_ENGINE.txt -errcode print_requests.py //jobs &> out.destroy-requests.$DATABRICKS_BUNDLE_ENGINE.txt +errcode $CLI bundle plan &> out.plan.txt +errcode $CLI bundle deploy &> out.deploy.txt +errcode print_requests.py //jobs &> out.deploy-requests.txt +errcode $CLI bundle summary &> out.summary.txt +errcode $CLI bundle destroy --auto-approve &> out.destroy.txt +errcode print_requests.py //jobs &> out.destroy-requests.txt diff --git a/acceptance/bundle/config-remote-sync/cli_defaults/out.test.toml b/acceptance/bundle/config-remote-sync/cli_defaults/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/cli_defaults/out.test.toml +++ b/acceptance/bundle/config-remote-sync/cli_defaults/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/cli_defaults/test.toml b/acceptance/bundle/config-remote-sync/cli_defaults/test.toml index 74e14b7c03b..21cf5f934b3 100644 --- a/acceptance/bundle/config-remote-sync/cli_defaults/test.toml +++ b/acceptance/bundle/config-remote-sync/cli_defaults/test.toml @@ -4,5 +4,3 @@ RecordRequests = false Ignore = [".databricks", "dummy.whl", "databricks.yml", "databricks.yml.backup"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/cluster_policy_remote_addition/out.test.toml b/acceptance/bundle/config-remote-sync/cluster_policy_remote_addition/out.test.toml index 0db72c1b195..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/cluster_policy_remote_addition/out.test.toml +++ b/acceptance/bundle/config-remote-sync/cluster_policy_remote_addition/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/cluster_policy_remote_addition/test.toml b/acceptance/bundle/config-remote-sync/cluster_policy_remote_addition/test.toml index b13ee63c9a2..a799274577a 100644 --- a/acceptance/bundle/config-remote-sync/cluster_policy_remote_addition/test.toml +++ b/acceptance/bundle/config-remote-sync/cluster_policy_remote_addition/test.toml @@ -1,4 +1,3 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] RecordRequests = false Ignore = [".databricks", "databricks.yml", "databricks.yml.backup"] diff --git a/acceptance/bundle/config-remote-sync/config_edits/out.test.toml b/acceptance/bundle/config-remote-sync/config_edits/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/config_edits/out.test.toml +++ b/acceptance/bundle/config-remote-sync/config_edits/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/config_edits/test.toml b/acceptance/bundle/config-remote-sync/config_edits/test.toml index abf648afba9..3215c8a064e 100644 --- a/acceptance/bundle/config-remote-sync/config_edits/test.toml +++ b/acceptance/bundle/config-remote-sync/config_edits/test.toml @@ -5,5 +5,3 @@ RecordRequests = false Ignore = [".databricks", "dummy.whl", "databricks.yml", "databricks.yml.backup"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/dashboard_etag/out.test.toml b/acceptance/bundle/config-remote-sync/dashboard_etag/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/dashboard_etag/out.test.toml +++ b/acceptance/bundle/config-remote-sync/dashboard_etag/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/dashboard_etag/test.toml b/acceptance/bundle/config-remote-sync/dashboard_etag/test.toml index 9706701aa91..440f488b0de 100644 --- a/acceptance/bundle/config-remote-sync/dashboard_etag/test.toml +++ b/acceptance/bundle/config-remote-sync/dashboard_etag/test.toml @@ -5,5 +5,3 @@ RecordRequests = false Ignore = [".databricks", "databricks.yml", "databricks.yml.backup"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/flushed_cache/out.test.toml b/acceptance/bundle/config-remote-sync/flushed_cache/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/flushed_cache/out.test.toml +++ b/acceptance/bundle/config-remote-sync/flushed_cache/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/flushed_cache/test.toml b/acceptance/bundle/config-remote-sync/flushed_cache/test.toml index 084af5a2129..f388c192c90 100644 --- a/acceptance/bundle/config-remote-sync/flushed_cache/test.toml +++ b/acceptance/bundle/config-remote-sync/flushed_cache/test.toml @@ -5,7 +5,6 @@ Ignore = [".databricks", "databricks.yml"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] # Normalize ls error messages across platforms [[Repls]] diff --git a/acceptance/bundle/config-remote-sync/formatting_preserved/out.test.toml b/acceptance/bundle/config-remote-sync/formatting_preserved/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/formatting_preserved/out.test.toml +++ b/acceptance/bundle/config-remote-sync/formatting_preserved/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/formatting_preserved/test.toml b/acceptance/bundle/config-remote-sync/formatting_preserved/test.toml index 74e14b7c03b..21cf5f934b3 100644 --- a/acceptance/bundle/config-remote-sync/formatting_preserved/test.toml +++ b/acceptance/bundle/config-remote-sync/formatting_preserved/test.toml @@ -4,5 +4,3 @@ RecordRequests = false Ignore = [".databricks", "dummy.whl", "databricks.yml", "databricks.yml.backup"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/job_fields/out.test.toml b/acceptance/bundle/config-remote-sync/job_fields/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/job_fields/out.test.toml +++ b/acceptance/bundle/config-remote-sync/job_fields/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/job_fields/test.toml b/acceptance/bundle/config-remote-sync/job_fields/test.toml index c4ceb894060..d0e1bdf6049 100644 --- a/acceptance/bundle/config-remote-sync/job_fields/test.toml +++ b/acceptance/bundle/config-remote-sync/job_fields/test.toml @@ -7,5 +7,3 @@ RecordRequests = true Ignore = [".databricks", "dummy.whl", "databricks.yml", "databricks.yml.backup"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/job_multiple_tasks/out.test.toml b/acceptance/bundle/config-remote-sync/job_multiple_tasks/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/job_multiple_tasks/out.test.toml +++ b/acceptance/bundle/config-remote-sync/job_multiple_tasks/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/job_multiple_tasks/test.toml b/acceptance/bundle/config-remote-sync/job_multiple_tasks/test.toml index 2bbffa30109..3c27bbf8319 100644 --- a/acceptance/bundle/config-remote-sync/job_multiple_tasks/test.toml +++ b/acceptance/bundle/config-remote-sync/job_multiple_tasks/test.toml @@ -4,5 +4,3 @@ RecordRequests = false Ignore = [".databricks", "dummy.whl", "databricks.yml", "databricks.yml.backup", "synced_notebook.py"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/job_params_variables/out.test.toml b/acceptance/bundle/config-remote-sync/job_params_variables/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/job_params_variables/out.test.toml +++ b/acceptance/bundle/config-remote-sync/job_params_variables/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/job_params_variables/test.toml b/acceptance/bundle/config-remote-sync/job_params_variables/test.toml index a41b313ac94..8b6c9ef02fc 100644 --- a/acceptance/bundle/config-remote-sync/job_params_variables/test.toml +++ b/acceptance/bundle/config-remote-sync/job_params_variables/test.toml @@ -4,5 +4,3 @@ RecordRequests = false Ignore = [".databricks", "databricks.yml", "databricks.yml.backup"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/job_pipeline_task/out.test.toml b/acceptance/bundle/config-remote-sync/job_pipeline_task/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/job_pipeline_task/out.test.toml +++ b/acceptance/bundle/config-remote-sync/job_pipeline_task/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/job_pipeline_task/test.toml b/acceptance/bundle/config-remote-sync/job_pipeline_task/test.toml index 74e14b7c03b..21cf5f934b3 100644 --- a/acceptance/bundle/config-remote-sync/job_pipeline_task/test.toml +++ b/acceptance/bundle/config-remote-sync/job_pipeline_task/test.toml @@ -4,5 +4,3 @@ RecordRequests = false Ignore = [".databricks", "dummy.whl", "databricks.yml", "databricks.yml.backup"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/json_status_missing_state/databricks.yml.tmpl b/acceptance/bundle/config-remote-sync/json_status_missing_state/databricks.yml.tmpl deleted file mode 100644 index 16d5646d970..00000000000 --- a/acceptance/bundle/config-remote-sync/json_status_missing_state/databricks.yml.tmpl +++ /dev/null @@ -1,19 +0,0 @@ -bundle: - name: test-bundle-$UNIQUE_NAME - -resources: - jobs: - test_job: - max_concurrent_runs: 1 - tasks: - - task_key: main - notebook_task: - notebook_path: /Users/{{workspace_user_name}}/notebook - new_cluster: - spark_version: $DEFAULT_SPARK_VERSION - node_type_id: $NODE_TYPE_ID - num_workers: 1 - -targets: - default: - mode: development diff --git a/acceptance/bundle/config-remote-sync/json_status_missing_state/out.test.toml b/acceptance/bundle/config-remote-sync/json_status_missing_state/out.test.toml deleted file mode 100644 index 031ca09a000..00000000000 --- a/acceptance/bundle/config-remote-sync/json_status_missing_state/out.test.toml +++ /dev/null @@ -1,4 +0,0 @@ -Cloud = true -GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] -EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/json_status_missing_state/output.txt b/acceptance/bundle/config-remote-sync/json_status_missing_state/output.txt deleted file mode 100644 index 069d2960882..00000000000 --- a/acceptance/bundle/config-remote-sync/json_status_missing_state/output.txt +++ /dev/null @@ -1,8 +0,0 @@ - -=== Missing tf state is reported as skipped, exit 0 -{ - "status": "skipped", - "error": "state snapshot not available: resources state snapshot not found remotely at resources-config-sync-snapshot.json: state snapshot not found", - "files": null, - "changes": {} -} diff --git a/acceptance/bundle/config-remote-sync/json_status_missing_state/script b/acceptance/bundle/config-remote-sync/json_status_missing_state/script deleted file mode 100755 index 00baec1b20e..00000000000 --- a/acceptance/bundle/config-remote-sync/json_status_missing_state/script +++ /dev/null @@ -1,9 +0,0 @@ -#!/bin/bash - -envsubst < databricks.yml.tmpl > databricks.yml - -# No deploy, so the terraform state snapshot does not exist: in JSON mode the -# sync is reported as skipped with exit 0, not a hard failure. -title "Missing tf state is reported as skipped, exit 0" -echo -errcode $CLI bundle config-remote-sync -o json diff --git a/acceptance/bundle/config-remote-sync/json_status_missing_state/test.toml b/acceptance/bundle/config-remote-sync/json_status_missing_state/test.toml deleted file mode 100644 index 3c4907c9d8e..00000000000 --- a/acceptance/bundle/config-remote-sync/json_status_missing_state/test.toml +++ /dev/null @@ -1,11 +0,0 @@ -Cloud = true - -RecordRequests = false -Ignore = [".databricks", "dummy.whl", "databricks.yml"] - -Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -# "Missing tf state" is terraform-specific: the direct engine has no separate -# state snapshot to be absent, so ErrStateSnapshotNotFound (and the skipped -# outcome it drives) only arises on terraform. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] diff --git a/acceptance/bundle/config-remote-sync/json_status_selectors/out.test.toml b/acceptance/bundle/config-remote-sync/json_status_selectors/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/json_status_selectors/out.test.toml +++ b/acceptance/bundle/config-remote-sync/json_status_selectors/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/json_status_selectors/test.toml b/acceptance/bundle/config-remote-sync/json_status_selectors/test.toml index b721843242f..1f20e9fda75 100644 --- a/acceptance/bundle/config-remote-sync/json_status_selectors/test.toml +++ b/acceptance/bundle/config-remote-sync/json_status_selectors/test.toml @@ -4,5 +4,3 @@ RecordRequests = false Ignore = [".databricks", "dummy.whl", "databricks.yml"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/multiple_files/out.test.toml b/acceptance/bundle/config-remote-sync/multiple_files/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/multiple_files/out.test.toml +++ b/acceptance/bundle/config-remote-sync/multiple_files/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/multiple_files/test.toml b/acceptance/bundle/config-remote-sync/multiple_files/test.toml index 976b4498f7a..647daee4044 100644 --- a/acceptance/bundle/config-remote-sync/multiple_files/test.toml +++ b/acceptance/bundle/config-remote-sync/multiple_files/test.toml @@ -4,5 +4,3 @@ RecordRequests = false Ignore = [".databricks", "dummy.whl", "databricks.yml", "resources/job1.yml", "resources/job2.yml", "sample_exploration.ipynb"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/multiple_resources/out.test.toml b/acceptance/bundle/config-remote-sync/multiple_resources/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/multiple_resources/out.test.toml +++ b/acceptance/bundle/config-remote-sync/multiple_resources/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/multiple_resources/test.toml b/acceptance/bundle/config-remote-sync/multiple_resources/test.toml index 74e14b7c03b..21cf5f934b3 100644 --- a/acceptance/bundle/config-remote-sync/multiple_resources/test.toml +++ b/acceptance/bundle/config-remote-sync/multiple_resources/test.toml @@ -4,5 +4,3 @@ RecordRequests = false Ignore = [".databricks", "dummy.whl", "databricks.yml", "databricks.yml.backup"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/output_json/out.test.toml b/acceptance/bundle/config-remote-sync/output_json/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/output_json/out.test.toml +++ b/acceptance/bundle/config-remote-sync/output_json/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/output_json/test.toml b/acceptance/bundle/config-remote-sync/output_json/test.toml index d29b8a16314..33f2b8d728a 100644 --- a/acceptance/bundle/config-remote-sync/output_json/test.toml +++ b/acceptance/bundle/config-remote-sync/output_json/test.toml @@ -4,5 +4,3 @@ RecordRequests = false Ignore = [".databricks", "dummy.whl", "tmp.json", "databricks.yml"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/output_no_changes/out.test.toml b/acceptance/bundle/config-remote-sync/output_no_changes/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/output_no_changes/out.test.toml +++ b/acceptance/bundle/config-remote-sync/output_no_changes/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/output_no_changes/test.toml b/acceptance/bundle/config-remote-sync/output_no_changes/test.toml index d29b8a16314..33f2b8d728a 100644 --- a/acceptance/bundle/config-remote-sync/output_no_changes/test.toml +++ b/acceptance/bundle/config-remote-sync/output_no_changes/test.toml @@ -4,5 +4,3 @@ RecordRequests = false Ignore = [".databricks", "dummy.whl", "tmp.json", "databricks.yml"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/pipeline_fields/out.test.toml b/acceptance/bundle/config-remote-sync/pipeline_fields/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/pipeline_fields/out.test.toml +++ b/acceptance/bundle/config-remote-sync/pipeline_fields/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/pipeline_fields/test.toml b/acceptance/bundle/config-remote-sync/pipeline_fields/test.toml index 0a05bc5e9d2..a311f6bf434 100644 --- a/acceptance/bundle/config-remote-sync/pipeline_fields/test.toml +++ b/acceptance/bundle/config-remote-sync/pipeline_fields/test.toml @@ -4,5 +4,3 @@ RecordRequests = false Ignore = [".databricks", "databricks.yml", "databricks.yml.backup", "pipeline_root"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/policy_injected_cluster_fields/out.test.toml b/acceptance/bundle/config-remote-sync/policy_injected_cluster_fields/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/policy_injected_cluster_fields/out.test.toml +++ b/acceptance/bundle/config-remote-sync/policy_injected_cluster_fields/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/policy_injected_cluster_fields/test.toml b/acceptance/bundle/config-remote-sync/policy_injected_cluster_fields/test.toml index a41b313ac94..8b6c9ef02fc 100644 --- a/acceptance/bundle/config-remote-sync/policy_injected_cluster_fields/test.toml +++ b/acceptance/bundle/config-remote-sync/policy_injected_cluster_fields/test.toml @@ -4,5 +4,3 @@ RecordRequests = false Ignore = [".databricks", "databricks.yml", "databricks.yml.backup"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/resolve_variables/out.test.toml b/acceptance/bundle/config-remote-sync/resolve_variables/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/resolve_variables/out.test.toml +++ b/acceptance/bundle/config-remote-sync/resolve_variables/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/resolve_variables/test.toml b/acceptance/bundle/config-remote-sync/resolve_variables/test.toml index 192841ec4cb..ab417b9ba5f 100644 --- a/acceptance/bundle/config-remote-sync/resolve_variables/test.toml +++ b/acceptance/bundle/config-remote-sync/resolve_variables/test.toml @@ -9,7 +9,6 @@ Ignore = [".databricks", "databricks.yml", "databricks.yml.backup"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] # The state serial counts state writes, and the terraform path writes more times # than the direct path for the same script, so the value differs per engine. # The serial is not what this test asserts — normalize it. diff --git a/acceptance/bundle/config-remote-sync/select_basic/out.test.toml b/acceptance/bundle/config-remote-sync/select_basic/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/select_basic/out.test.toml +++ b/acceptance/bundle/config-remote-sync/select_basic/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/select_basic/test.toml b/acceptance/bundle/config-remote-sync/select_basic/test.toml index ff73e7474f6..6708f69069f 100644 --- a/acceptance/bundle/config-remote-sync/select_basic/test.toml +++ b/acceptance/bundle/config-remote-sync/select_basic/test.toml @@ -5,7 +5,6 @@ Ignore = [".databricks", "databricks.yml", "databricks.yml.backup"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] # The two job ids are server-assigned, so their sort order in the # "deployed jobs ids in state" list varies run to run. Collapse the pair to a # single stable token so the expectation stays hermetic. diff --git a/acceptance/bundle/config-remote-sync/select_multiple/out.test.toml b/acceptance/bundle/config-remote-sync/select_multiple/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/select_multiple/out.test.toml +++ b/acceptance/bundle/config-remote-sync/select_multiple/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/select_multiple/test.toml b/acceptance/bundle/config-remote-sync/select_multiple/test.toml index a41b313ac94..8b6c9ef02fc 100644 --- a/acceptance/bundle/config-remote-sync/select_multiple/test.toml +++ b/acceptance/bundle/config-remote-sync/select_multiple/test.toml @@ -4,5 +4,3 @@ RecordRequests = false Ignore = [".databricks", "databricks.yml", "databricks.yml.backup"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/skip_deployment/out.test.toml b/acceptance/bundle/config-remote-sync/skip_deployment/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/skip_deployment/out.test.toml +++ b/acceptance/bundle/config-remote-sync/skip_deployment/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/skip_deployment/test.toml b/acceptance/bundle/config-remote-sync/skip_deployment/test.toml index d9c714eca5e..86ffa2fdb9c 100644 --- a/acceptance/bundle/config-remote-sync/skip_deployment/test.toml +++ b/acceptance/bundle/config-remote-sync/skip_deployment/test.toml @@ -5,5 +5,3 @@ Ignore = [".databricks", "databricks.yml", "databricks.yml.backup"] # Enables writing the config-sync state snapshot at deploy time, which the # terraform-engine config-remote-sync reads back. Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/skip_permissions/out.test.toml b/acceptance/bundle/config-remote-sync/skip_permissions/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/skip_permissions/out.test.toml +++ b/acceptance/bundle/config-remote-sync/skip_permissions/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/skip_permissions/test.toml b/acceptance/bundle/config-remote-sync/skip_permissions/test.toml index a41b313ac94..8b6c9ef02fc 100644 --- a/acceptance/bundle/config-remote-sync/skip_permissions/test.toml +++ b/acceptance/bundle/config-remote-sync/skip_permissions/test.toml @@ -4,5 +4,3 @@ RecordRequests = false Ignore = [".databricks", "databricks.yml", "databricks.yml.backup"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/split/cli_default_split_element/out.test.toml b/acceptance/bundle/config-remote-sync/split/cli_default_split_element/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/split/cli_default_split_element/out.test.toml +++ b/acceptance/bundle/config-remote-sync/split/cli_default_split_element/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/split/dotted_target/out.test.toml b/acceptance/bundle/config-remote-sync/split/dotted_target/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/split/dotted_target/out.test.toml +++ b/acceptance/bundle/config-remote-sync/split/dotted_target/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/split/isolation/out.test.toml b/acceptance/bundle/config-remote-sync/split/isolation/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/split/isolation/out.test.toml +++ b/acceptance/bundle/config-remote-sync/split/isolation/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/split/keyed_edit/out.test.toml b/acceptance/bundle/config-remote-sync/split/keyed_edit/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/split/keyed_edit/out.test.toml +++ b/acceptance/bundle/config-remote-sync/split/keyed_edit/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/split/keyed_remove/out.test.toml b/acceptance/bundle/config-remote-sync/split/keyed_remove/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/split/keyed_remove/out.test.toml +++ b/acceptance/bundle/config-remote-sync/split/keyed_remove/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/split/keyed_rename/out.test.toml b/acceptance/bundle/config-remote-sync/split/keyed_rename/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/split/keyed_rename/out.test.toml +++ b/acceptance/bundle/config-remote-sync/split/keyed_rename/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/split/keyed_twoblock/out.test.toml b/acceptance/bundle/config-remote-sync/split/keyed_twoblock/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/split/keyed_twoblock/out.test.toml +++ b/acceptance/bundle/config-remote-sync/split/keyed_twoblock/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/split/multifile/out.test.toml b/acceptance/bundle/config-remote-sync/split/multifile/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/split/multifile/out.test.toml +++ b/acceptance/bundle/config-remote-sync/split/multifile/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/split/nested_add_split_parent/out.test.toml b/acceptance/bundle/config-remote-sync/split/nested_add_split_parent/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/split/nested_add_split_parent/out.test.toml +++ b/acceptance/bundle/config-remote-sync/split/nested_add_split_parent/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/split/nested_sequence/out.test.toml b/acceptance/bundle/config-remote-sync/split/nested_sequence/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/split/nested_sequence/out.test.toml +++ b/acceptance/bundle/config-remote-sync/split/nested_sequence/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/split/positional/out.test.toml b/acceptance/bundle/config-remote-sync/split/positional/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/split/positional/out.test.toml +++ b/acceptance/bundle/config-remote-sync/split/positional/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/split/remove_field_both_blocks/out.test.toml b/acceptance/bundle/config-remote-sync/split/remove_field_both_blocks/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/split/remove_field_both_blocks/out.test.toml +++ b/acceptance/bundle/config-remote-sync/split/remove_field_both_blocks/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/split/remove_with_unrelated_add/out.test.toml b/acceptance/bundle/config-remote-sync/split/remove_with_unrelated_add/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/split/remove_with_unrelated_add/out.test.toml +++ b/acceptance/bundle/config-remote-sync/split/remove_with_unrelated_add/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/split/rename_ambiguous_pairing/out.test.toml b/acceptance/bundle/config-remote-sync/split/rename_ambiguous_pairing/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/split/rename_ambiguous_pairing/out.test.toml +++ b/acceptance/bundle/config-remote-sync/split/rename_ambiguous_pairing/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/split/rename_ambiguous_single_block/out.test.toml b/acceptance/bundle/config-remote-sync/split/rename_ambiguous_single_block/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/split/rename_ambiguous_single_block/out.test.toml +++ b/acceptance/bundle/config-remote-sync/split/rename_ambiguous_single_block/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/split/rename_two_removes_one_add/out.test.toml b/acceptance/bundle/config-remote-sync/split/rename_two_removes_one_add/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/split/rename_two_removes_one_add/out.test.toml +++ b/acceptance/bundle/config-remote-sync/split/rename_two_removes_one_add/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/split/target_variable/out.test.toml b/acceptance/bundle/config-remote-sync/split/target_variable/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/split/target_variable/out.test.toml +++ b/acceptance/bundle/config-remote-sync/split/target_variable/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/split/test.toml b/acceptance/bundle/config-remote-sync/split/test.toml index 25d73d46a00..732f2cf0edd 100644 --- a/acceptance/bundle/config-remote-sync/split/test.toml +++ b/acceptance/bundle/config-remote-sync/split/test.toml @@ -5,5 +5,3 @@ RecordRequests = false Ignore = [".databricks", "databricks.yml", "databricks.yml.backup", "overrides/*.yml", "overrides/*.backup"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/split/variable_file_order/out.test.toml b/acceptance/bundle/config-remote-sync/split/variable_file_order/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/split/variable_file_order/out.test.toml +++ b/acceptance/bundle/config-remote-sync/split/variable_file_order/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/target_override/out.test.toml b/acceptance/bundle/config-remote-sync/target_override/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/target_override/out.test.toml +++ b/acceptance/bundle/config-remote-sync/target_override/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/target_override/test.toml b/acceptance/bundle/config-remote-sync/target_override/test.toml index 74e14b7c03b..21cf5f934b3 100644 --- a/acceptance/bundle/config-remote-sync/target_override/test.toml +++ b/acceptance/bundle/config-remote-sync/target_override/test.toml @@ -4,5 +4,3 @@ RecordRequests = false Ignore = [".databricks", "dummy.whl", "databricks.yml", "databricks.yml.backup"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/task_rename_revert/out.test.toml b/acceptance/bundle/config-remote-sync/task_rename_revert/out.test.toml index f25e278148e..a4f8dd5ef74 100644 --- a/acceptance/bundle/config-remote-sync/task_rename_revert/out.test.toml +++ b/acceptance/bundle/config-remote-sync/task_rename_revert/out.test.toml @@ -1,4 +1,3 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/task_rename_revert/test.toml b/acceptance/bundle/config-remote-sync/task_rename_revert/test.toml index a41b313ac94..8b6c9ef02fc 100644 --- a/acceptance/bundle/config-remote-sync/task_rename_revert/test.toml +++ b/acceptance/bundle/config-remote-sync/task_rename_revert/test.toml @@ -4,5 +4,3 @@ RecordRequests = false Ignore = [".databricks", "databricks.yml", "databricks.yml.backup"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/validation_errors/out.test.toml b/acceptance/bundle/config-remote-sync/validation_errors/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/validation_errors/out.test.toml +++ b/acceptance/bundle/config-remote-sync/validation_errors/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/validation_errors/test.toml b/acceptance/bundle/config-remote-sync/validation_errors/test.toml index 10ac73763eb..bf190f0f3fb 100644 --- a/acceptance/bundle/config-remote-sync/validation_errors/test.toml +++ b/acceptance/bundle/config-remote-sync/validation_errors/test.toml @@ -2,5 +2,3 @@ RecordRequests = false Ignore = [".databricks", "databricks.yml", "databricks.yml.backup", "src", "pipeline_root"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/config-remote-sync/variable_reference_parent/out.test.toml b/acceptance/bundle/config-remote-sync/variable_reference_parent/out.test.toml index f574949a89d..8c2cb31de53 100644 --- a/acceptance/bundle/config-remote-sync/variable_reference_parent/out.test.toml +++ b/acceptance/bundle/config-remote-sync/variable_reference_parent/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/config-remote-sync/variable_reference_parent/test.toml b/acceptance/bundle/config-remote-sync/variable_reference_parent/test.toml index f1d8d0468b0..4a0348ad065 100644 --- a/acceptance/bundle/config-remote-sync/variable_reference_parent/test.toml +++ b/acceptance/bundle/config-remote-sync/variable_reference_parent/test.toml @@ -5,5 +5,3 @@ RecordRequests = true Ignore = [".databricks", "databricks.yml", "databricks.yml.backup"] Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/debug/fetch-repository-info-repos-error/out.test.toml b/acceptance/bundle/debug/fetch-repository-info-repos-error/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/debug/fetch-repository-info-repos-error/out.test.toml +++ b/acceptance/bundle/debug/fetch-repository-info-repos-error/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/debug/fetch-repository-info-repos-error/test.toml b/acceptance/bundle/debug/fetch-repository-info-repos-error/test.toml index 9993005d754..3b30595f0b8 100644 --- a/acceptance/bundle/debug/fetch-repository-info-repos-error/test.toml +++ b/acceptance/bundle/debug/fetch-repository-info-repos-error/test.toml @@ -2,4 +2,3 @@ Cloud = false # This exercises git.FetchRepositoryInfo, which is independent of the deploy engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/debug/fetch-repository-info/out.test.toml b/acceptance/bundle/debug/fetch-repository-info/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/debug/fetch-repository-info/out.test.toml +++ b/acceptance/bundle/debug/fetch-repository-info/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/debug/fetch-repository-info/test.toml b/acceptance/bundle/debug/fetch-repository-info/test.toml index 4ad61829cbe..057e7be73f6 100644 --- a/acceptance/bundle/debug/fetch-repository-info/test.toml +++ b/acceptance/bundle/debug/fetch-repository-info/test.toml @@ -1,7 +1,6 @@ Cloud = true # This exercises git.FetchRepositoryInfo, which is independent of the deploy engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # Keep Git Bash from rewriting the /Workspace paths passed to --path. Env.MSYS_NO_PATHCONV = "1" diff --git a/acceptance/bundle/debug/list-targets/out.test.toml b/acceptance/bundle/debug/list-targets/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/debug/list-targets/out.test.toml +++ b/acceptance/bundle/debug/list-targets/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/debug/out.test.toml b/acceptance/bundle/debug/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/debug/out.test.toml +++ b/acceptance/bundle/debug/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/empty-bundle/out.test.toml b/acceptance/bundle/deploy/empty-bundle/out.test.toml index dc095674ca0..772e01a6326 100644 --- a/acceptance/bundle/deploy/empty-bundle/out.test.toml +++ b/acceptance/bundle/deploy/empty-bundle/out.test.toml @@ -1,4 +1,3 @@ Cloud = true EnvMatrix.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = ["", "true"] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/experimental-python/out.test.toml b/acceptance/bundle/deploy/experimental-python/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/deploy/experimental-python/out.test.toml +++ b/acceptance/bundle/deploy/experimental-python/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/fail-on-active-runs/out.test.toml b/acceptance/bundle/deploy/fail-on-active-runs/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/deploy/fail-on-active-runs/out.test.toml +++ b/acceptance/bundle/deploy/fail-on-active-runs/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/files/no-snapshot-sync/out.test.toml b/acceptance/bundle/deploy/files/no-snapshot-sync/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/deploy/files/no-snapshot-sync/out.test.toml +++ b/acceptance/bundle/deploy/files/no-snapshot-sync/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/files/out-of-band-delete/out.test.toml b/acceptance/bundle/deploy/files/out-of-band-delete/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/deploy/files/out-of-band-delete/out.test.toml +++ b/acceptance/bundle/deploy/files/out-of-band-delete/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deploy/force-lock-config/out.test.toml b/acceptance/bundle/deploy/force-lock-config/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/deploy/force-lock-config/out.test.toml +++ b/acceptance/bundle/deploy/force-lock-config/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/immutable-no-artifacts/out.test.toml b/acceptance/bundle/deploy/immutable-no-artifacts/out.test.toml index dd03baaabb6..f7fafbcc731 100644 --- a/acceptance/bundle/deploy/immutable-no-artifacts/out.test.toml +++ b/acceptance/bundle/deploy/immutable-no-artifacts/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/deploy/immutable-no-artifacts/test.toml b/acceptance/bundle/deploy/immutable-no-artifacts/test.toml index 202e70986d8..f978d3c3f42 100644 --- a/acceptance/bundle/deploy/immutable-no-artifacts/test.toml +++ b/acceptance/bundle/deploy/immutable-no-artifacts/test.toml @@ -3,7 +3,6 @@ RecordRequests = true EnvMatrix.READPLAN = ["", "1"] # immutable_folder only works with the direct engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ "databricks.yml", diff --git a/acceptance/bundle/deploy/immutable-permissions-change/out.test.toml b/acceptance/bundle/deploy/immutable-permissions-change/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/deploy/immutable-permissions-change/out.test.toml +++ b/acceptance/bundle/deploy/immutable-permissions-change/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/immutable-permissions-change/test.toml b/acceptance/bundle/deploy/immutable-permissions-change/test.toml index 88b225ea71f..0439d8243bc 100644 --- a/acceptance/bundle/deploy/immutable-permissions-change/test.toml +++ b/acceptance/bundle/deploy/immutable-permissions-change/test.toml @@ -1,7 +1,6 @@ Cloud = false # Temporary disable cloud tests until the API is fully available # immutable_folder only works with the direct engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ "databricks.yml", diff --git a/acceptance/bundle/deploy/immutable/out.test.toml b/acceptance/bundle/deploy/immutable/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/deploy/immutable/out.test.toml +++ b/acceptance/bundle/deploy/immutable/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/immutable/test.toml b/acceptance/bundle/deploy/immutable/test.toml index 2a37b8f1280..d9dfe07d910 100644 --- a/acceptance/bundle/deploy/immutable/test.toml +++ b/acceptance/bundle/deploy/immutable/test.toml @@ -1,7 +1,6 @@ Cloud = false # Temporary disable cloud tests until the API is fully available # immutable_folder only works with the direct engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ "dist", diff --git a/acceptance/bundle/deploy/mlops-stacks/out.test.toml b/acceptance/bundle/deploy/mlops-stacks/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/deploy/mlops-stacks/out.test.toml +++ b/acceptance/bundle/deploy/mlops-stacks/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/partial-summary-on-push-fail/out.test.toml b/acceptance/bundle/deploy/partial-summary-on-push-fail/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/deploy/partial-summary-on-push-fail/out.test.toml +++ b/acceptance/bundle/deploy/partial-summary-on-push-fail/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/partial-summary-on-push-fail/test.toml b/acceptance/bundle/deploy/partial-summary-on-push-fail/test.toml index 7ad1225aec5..01dc2713a99 100644 --- a/acceptance/bundle/deploy/partial-summary-on-push-fail/test.toml +++ b/acceptance/bundle/deploy/partial-summary-on-push-fail/test.toml @@ -4,5 +4,4 @@ # # The injected path is the direct-engine state file (state/resources.json), so # this runs on the direct engine only. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [".databricks", ".gitignore"] diff --git a/acceptance/bundle/deploy/pipeline-config-dots/out.test.toml b/acceptance/bundle/deploy/pipeline-config-dots/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/deploy/pipeline-config-dots/out.test.toml +++ b/acceptance/bundle/deploy/pipeline-config-dots/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/python-notebook/out.test.toml b/acceptance/bundle/deploy/python-notebook/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/deploy/python-notebook/out.test.toml +++ b/acceptance/bundle/deploy/python-notebook/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/readplan/basic/out.test.toml b/acceptance/bundle/deploy/readplan/basic/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/deploy/readplan/basic/out.test.toml +++ b/acceptance/bundle/deploy/readplan/basic/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/readplan/basic/test.toml b/acceptance/bundle/deploy/readplan/basic/test.toml index c026765cce2..301a964aeef 100644 --- a/acceptance/bundle/deploy/readplan/basic/test.toml +++ b/acceptance/bundle/deploy/readplan/basic/test.toml @@ -1,4 +1,3 @@ # Test basic --plan functionality -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] RecordRequests = true Ignore = ["tmp.plan_*.json"] diff --git a/acceptance/bundle/deploy/readplan/cli-version-mismatch/out.test.toml b/acceptance/bundle/deploy/readplan/cli-version-mismatch/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/deploy/readplan/cli-version-mismatch/out.test.toml +++ b/acceptance/bundle/deploy/readplan/cli-version-mismatch/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/readplan/cli-version-mismatch/test.toml b/acceptance/bundle/deploy/readplan/cli-version-mismatch/test.toml index c8f942fbf84..5d09f246c37 100644 --- a/acceptance/bundle/deploy/readplan/cli-version-mismatch/test.toml +++ b/acceptance/bundle/deploy/readplan/cli-version-mismatch/test.toml @@ -1,3 +1,2 @@ # Test that --plan with different cli_version produces a warning but succeeds -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] RecordRequests = true diff --git a/acceptance/bundle/deploy/readplan/grants-remove-principal/out.test.toml b/acceptance/bundle/deploy/readplan/grants-remove-principal/out.test.toml index dd03baaabb6..f7fafbcc731 100644 --- a/acceptance/bundle/deploy/readplan/grants-remove-principal/out.test.toml +++ b/acceptance/bundle/deploy/readplan/grants-remove-principal/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/deploy/readplan/grants-remove-principal/test.toml b/acceptance/bundle/deploy/readplan/grants-remove-principal/test.toml index 75904d6e3da..fd9213de255 100644 --- a/acceptance/bundle/deploy/readplan/grants-remove-principal/test.toml +++ b/acceptance/bundle/deploy/readplan/grants-remove-principal/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.READPLAN = ["", "1"] RecordRequests = true Ignore = ["tmp.plan.json"] diff --git a/acceptance/bundle/deploy/readplan/invalid-plan/out.test.toml b/acceptance/bundle/deploy/readplan/invalid-plan/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/deploy/readplan/invalid-plan/out.test.toml +++ b/acceptance/bundle/deploy/readplan/invalid-plan/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/readplan/invalid-plan/test.toml b/acceptance/bundle/deploy/readplan/invalid-plan/test.toml deleted file mode 100644 index 8a6becefe0a..00000000000 --- a/acceptance/bundle/deploy/readplan/invalid-plan/test.toml +++ /dev/null @@ -1,2 +0,0 @@ -# Test that --plan with invalid JSON produces an error -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/deploy/readplan/lineage-mismatch/out.test.toml b/acceptance/bundle/deploy/readplan/lineage-mismatch/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/deploy/readplan/lineage-mismatch/out.test.toml +++ b/acceptance/bundle/deploy/readplan/lineage-mismatch/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/readplan/lineage-mismatch/plan.direct.json b/acceptance/bundle/deploy/readplan/lineage-mismatch/plan.nohistory.json similarity index 100% rename from acceptance/bundle/deploy/readplan/lineage-mismatch/plan.direct.json rename to acceptance/bundle/deploy/readplan/lineage-mismatch/plan.nohistory.json diff --git a/acceptance/bundle/deploy/readplan/lineage-mismatch/script b/acceptance/bundle/deploy/readplan/lineage-mismatch/script index e6601a86c5b..c60753739a7 100644 --- a/acceptance/bundle/deploy/readplan/lineage-mismatch/script +++ b/acceptance/bundle/deploy/readplan/lineage-mismatch/script @@ -1,7 +1,7 @@ # The plan is committed rather than generated, so it must match the shape of the target it is fed # to: a recorded target's state carries the deployment_history feature, and validatePlan rejects a # plan whose features differ before it looks at lineage. -plan=plan.direct.json +plan=plan.nohistory.json if [ "$DATABRICKS_BUNDLE_DEPLOYMENT_HISTORY" = "true" ]; then plan=plan.dms.json fi diff --git a/acceptance/bundle/deploy/readplan/lineage-mismatch/test.toml b/acceptance/bundle/deploy/readplan/lineage-mismatch/test.toml deleted file mode 100644 index de0ba18b25f..00000000000 --- a/acceptance/bundle/deploy/readplan/lineage-mismatch/test.toml +++ /dev/null @@ -1,2 +0,0 @@ -# Test that --plan with mismatched lineage produces an error -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/deploy/readplan/plan-not-found/out.test.toml b/acceptance/bundle/deploy/readplan/plan-not-found/out.test.toml index 429e714df15..8c2cb31de53 100644 --- a/acceptance/bundle/deploy/readplan/plan-not-found/out.test.toml +++ b/acceptance/bundle/deploy/readplan/plan-not-found/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/readplan/plan-not-found/test.toml b/acceptance/bundle/deploy/readplan/plan-not-found/test.toml index 5ed97a8d220..490d17654af 100644 --- a/acceptance/bundle/deploy/readplan/plan-not-found/test.toml +++ b/acceptance/bundle/deploy/readplan/plan-not-found/test.toml @@ -1,5 +1,4 @@ # Test that --plan with missing file produces an error -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # different error message on Windows GOOS.windows = false diff --git a/acceptance/bundle/deploy/readplan/plan-version-mismatch/out.test.toml b/acceptance/bundle/deploy/readplan/plan-version-mismatch/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/deploy/readplan/plan-version-mismatch/out.test.toml +++ b/acceptance/bundle/deploy/readplan/plan-version-mismatch/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/readplan/plan-version-mismatch/test.toml b/acceptance/bundle/deploy/readplan/plan-version-mismatch/test.toml deleted file mode 100644 index 4530e5f8f55..00000000000 --- a/acceptance/bundle/deploy/readplan/plan-version-mismatch/test.toml +++ /dev/null @@ -1,2 +0,0 @@ -# Test that --plan with mismatched plan_version produces an error -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/deploy/readplan/postgres_role/out.test.toml b/acceptance/bundle/deploy/readplan/postgres_role/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/deploy/readplan/postgres_role/out.test.toml +++ b/acceptance/bundle/deploy/readplan/postgres_role/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/readplan/postgres_role/test.toml b/acceptance/bundle/deploy/readplan/postgres_role/test.toml index babde706a4f..0371f86a139 100644 --- a/acceptance/bundle/deploy/readplan/postgres_role/test.toml +++ b/acceptance/bundle/deploy/readplan/postgres_role/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] RecordRequests = true # Full plan fed to `deploy --plan`; the committed golden keeps only the role entry. diff --git a/acceptance/bundle/deploy/readplan/serial-mismatch/out.test.toml b/acceptance/bundle/deploy/readplan/serial-mismatch/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/deploy/readplan/serial-mismatch/out.test.toml +++ b/acceptance/bundle/deploy/readplan/serial-mismatch/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/readplan/serial-mismatch/test.toml b/acceptance/bundle/deploy/readplan/serial-mismatch/test.toml index dc4dcf06fc7..aee11c6dbf0 100644 --- a/acceptance/bundle/deploy/readplan/serial-mismatch/test.toml +++ b/acceptance/bundle/deploy/readplan/serial-mismatch/test.toml @@ -1,3 +1,2 @@ # Test that --plan with mismatched serial produces an error -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] RecordRequests = false diff --git a/acceptance/bundle/deploy/readplan/terraform-error/databricks.yml b/acceptance/bundle/deploy/readplan/terraform-error/databricks.yml deleted file mode 100644 index b93d6b5b021..00000000000 --- a/acceptance/bundle/deploy/readplan/terraform-error/databricks.yml +++ /dev/null @@ -1,7 +0,0 @@ -bundle: - name: test-bundle - -resources: - jobs: - job: - name: test-job diff --git a/acceptance/bundle/deploy/readplan/terraform-error/out.test.toml b/acceptance/bundle/deploy/readplan/terraform-error/out.test.toml deleted file mode 100644 index 5d0f3e4aac2..00000000000 --- a/acceptance/bundle/deploy/readplan/terraform-error/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] -EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/readplan/terraform-error/output.txt b/acceptance/bundle/deploy/readplan/terraform-error/output.txt deleted file mode 100644 index 63cfb10967e..00000000000 --- a/acceptance/bundle/deploy/readplan/terraform-error/output.txt +++ /dev/null @@ -1,4 +0,0 @@ -Error: --plan is only supported with direct engine (set bundle.engine to "direct" or DATABRICKS_BUNDLE_ENGINE=direct) - - -Exit code: 1 diff --git a/acceptance/bundle/deploy/readplan/terraform-error/plan.json b/acceptance/bundle/deploy/readplan/terraform-error/plan.json deleted file mode 100644 index 0967ef424bc..00000000000 --- a/acceptance/bundle/deploy/readplan/terraform-error/plan.json +++ /dev/null @@ -1 +0,0 @@ -{} diff --git a/acceptance/bundle/deploy/readplan/terraform-error/script b/acceptance/bundle/deploy/readplan/terraform-error/script deleted file mode 100644 index 9a05b826834..00000000000 --- a/acceptance/bundle/deploy/readplan/terraform-error/script +++ /dev/null @@ -1 +0,0 @@ -$CLI bundle deploy --plan plan.json diff --git a/acceptance/bundle/deploy/readplan/terraform-error/test.toml b/acceptance/bundle/deploy/readplan/terraform-error/test.toml deleted file mode 100644 index c9ad2c68ec1..00000000000 --- a/acceptance/bundle/deploy/readplan/terraform-error/test.toml +++ /dev/null @@ -1,2 +0,0 @@ -# Test that --plan with terraform engine produces an error -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] diff --git a/acceptance/bundle/deploy/readplan/unknown-field/out.test.toml b/acceptance/bundle/deploy/readplan/unknown-field/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/deploy/readplan/unknown-field/out.test.toml +++ b/acceptance/bundle/deploy/readplan/unknown-field/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/readplan/unknown-field/test.toml b/acceptance/bundle/deploy/readplan/unknown-field/test.toml deleted file mode 100644 index 0653828bd08..00000000000 --- a/acceptance/bundle/deploy/readplan/unknown-field/test.toml +++ /dev/null @@ -1,2 +0,0 @@ -# Test that --plan with unknown fields in the plan JSON produces an error -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/deploy/readplan/whl-not-uploaded/test.toml b/acceptance/bundle/deploy/readplan/whl-not-uploaded/test.toml index f971f7bb2ae..ef13b156702 100644 --- a/acceptance/bundle/deploy/readplan/whl-not-uploaded/test.toml +++ b/acceptance/bundle/deploy/readplan/whl-not-uploaded/test.toml @@ -1,6 +1,5 @@ Badness = "bundle deploy --plan skips the build phase, so a local wheel referenced by a job is never uploaded and the job fails at runtime." # --plan is direct-engine only. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] RecordRequests = true Ignore = [".databricks", "tmp.plan.json"] diff --git a/acceptance/bundle/deploy/readplan/whl-upload/out.test.toml b/acceptance/bundle/deploy/readplan/whl-upload/out.test.toml index 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/deploy/readplan/whl-upload/out.test.toml +++ b/acceptance/bundle/deploy/readplan/whl-upload/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deploy/readplan/whl-upload/test.toml b/acceptance/bundle/deploy/readplan/whl-upload/test.toml index 8e5c2176367..aad8dfa67f1 100644 --- a/acceptance/bundle/deploy/readplan/whl-upload/test.toml +++ b/acceptance/bundle/deploy/readplan/whl-upload/test.toml @@ -1,5 +1,4 @@ # --plan is direct-engine only. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # Saved plans don't carry the deployment stamp, so this test skips the DMS variant. EnvMatrix.DMS = [""] RecordRequests = true diff --git a/acceptance/bundle/deploy/resource-max-wait-zero/out.test.toml b/acceptance/bundle/deploy/resource-max-wait-zero/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/deploy/resource-max-wait-zero/out.test.toml +++ b/acceptance/bundle/deploy/resource-max-wait-zero/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/resource-max-wait-zero/test.toml b/acceptance/bundle/deploy/resource-max-wait-zero/test.toml index 3c8a65fabca..c906a3efc89 100644 --- a/acceptance/bundle/deploy/resource-max-wait-zero/test.toml +++ b/acceptance/bundle/deploy/resource-max-wait-zero/test.toml @@ -1,5 +1,4 @@ # The cap is read by the direct engine only. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] RecordRequests = true diff --git a/acceptance/bundle/deploy/resource-max-wait/out.test.toml b/acceptance/bundle/deploy/resource-max-wait/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/deploy/resource-max-wait/out.test.toml +++ b/acceptance/bundle/deploy/resource-max-wait/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/resource-max-wait/test.toml b/acceptance/bundle/deploy/resource-max-wait/test.toml deleted file mode 100644 index cb44a5e0409..00000000000 --- a/acceptance/bundle/deploy/resource-max-wait/test.toml +++ /dev/null @@ -1,5 +0,0 @@ -# Covers parsing of DATABRICKS_BUNDLE_RESOURCE_MAX_WAIT only. What the cap does to a wait -# is covered by ../resource-max-wait-zero, whose resource actually has one: jobs have no -# WaitAfterCreate, so a cap would be a no-op here. -# DATABRICKS_BUNDLE_RESOURCE_MAX_WAIT is read by the direct engine only. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/deploy/snapshot-comparison/databricks.yml.tmpl b/acceptance/bundle/deploy/snapshot-comparison/databricks.yml.tmpl deleted file mode 100644 index bcf33e49d8f..00000000000 --- a/acceptance/bundle/deploy/snapshot-comparison/databricks.yml.tmpl +++ /dev/null @@ -1,26 +0,0 @@ -bundle: - name: ${BUNDLE_NAME} - -workspace: - host: ${DATABRICKS_HOST} - -resources: - pipelines: - test_pipeline: - name: "Snapshot Test Pipeline ${BUNDLE_NAME}" - libraries: - - notebook: - path: "./pipeline_notebook.py" - development: true - - jobs: - test_job: - name: "Snapshot Test Job ${BUNDLE_NAME}" - tasks: - - task_key: "pipeline_task" - pipeline_task: - pipeline_id: ${resources.pipelines.test_pipeline.id} - -targets: - default: - mode: development diff --git a/acceptance/bundle/deploy/snapshot-comparison/notebook.py b/acceptance/bundle/deploy/snapshot-comparison/notebook.py deleted file mode 100644 index 8cfae7c74fa..00000000000 --- a/acceptance/bundle/deploy/snapshot-comparison/notebook.py +++ /dev/null @@ -1,2 +0,0 @@ -# Databricks notebook source -print("Test notebook") diff --git a/acceptance/bundle/deploy/snapshot-comparison/out.test.toml b/acceptance/bundle/deploy/snapshot-comparison/out.test.toml deleted file mode 100644 index 19131430a06..00000000000 --- a/acceptance/bundle/deploy/snapshot-comparison/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] -EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/snapshot-comparison/output.txt b/acceptance/bundle/deploy/snapshot-comparison/output.txt deleted file mode 100644 index 35c1b7ad43d..00000000000 --- a/acceptance/bundle/deploy/snapshot-comparison/output.txt +++ /dev/null @@ -1,67 +0,0 @@ - -=== Deploy bundle 1 with terraform ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/snapshot-test-1-[UNIQUE_NAME]/default/files... -Created jobs.test_job -Created pipelines.test_pipeline -Files: 3 uploaded, 0 deleted -Resources: 2 created, 0 changed, 0 deleted, 0 unchanged - -=== Run migrate on bundle 1 ->>> [CLI] bundle deployment migrate -Success! Migrated 2 resources to direct engine state file: [TEST_TMP_DIR]/bundle1/.databricks/bundle/default/resources.json - -Validate the migration by running "databricks bundle plan", there should be no actions planned. - -The state file is not synchronized to the workspace yet. To do that and finalize the migration, run "bundle deploy". - -To undo the migration, remove [TEST_TMP_DIR]/bundle1/.databricks/bundle/default/resources.json and rename [TEST_TMP_DIR]/bundle1/.databricks/bundle/default/terraform/terraform.tfstate.backup to [TEST_TMP_DIR]/bundle1/.databricks/bundle/default/terraform/terraform.tfstate - - -=== Deploy bundle 2 with terraform and YamlSync ->>> DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC=true DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/snapshot-test-2-[UNIQUE_NAME]/default/files... -Created jobs.test_job -Created pipelines.test_pipeline -Files: 3 uploaded, 0 deleted -Resources: 2 created, 0 changed, 0 deleted, 0 unchanged - -=== Normalize bundle names for comparison ->>> cp bundle1/.databricks/bundle/default/resources.json tmp.bundle1.json - ->>> cp bundle2/.databricks/bundle/default/resources-config-sync-snapshot.json tmp.bundle2.json - ->>> update_file.py tmp.bundle1.json snapshot-test-1- snapshot-test-NORMALIZED- - ->>> update_file.py tmp.bundle2.json snapshot-test-2- snapshot-test-NORMALIZED- - -=== Compare normalized snapshots ->>> diff.py tmp.bundle1.json tmp.bundle2.json - -=== Cleanup bundle 1 ->>> [CLI] bundle destroy --auto-approve -The following resources will be deleted: - delete resources.jobs.test_job - delete resources.pipelines.test_pipeline - -This action will result in the deletion of the following Lakeflow Spark Declarative Pipelines along with the -Streaming Tables (STs) and Materialized Views (MVs) managed by them. Set 'cascade_on_destroy: false' on a pipeline to retain datasets on pipeline deletion: - delete resources.pipelines.test_pipeline - -All files and directories at the following location will be deleted: /Workspace/Users/[USERNAME]/.bundle/snapshot-test-1-[UNIQUE_NAME]/default - -Destroy: 2 deleted - -=== Cleanup bundle 2 ->>> [CLI] bundle destroy --auto-approve -The following resources will be deleted: - delete resources.jobs.test_job - delete resources.pipelines.test_pipeline - -This action will result in the deletion of the following Lakeflow Spark Declarative Pipelines along with the -Streaming Tables (STs) and Materialized Views (MVs) managed by them. Set 'cascade_on_destroy: false' on a pipeline to retain datasets on pipeline deletion: - delete resources.pipelines.test_pipeline - -All files and directories at the following location will be deleted: /Workspace/Users/[USERNAME]/.bundle/snapshot-test-2-[UNIQUE_NAME]/default - -Destroy: 2 deleted diff --git a/acceptance/bundle/deploy/snapshot-comparison/pipeline_notebook.py b/acceptance/bundle/deploy/snapshot-comparison/pipeline_notebook.py deleted file mode 100644 index 4dc99b53098..00000000000 --- a/acceptance/bundle/deploy/snapshot-comparison/pipeline_notebook.py +++ /dev/null @@ -1,2 +0,0 @@ -# Databricks notebook source -print("Test pipeline notebook") diff --git a/acceptance/bundle/deploy/snapshot-comparison/script b/acceptance/bundle/deploy/snapshot-comparison/script deleted file mode 100755 index c0a83c947f1..00000000000 --- a/acceptance/bundle/deploy/snapshot-comparison/script +++ /dev/null @@ -1,42 +0,0 @@ -#!/bin/bash - -mkdir -p bundle1 bundle2 - -export BUNDLE_NAME="snapshot-test-1-${UNIQUE_NAME}" -envsubst < databricks.yml.tmpl > bundle1/databricks.yml -cp notebook.py bundle1/ -cp pipeline_notebook.py bundle1/ - -export BUNDLE_NAME="snapshot-test-2-${UNIQUE_NAME}" -envsubst < databricks.yml.tmpl > bundle2/databricks.yml -cp notebook.py bundle2/ -cp pipeline_notebook.py bundle2/ - -cleanup() { - title "Cleanup bundle 1" - (cd bundle1 && unset DATABRICKS_BUNDLE_ENGINE && trace $CLI bundle destroy --auto-approve) - title "Cleanup bundle 2" - (cd bundle2 && unset DATABRICKS_BUNDLE_ENGINE && trace $CLI bundle destroy --auto-approve) - - rm -f "$OUT_REQUESTS" -} -trap cleanup EXIT - -title "Deploy bundle 1 with terraform" -(cd bundle1 && trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy) - -title "Run migrate on bundle 1" -(cd bundle1 && trace $CLI bundle deployment migrate 2>&1 | contains.py 'Migrated 2 resources') - -title "Deploy bundle 2 with terraform and YamlSync" -(cd bundle2 && trace DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC=true DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy) - -title "Normalize bundle names for comparison" -trace cp bundle1/.databricks/bundle/default/resources.json tmp.bundle1.json -trace cp bundle2/.databricks/bundle/default/resources-config-sync-snapshot.json tmp.bundle2.json - -trace update_file.py tmp.bundle1.json "snapshot-test-1-" "snapshot-test-NORMALIZED-" -trace update_file.py tmp.bundle2.json "snapshot-test-2-" "snapshot-test-NORMALIZED-" - -title "Compare normalized snapshots" -trace diff.py tmp.bundle1.json tmp.bundle2.json diff --git a/acceptance/bundle/deploy/snapshot-comparison/test.toml b/acceptance/bundle/deploy/snapshot-comparison/test.toml deleted file mode 100644 index aa750e154f6..00000000000 --- a/acceptance/bundle/deploy/snapshot-comparison/test.toml +++ /dev/null @@ -1,15 +0,0 @@ -Cloud = true - -RecordRequests = true - -Ignore = [ - ".databricks", - "databricks.yml", - "tmp.*", - "bundle1", - "bundle2" -] - -Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] diff --git a/acceptance/bundle/deploy/spark-jar-task/out.test.toml b/acceptance/bundle/deploy/spark-jar-task/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/deploy/spark-jar-task/out.test.toml +++ b/acceptance/bundle/deploy/spark-jar-task/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/spark-jar-task/test.toml b/acceptance/bundle/deploy/spark-jar-task/test.toml index 242b7278a8f..d4f48e2397e 100644 --- a/acceptance/bundle/deploy/spark-jar-task/test.toml +++ b/acceptance/bundle/deploy/spark-jar-task/test.toml @@ -1,5 +1,4 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] Ignore = [ 'myjar/PrintArgs.jar', diff --git a/acceptance/bundle/deploy/wal/chain-3-jobs/out.test.toml b/acceptance/bundle/deploy/wal/chain-3-jobs/out.test.toml index 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/deploy/wal/chain-3-jobs/out.test.toml +++ b/acceptance/bundle/deploy/wal/chain-3-jobs/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deploy/wal/corrupted-wal-entry/out.test.toml b/acceptance/bundle/deploy/wal/corrupted-wal-entry/out.test.toml index 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/deploy/wal/corrupted-wal-entry/out.test.toml +++ b/acceptance/bundle/deploy/wal/corrupted-wal-entry/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deploy/wal/crash-after-create/out.test.toml b/acceptance/bundle/deploy/wal/crash-after-create/out.test.toml index 9a7cc99433c..28505c1acaa 100644 --- a/acceptance/bundle/deploy/wal/crash-after-create/out.test.toml +++ b/acceptance/bundle/deploy/wal/crash-after-create/out.test.toml @@ -1,4 +1,3 @@ Cloud = false EnvMatrix.COMMAND = ["plan", "deploy --force-lock", "summary"] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deploy/wal/empty-wal/out.test.toml b/acceptance/bundle/deploy/wal/empty-wal/out.test.toml index 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/deploy/wal/empty-wal/out.test.toml +++ b/acceptance/bundle/deploy/wal/empty-wal/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deploy/wal/failed-plan-no-wal/out.test.toml b/acceptance/bundle/deploy/wal/failed-plan-no-wal/out.test.toml index 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/deploy/wal/failed-plan-no-wal/out.test.toml +++ b/acceptance/bundle/deploy/wal/failed-plan-no-wal/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deploy/wal/future-serial-wal/out.test.toml b/acceptance/bundle/deploy/wal/future-serial-wal/out.test.toml index 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/deploy/wal/future-serial-wal/out.test.toml +++ b/acceptance/bundle/deploy/wal/future-serial-wal/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deploy/wal/header-only-wal/out.test.toml b/acceptance/bundle/deploy/wal/header-only-wal/out.test.toml index 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/deploy/wal/header-only-wal/out.test.toml +++ b/acceptance/bundle/deploy/wal/header-only-wal/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deploy/wal/lineage-mismatch/out.test.toml b/acceptance/bundle/deploy/wal/lineage-mismatch/out.test.toml index 2845c70cfef..93e96ab2a1b 100644 --- a/acceptance/bundle/deploy/wal/lineage-mismatch/out.test.toml +++ b/acceptance/bundle/deploy/wal/lineage-mismatch/out.test.toml @@ -1,4 +1,3 @@ Cloud = false EnvMatrix.COMMAND = ["deploy", "plan", "summary"] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deploy/wal/stale-wal/out.test.toml b/acceptance/bundle/deploy/wal/stale-wal/out.test.toml index 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/deploy/wal/stale-wal/out.test.toml +++ b/acceptance/bundle/deploy/wal/stale-wal/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deploy/wal/test.toml b/acceptance/bundle/deploy/wal/test.toml index 512d9195cca..5d9bd382fcb 100644 --- a/acceptance/bundle/deploy/wal/test.toml +++ b/acceptance/bundle/deploy/wal/test.toml @@ -6,7 +6,6 @@ Env.DATABRICKS_CLI_TEST_PID = "1" -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] [[Repls]] diff --git a/acceptance/bundle/deploy/wal/wal-with-delete/out.test.toml b/acceptance/bundle/deploy/wal/wal-with-delete/out.test.toml index 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/deploy/wal/wal-with-delete/out.test.toml +++ b/acceptance/bundle/deploy/wal/wal-with-delete/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deploy/yaml-sync-empty-grants/databricks.yml b/acceptance/bundle/deploy/yaml-sync-empty-grants/databricks.yml deleted file mode 100644 index 87958c8e630..00000000000 --- a/acceptance/bundle/deploy/yaml-sync-empty-grants/databricks.yml +++ /dev/null @@ -1,9 +0,0 @@ -bundle: - name: yaml-sync-empty-grants - -resources: - schemas: - schema1: - name: myschema - catalog_name: main - grants: [] diff --git a/acceptance/bundle/deploy/yaml-sync-empty-grants/out.test.toml b/acceptance/bundle/deploy/yaml-sync-empty-grants/out.test.toml deleted file mode 100644 index 5d0f3e4aac2..00000000000 --- a/acceptance/bundle/deploy/yaml-sync-empty-grants/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] -EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/deploy/yaml-sync-empty-grants/output.txt b/acceptance/bundle/deploy/yaml-sync-empty-grants/output.txt deleted file mode 100644 index f4c284e8c81..00000000000 --- a/acceptance/bundle/deploy/yaml-sync-empty-grants/output.txt +++ /dev/null @@ -1,6 +0,0 @@ - ->>> [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/yaml-sync-empty-grants/default/files... -Created schemas.schema1 -Files: 3 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged diff --git a/acceptance/bundle/deploy/yaml-sync-empty-grants/script b/acceptance/bundle/deploy/yaml-sync-empty-grants/script deleted file mode 100644 index 68ebb78d775..00000000000 --- a/acceptance/bundle/deploy/yaml-sync-empty-grants/script +++ /dev/null @@ -1 +0,0 @@ -trace $CLI bundle deploy diff --git a/acceptance/bundle/deploy/yaml-sync-empty-grants/test.toml b/acceptance/bundle/deploy/yaml-sync-empty-grants/test.toml deleted file mode 100644 index f0630d5dacd..00000000000 --- a/acceptance/bundle/deploy/yaml-sync-empty-grants/test.toml +++ /dev/null @@ -1,4 +0,0 @@ -# The YAML-sync state upload only runs for the terraform engine; no direct-engine variant. -Env.DATABRICKS_BUNDLE_ENABLE_EXPERIMENTAL_YAML_SYNC = "true" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] diff --git a/acceptance/bundle/deployment/bind/alert/out.test.toml b/acceptance/bundle/deployment/bind/alert/out.test.toml index 9b8ddfcd2bd..f68b4a89c36 100644 --- a/acceptance/bundle/deployment/bind/alert/out.test.toml +++ b/acceptance/bundle/deployment/bind/alert/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/catalog/out.test.toml b/acceptance/bundle/deployment/bind/catalog/out.test.toml index d73c45e3119..f68b4a89c36 100644 --- a/acceptance/bundle/deployment/bind/catalog/out.test.toml +++ b/acceptance/bundle/deployment/bind/catalog/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/catalog/test.toml b/acceptance/bundle/deployment/bind/catalog/test.toml index 2c0fd37fd17..a26bade48d0 100644 --- a/acceptance/bundle/deployment/bind/catalog/test.toml +++ b/acceptance/bundle/deployment/bind/catalog/test.toml @@ -4,5 +4,3 @@ Ignore = [ ".databricks", "databricks.yml", ] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/deployment/bind/cluster/out.test.toml b/acceptance/bundle/deployment/bind/cluster/out.test.toml index 9b8ddfcd2bd..f68b4a89c36 100644 --- a/acceptance/bundle/deployment/bind/cluster/out.test.toml +++ b/acceptance/bundle/deployment/bind/cluster/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/dashboard/out.test.toml b/acceptance/bundle/deployment/bind/dashboard/out.test.toml index 2acec25aece..de136de256d 100644 --- a/acceptance/bundle/deployment/bind/dashboard/out.test.toml +++ b/acceptance/bundle/deployment/bind/dashboard/out.test.toml @@ -1,4 +1,3 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/deployment/bind/dashboard/output.txt b/acceptance/bundle/deployment/bind/dashboard/output.txt index 8cb10c92120..e7ce9199698 100644 --- a/acceptance/bundle/deployment/bind/dashboard/output.txt +++ b/acceptance/bundle/deployment/bind/dashboard/output.txt @@ -4,7 +4,7 @@ Successfully bound dashboard with an id '[DASHBOARD_ID]' Run 'bundle deploy' to deploy changes to your workspace Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle-[UNIQUE_NAME]/default/files... Updated dashboards.dashboard1 -Files: 12 uploaded, 0 deleted +Files: 11 uploaded, 0 deleted Resources: 0 created, 1 changed, 0 deleted, 0 unchanged >>> [CLI] lakeview get [DASHBOARD_ID] diff --git a/acceptance/bundle/deployment/bind/dashboard/recreation/out.state_after_bind.direct.json b/acceptance/bundle/deployment/bind/dashboard/recreation/out.state_after_bind.json similarity index 100% rename from acceptance/bundle/deployment/bind/dashboard/recreation/out.state_after_bind.direct.json rename to acceptance/bundle/deployment/bind/dashboard/recreation/out.state_after_bind.json diff --git a/acceptance/bundle/deployment/bind/dashboard/recreation/out.state_after_bind.terraform.json b/acceptance/bundle/deployment/bind/dashboard/recreation/out.state_after_bind.terraform.json deleted file mode 100644 index ca4b75342ea..00000000000 --- a/acceptance/bundle/deployment/bind/dashboard/recreation/out.state_after_bind.terraform.json +++ /dev/null @@ -1,47 +0,0 @@ -{ - "version": 4, - "terraform_version": "1.5.5", - "serial": 1, - "lineage": "[UUID]", - "outputs": {}, - "resources": [ - { - "mode": "managed", - "type": "databricks_dashboard", - "name": "dashboard1", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 0, - "attributes": { - "create_time": "[TIMESTAMP]", - "dashboard_change_detected": false, - "dashboard_id": "[DASHBOARD_ID]", - "dataset_catalog": null, - "dataset_schema": null, - "display_name": "test dashboard [UNIQUE_NAME]", - "embed_credentials": false, - "etag": [ETAG], - "file_path": null, - "id": "[DASHBOARD_ID]", - "lifecycle_state": "ACTIVE", - "md5": null, - "parent_path": "/Users/[USERNAME]", - "path": "/Users/[USERNAME]/test dashboard [UNIQUE_NAME].lvdash.json", - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "serialized_dashboard": "{\"pages\":[{\"displayName\":\"Untitled page\",\"name\":\"02724bf2\",\"pageType\":\"PAGE_TYPE_CANVAS\"}]}", - "update_time": "[TIMESTAMP]", - "warehouse_id": "[TEST_DEFAULT_WAREHOUSE_ID]" - }, - "sensitive_attributes": [], - "private": "eyJzY2hlbWFfdmVyc2lvbiI6IjAifQ==" - } - ] - } - ], - "check_results": null -} diff --git a/acceptance/bundle/deployment/bind/dashboard/recreation/out.test.toml b/acceptance/bundle/deployment/bind/dashboard/recreation/out.test.toml index 2acec25aece..de136de256d 100644 --- a/acceptance/bundle/deployment/bind/dashboard/recreation/out.test.toml +++ b/acceptance/bundle/deployment/bind/dashboard/recreation/out.test.toml @@ -1,4 +1,3 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/deployment/bind/dashboard/recreation/script b/acceptance/bundle/deployment/bind/dashboard/recreation/script index ce63de92924..9d9f5cacf2f 100644 --- a/acceptance/bundle/deployment/bind/dashboard/recreation/script +++ b/acceptance/bundle/deployment/bind/dashboard/recreation/script @@ -13,11 +13,11 @@ cleanupRemoveDashboard() { trap cleanupRemoveDashboard EXIT trace $CLI bundle deployment bind dashboard1 "${DASHBOARD_ID}" --auto-approve -trace print_state.py > out.state_after_bind.$DATABRICKS_BUNDLE_ENGINE.json -ETAG=$(jq '.state["resources.dashboards.dashboard1"].state.etag // .resources[0].instances[0].attributes.etag // "no-etag"' < out.state_after_bind.$DATABRICKS_BUNDLE_ENGINE.json) +trace print_state.py > 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 -json_in_json_normalize.py out.state_after_bind.$DATABRICKS_BUNDLE_ENGINE.json +json_in_json_normalize.py out.state_after_bind.json trace $CLI bundle plan $CLI bundle plan -o json > tmp.plan.json diff --git a/acceptance/bundle/deployment/bind/database_instance/out.test.toml b/acceptance/bundle/deployment/bind/database_instance/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/deployment/bind/database_instance/out.test.toml +++ b/acceptance/bundle/deployment/bind/database_instance/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/experiment/out.plan1.direct.json b/acceptance/bundle/deployment/bind/experiment/out.plan1.json similarity index 100% rename from acceptance/bundle/deployment/bind/experiment/out.plan1.direct.json rename to acceptance/bundle/deployment/bind/experiment/out.plan1.json diff --git a/acceptance/bundle/deployment/bind/experiment/out.plan1.terraform.json b/acceptance/bundle/deployment/bind/experiment/out.plan1.terraform.json deleted file mode 100644 index 884cb9c919a..00000000000 --- a/acceptance/bundle/deployment/bind/experiment/out.plan1.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "plan": { - "resources.experiments.experiment1": { - "action": "skip", - "name_change": null - } - } -} diff --git a/acceptance/bundle/deployment/bind/experiment/out.plan2.direct.json b/acceptance/bundle/deployment/bind/experiment/out.plan2.json similarity index 100% rename from acceptance/bundle/deployment/bind/experiment/out.plan2.direct.json rename to acceptance/bundle/deployment/bind/experiment/out.plan2.json diff --git a/acceptance/bundle/deployment/bind/experiment/out.plan2.terraform.json b/acceptance/bundle/deployment/bind/experiment/out.plan2.terraform.json deleted file mode 100644 index 884cb9c919a..00000000000 --- a/acceptance/bundle/deployment/bind/experiment/out.plan2.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "plan": { - "resources.experiments.experiment1": { - "action": "skip", - "name_change": null - } - } -} diff --git a/acceptance/bundle/deployment/bind/experiment/out.test.toml b/acceptance/bundle/deployment/bind/experiment/out.test.toml index 9b8ddfcd2bd..f68b4a89c36 100644 --- a/acceptance/bundle/deployment/bind/experiment/out.test.toml +++ b/acceptance/bundle/deployment/bind/experiment/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/experiment/script b/acceptance/bundle/deployment/bind/experiment/script index e4528d6b24c..b2b41897e48 100644 --- a/acceptance/bundle/deployment/bind/experiment/script +++ b/acceptance/bundle/deployment/bind/experiment/script @@ -21,7 +21,7 @@ trace $CLI bundle deploy --force-lock --auto-approve # Use --output json to verify the change details including skip reason. # Write per-engine output since direct includes change details that terraform doesn't. # Filter to only the name change (tags/artifact_location may differ between local and cloud). -$CLI bundle plan --output json | nostamp | jq '{plan: .plan | map_values({action, name_change: (.changes.name // null)})}' > out.plan1.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan --output json | nostamp | jq '{plan: .plan | map_values({action, name_change: (.changes.name // null)})}' > out.plan1.json trace $CLI experiments get-experiment ${EXPERIMENT_ID} | jq '{name: .experiment.name, lifecycle_stage: .experiment.lifecycle_stage}' @@ -29,7 +29,7 @@ trace $CLI experiments get-experiment ${EXPERIMENT_ID} | jq '{name: .experiment. # Plan should still show no changes because the diff is suppressed. EXPERIMENT_NAME="//Users/${CURRENT_USER_NAME}/test-experiment$UNIQUE_NAME" envsubst < databricks.yml.tmpl > databricks.yml -$CLI bundle plan --output json | nostamp | jq '{plan: .plan | map_values({action, name_change: (.changes.name // null)})}' > out.plan2.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan --output json | nostamp | jq '{plan: .plan | map_values({action, name_change: (.changes.name // null)})}' > out.plan2.json trace $CLI bundle deployment unbind experiment1 diff --git a/acceptance/bundle/deployment/bind/external_location/out.test.toml b/acceptance/bundle/deployment/bind/external_location/out.test.toml index 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/deployment/bind/external_location/out.test.toml +++ b/acceptance/bundle/deployment/bind/external_location/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/external_location/test.toml b/acceptance/bundle/deployment/bind/external_location/test.toml index a9a6605ad30..c1bde723431 100644 --- a/acceptance/bundle/deployment/bind/external_location/test.toml +++ b/acceptance/bundle/deployment/bind/external_location/test.toml @@ -4,5 +4,3 @@ Ignore = [ ".databricks", "databricks.yml", ] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/deployment/bind/genie_space/out.test.toml b/acceptance/bundle/deployment/bind/genie_space/out.test.toml index 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/deployment/bind/genie_space/out.test.toml +++ b/acceptance/bundle/deployment/bind/genie_space/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/genie_space/test.toml b/acceptance/bundle/deployment/bind/genie_space/test.toml index 6bf62978384..792fc26cd6a 100644 --- a/acceptance/bundle/deployment/bind/genie_space/test.toml +++ b/acceptance/bundle/deployment/bind/genie_space/test.toml @@ -1,5 +1,4 @@ # Genie spaces are only deployed via the direct deployment engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # Uses a literal warehouse id and a version-sensitive serialized_space, so this # lifecycle test runs against the local mock server only (overrides the Cloud=true diff --git a/acceptance/bundle/deployment/bind/job/already-managed-different/out.bind.terraform.txt b/acceptance/bundle/deployment/bind/job/already-managed-different/out.bind.terraform.txt deleted file mode 100644 index 0415fee5299..00000000000 --- a/acceptance/bundle/deployment/bind/job/already-managed-different/out.bind.terraform.txt +++ /dev/null @@ -1,12 +0,0 @@ - ->>> musterr [CLI] bundle deployment bind foo [NEW_JOB_ID] -Error: terraform import: exit status 1 - -Error: Resource already managed by Terraform - -Terraform is already managing a remote object for databricks_job.foo. To -import to this address you must first remove the existing object from the -state. - - - diff --git a/acceptance/bundle/deployment/bind/job/already-managed-different/out.bind.direct.txt b/acceptance/bundle/deployment/bind/job/already-managed-different/out.bind.txt similarity index 100% rename from acceptance/bundle/deployment/bind/job/already-managed-different/out.bind.direct.txt rename to acceptance/bundle/deployment/bind/job/already-managed-different/out.bind.txt 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 ae800809893..19b5b15d11f 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,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/job/already-managed-different/script b/acceptance/bundle/deployment/bind/job/already-managed-different/script index e36fdd856ad..a844b9cbdbe 100644 --- a/acceptance/bundle/deployment/bind/job/already-managed-different/script +++ b/acceptance/bundle/deployment/bind/job/already-managed-different/script @@ -5,4 +5,4 @@ replace_ids.py new_job_id=$(trace $CLI jobs create --json '{"name": "My Job"}' | jq -r '.job_id') add_repl $new_job_id NEW_JOB_ID -trace musterr $CLI bundle deployment bind foo $new_job_id &> out.bind.$DATABRICKS_BUNDLE_ENGINE.txt +trace musterr $CLI bundle deployment bind foo $new_job_id &> out.bind.txt diff --git a/acceptance/bundle/deployment/bind/job/already-managed-different/test.toml b/acceptance/bundle/deployment/bind/job/already-managed-different/test.toml index dfbe1eeee99..18b1a88417e 100644 --- a/acceptance/bundle/deployment/bind/job/already-managed-different/test.toml +++ b/acceptance/bundle/deployment/bind/job/already-managed-different/test.toml @@ -1,3 +1 @@ Cloud = false - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/bundle/deployment/bind/job/already-managed-same/out.bind.terraform.txt b/acceptance/bundle/deployment/bind/job/already-managed-same/out.bind.terraform.txt deleted file mode 100644 index a3be6f2ee3c..00000000000 --- a/acceptance/bundle/deployment/bind/job/already-managed-same/out.bind.terraform.txt +++ /dev/null @@ -1,12 +0,0 @@ - ->>> musterr [CLI] bundle deployment bind foo [FOO_ID] -Error: terraform import: exit status 1 - -Error: Resource already managed by Terraform - -Terraform is already managing a remote object for databricks_job.foo. To -import to this address you must first remove the existing object from the -state. - - - diff --git a/acceptance/bundle/deployment/bind/job/already-managed-same/out.bind.direct.txt b/acceptance/bundle/deployment/bind/job/already-managed-same/out.bind.txt similarity index 100% rename from acceptance/bundle/deployment/bind/job/already-managed-same/out.bind.direct.txt rename to acceptance/bundle/deployment/bind/job/already-managed-same/out.bind.txt 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 ae800809893..19b5b15d11f 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,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/job/already-managed-same/script b/acceptance/bundle/deployment/bind/job/already-managed-same/script index a63358c112e..1d65e759e9f 100644 --- a/acceptance/bundle/deployment/bind/job/already-managed-same/script +++ b/acceptance/bundle/deployment/bind/job/already-managed-same/script @@ -4,5 +4,5 @@ trace $CLI bundle deploy job_id=$(read_id.py foo) -trace musterr $CLI bundle deployment bind foo $job_id &> out.bind.$DATABRICKS_BUNDLE_ENGINE.txt +trace musterr $CLI bundle deployment bind foo $job_id &> out.bind.txt trace $CLI bundle plan | contains.py "1 unchanged" 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 27ec2a7fcd6..19b5b15d11f 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,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/job/engine-from-config/test.toml b/acceptance/bundle/deployment/bind/job/engine-from-config/test.toml index 501c5e1294d..5c721ad6e79 100644 --- a/acceptance/bundle/deployment/bind/job/engine-from-config/test.toml +++ b/acceptance/bundle/deployment/bind/job/engine-from-config/test.toml @@ -1,4 +1,2 @@ Cloud = false # test leaves deployed job Ignore = [".databricks"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] 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 9b8ddfcd2bd..f68b4a89c36 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,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] 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 9b8ddfcd2bd..f68b4a89c36 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,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] 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 9b8ddfcd2bd..f68b4a89c36 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,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/job/noop-job/out.job.direct.json b/acceptance/bundle/deployment/bind/job/noop-job/out.job.json similarity index 100% rename from acceptance/bundle/deployment/bind/job/noop-job/out.job.direct.json rename to acceptance/bundle/deployment/bind/job/noop-job/out.job.json diff --git a/acceptance/bundle/deployment/bind/job/noop-job/out.job.terraform.json b/acceptance/bundle/deployment/bind/job/noop-job/out.job.terraform.json deleted file mode 100644 index 99953cf995c..00000000000 --- a/acceptance/bundle/deployment/bind/job/noop-job/out.job.terraform.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "created_time": [UNIX_TIME_MILLIS], - "creator_user_name": "[USERNAME]", - "job_id": [NUMID], - "run_as_user_name": "[USERNAME]", - "settings": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_project/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "email_notifications": {}, - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "Updated Job", - "queue": { - "enabled": true - }, - "run_as": { - "user_name": "[USERNAME]" - }, - "timeout_seconds": 0, - "webhook_notifications": {} - } -} 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 ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/deployment/bind/job/noop-job/out.test.toml +++ b/acceptance/bundle/deployment/bind/job/noop-job/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/job/noop-job/script b/acceptance/bundle/deployment/bind/job/noop-job/script index d844cea5b31..c4689cd32b1 100644 --- a/acceptance/bundle/deployment/bind/job/noop-job/script +++ b/acceptance/bundle/deployment/bind/job/noop-job/script @@ -5,4 +5,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.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI jobs get $job_id --output json > out.job.json diff --git a/acceptance/bundle/deployment/bind/job/python-job/out.job.direct.json b/acceptance/bundle/deployment/bind/job/python-job/out.job.json similarity index 100% rename from acceptance/bundle/deployment/bind/job/python-job/out.job.direct.json rename to acceptance/bundle/deployment/bind/job/python-job/out.job.json diff --git a/acceptance/bundle/deployment/bind/job/python-job/out.job.terraform.json b/acceptance/bundle/deployment/bind/job/python-job/out.job.terraform.json deleted file mode 100644 index 99953cf995c..00000000000 --- a/acceptance/bundle/deployment/bind/job/python-job/out.job.terraform.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "created_time": [UNIX_TIME_MILLIS], - "creator_user_name": "[USERNAME]", - "job_id": [NUMID], - "run_as_user_name": "[USERNAME]", - "settings": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_project/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "email_notifications": {}, - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "Updated Job", - "queue": { - "enabled": true - }, - "run_as": { - "user_name": "[USERNAME]" - }, - "timeout_seconds": 0, - "webhook_notifications": {} - } -} 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 ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/deployment/bind/job/python-job/out.test.toml +++ b/acceptance/bundle/deployment/bind/job/python-job/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/job/python-job/script b/acceptance/bundle/deployment/bind/job/python-job/script index 8120a8a5725..b827e22fd14 100644 --- a/acceptance/bundle/deployment/bind/job/python-job/script +++ b/acceptance/bundle/deployment/bind/job/python-job/script @@ -6,4 +6,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.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI jobs get $job_id --output json > out.job.json diff --git a/acceptance/bundle/deployment/bind/job/stale-state/out.bind.terraform.txt b/acceptance/bundle/deployment/bind/job/stale-state/out.bind.terraform.txt deleted file mode 100644 index 88dabf9f204..00000000000 --- a/acceptance/bundle/deployment/bind/job/stale-state/out.bind.terraform.txt +++ /dev/null @@ -1,14 +0,0 @@ - ->>> errcode [CLI] bundle deployment bind job_2 [EXTERNAL_JOB_ID] --auto-approve -Error: terraform import: exit status 1 - -Error: Resource already managed by Terraform - -Terraform is already managing a remote object for databricks_job.job_2. To -import to this address you must first remove the existing object from the -state. - - - - -Exit code: 1 diff --git a/acceptance/bundle/deployment/bind/job/stale-state/out.bind.direct.txt b/acceptance/bundle/deployment/bind/job/stale-state/out.bind.txt similarity index 100% rename from acceptance/bundle/deployment/bind/job/stale-state/out.bind.direct.txt rename to acceptance/bundle/deployment/bind/job/stale-state/out.bind.txt 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 ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/deployment/bind/job/stale-state/out.test.toml +++ b/acceptance/bundle/deployment/bind/job/stale-state/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/job/stale-state/script b/acceptance/bundle/deployment/bind/job/stale-state/script index 3aea8be1b65..a931f94d52a 100755 --- a/acceptance/bundle/deployment/bind/job/stale-state/script +++ b/acceptance/bundle/deployment/bind/job/stale-state/script @@ -1,8 +1,4 @@ -if [ "$DATABRICKS_BUNDLE_ENGINE" = "direct" ]; then - state_file=".databricks/bundle/default/resources.json" -else - state_file=".databricks/bundle/default/terraform/terraform.tfstate" -fi +state_file=".databricks/bundle/default/resources.json" title "Step 1: Deploy with job_1 only" trace $CLI bundle deploy @@ -24,4 +20,4 @@ title "Step 6: Create external job and try to bind (should fail: remote state al job_id=$($CLI jobs create --json '{"name": "External Job"}' | jq -r '.job_id') add_repl "$job_id" EXTERNAL_JOB_ID echo "External job ID: $job_id" -trace errcode $CLI bundle deployment bind job_2 $job_id --auto-approve &> out.bind.$DATABRICKS_BUNDLE_ENGINE.txt +trace errcode $CLI bundle deployment bind job_2 $job_id --auto-approve &> out.bind.txt diff --git a/acceptance/bundle/deployment/bind/job/stale-state/test.toml b/acceptance/bundle/deployment/bind/job/stale-state/test.toml index 60d45d86716..0002c563689 100644 --- a/acceptance/bundle/deployment/bind/job/stale-state/test.toml +++ b/acceptance/bundle/deployment/bind/job/stale-state/test.toml @@ -4,5 +4,3 @@ Ignore = [ "databricks_v2.yml", "stale_state.json", ] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/bundle/deployment/bind/mcp_service/out.test.toml b/acceptance/bundle/deployment/bind/mcp_service/out.test.toml index 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/deployment/bind/mcp_service/out.test.toml +++ b/acceptance/bundle/deployment/bind/mcp_service/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/mcp_service/test.toml b/acceptance/bundle/deployment/bind/mcp_service/test.toml index 61218f9b23e..025e9521ea9 100644 --- a/acceptance/bundle/deployment/bind/mcp_service/test.toml +++ b/acceptance/bundle/deployment/bind/mcp_service/test.toml @@ -1,5 +1,4 @@ # AI Gateway securables are direct-engine only. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Cloud = false 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 9b8ddfcd2bd..f68b4a89c36 100644 --- a/acceptance/bundle/deployment/bind/model-serving-endpoint/out.test.toml +++ b/acceptance/bundle/deployment/bind/model-serving-endpoint/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] 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 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/deployment/bind/model_provider_service/out.test.toml +++ b/acceptance/bundle/deployment/bind/model_provider_service/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/model_provider_service/test.toml b/acceptance/bundle/deployment/bind/model_provider_service/test.toml index 651520efa8f..7f9f253ea48 100644 --- a/acceptance/bundle/deployment/bind/model_provider_service/test.toml +++ b/acceptance/bundle/deployment/bind/model_provider_service/test.toml @@ -1,5 +1,4 @@ # AI Gateway securables are direct-engine only. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Cloud = false diff --git a/acceptance/bundle/deployment/bind/model_service/out.test.toml b/acceptance/bundle/deployment/bind/model_service/out.test.toml index 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/deployment/bind/model_service/out.test.toml +++ b/acceptance/bundle/deployment/bind/model_service/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/model_service/test.toml b/acceptance/bundle/deployment/bind/model_service/test.toml index dc03ed31a1b..72e6e74c0ba 100644 --- a/acceptance/bundle/deployment/bind/model_service/test.toml +++ b/acceptance/bundle/deployment/bind/model_service/test.toml @@ -1,5 +1,4 @@ # AI Gateway securables are direct-engine only. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Cloud = false diff --git a/acceptance/bundle/deployment/bind/pipelines/recreate/out.bind-fail.terraform.txt b/acceptance/bundle/deployment/bind/pipelines/recreate/out.bind-fail.terraform.txt deleted file mode 100644 index 4e20bfd9ece..00000000000 --- a/acceptance/bundle/deployment/bind/pipelines/recreate/out.bind-fail.terraform.txt +++ /dev/null @@ -1,63 +0,0 @@ - ->>> musterr [CLI] bundle deployment bind foo [NEW_PIPELINE_ID] -databricks_pipeline.foo: Refreshing state... [id=[NEW_PIPELINE_ID]] - -Terraform used the selected providers to generate the following execution -plan. Resource actions are indicated with the following symbols: --/+ destroy and then create replacement - -Terraform will perform the following actions: - - # databricks_pipeline.foo must be replaced --/+ resource "databricks_pipeline" "foo" { - - allow_duplicate_names = false -> null - + cause = (known after apply) - + channel = "CURRENT" - + cluster_id = (known after apply) - - continuous = false -> null - ~ creator_user_name = "[USERNAME]" -> (known after apply) - - development = false -> null - + edition = "ADVANCED" - - expected_last_modified = 0 -> null - + health = (known after apply) - ~ id = "[NEW_PIPELINE_ID]" -> (known after apply) - ~ last_modified = [UNIX_TIME_MILLIS] -> (known after apply) - ~ name = "lakeflow-pipeline-[UNIQUE_NAME]" -> "test-pipeline-[UNIQUE_NAME]" - - photon = false -> null - - root_path = "/Workspace/Users/someuser@databricks.com/lakeflow_pipeline" -> null - ~ run_as_user_name = "[USERNAME]" -> (known after apply) - - serverless = false -> null - ~ state = "IDLE" -> (known after apply) - ~ storage = "/Shared/old_storage" -> "/Shared/new_storage" # forces replacement - ~ url = "[DATABRICKS_URL]/#joblist/pipelines/[NEW_PIPELINE_ID]" -> (known after apply) - - + deployment { - + kind = "BUNDLE" - + metadata_file_path = "/Workspace/Users/[USERNAME]/.bundle/test-pipeline-recreate-[UNIQUE_NAME]/default/state/metadata.json" - } - - ~ library { - - glob { - - include = "/Workspace/Users/someuser@databricks.com/lakeflow_pipeline/transformations/**" -> null - } - + notebook { - + path = "/Workspace/Users/[USERNAME]/.bundle/test-pipeline-recreate-[UNIQUE_NAME]/default/files/nb" - } - } - - library { - - glob { - - include = "/Workspace/Users/foo@databricks.com/another/**" -> null - } - } - - - provider_config { - - workspace_id = "[NUMID]" -> null - } - } - -Plan: 1 to add, 0 to change, 1 to destroy. - - -Error: this bind operation requires user confirmation, but the current console does not support prompting. -To proceed, use --auto-approve after reviewing the plan above. - diff --git a/acceptance/bundle/deployment/bind/pipelines/recreate/out.bind-fail.direct.txt b/acceptance/bundle/deployment/bind/pipelines/recreate/out.bind-fail.txt similarity index 100% rename from acceptance/bundle/deployment/bind/pipelines/recreate/out.bind-fail.direct.txt rename to acceptance/bundle/deployment/bind/pipelines/recreate/out.bind-fail.txt diff --git a/acceptance/bundle/deployment/bind/pipelines/recreate/out.test.toml b/acceptance/bundle/deployment/bind/pipelines/recreate/out.test.toml index 9b8ddfcd2bd..f68b4a89c36 100644 --- a/acceptance/bundle/deployment/bind/pipelines/recreate/out.test.toml +++ b/acceptance/bundle/deployment/bind/pipelines/recreate/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/pipelines/recreate/script b/acceptance/bundle/deployment/bind/pipelines/recreate/script index 64489d919ff..9fd964fee14 100644 --- a/acceptance/bundle/deployment/bind/pipelines/recreate/script +++ b/acceptance/bundle/deployment/bind/pipelines/recreate/script @@ -5,7 +5,7 @@ NEW_PIPELINE_ID=$($CLI pipelines create --json @pipeline.json | jq -r .pipeline_ add_repl $NEW_PIPELINE_ID NEW_PIPELINE_ID rm -f "$OUT_REQUESTS" -trace musterr $CLI bundle deployment bind foo $NEW_PIPELINE_ID &> out.bind-fail.$DATABRICKS_BUNDLE_ENGINE.txt +trace musterr $CLI bundle deployment bind foo $NEW_PIPELINE_ID &> out.bind-fail.txt print_requests.py '^//import-file/' '^//workspace/' rm -f "$OUT_REQUESTS" diff --git a/acceptance/bundle/deployment/bind/pipelines/update/out.bind-fail.terraform.txt b/acceptance/bundle/deployment/bind/pipelines/update/out.bind-fail.terraform.txt deleted file mode 100644 index deacd3b1a20..00000000000 --- a/acceptance/bundle/deployment/bind/pipelines/update/out.bind-fail.terraform.txt +++ /dev/null @@ -1,48 +0,0 @@ - ->>> musterr [CLI] bundle deployment bind foo [NEW_PIPELINE_ID] -databricks_pipeline.foo: Refreshing state... [id=[NEW_PIPELINE_ID]] - -Terraform used the selected providers to generate the following execution -plan. Resource actions are indicated with the following symbols: - ~ update in-place - -Terraform will perform the following actions: - - # databricks_pipeline.foo will be updated in-place - ~ resource "databricks_pipeline" "foo" { - + catalog = "main" - + channel = "CURRENT" - + edition = "ADVANCED" - id = "[NEW_PIPELINE_ID]" - ~ name = "lakeflow-pipeline" -> "test-pipeline" - - root_path = "/Workspace/Users/[USERNAME]/lakeflow_pipeline" -> null - # (12 unchanged attributes hidden) - - + deployment { - + kind = "BUNDLE" - + metadata_file_path = "/Workspace/Users/[USERNAME]/.bundle/test-pipeline-recreate/default/state/metadata.json" - } - - ~ library { - - glob { - - include = "/Workspace/Users/[USERNAME]/lakeflow_pipeline/transformations/**" -> null - } - + notebook { - + path = "/Workspace/Users/[USERNAME]/.bundle/test-pipeline-recreate/default/files/nb" - } - } - - library { - - glob { - - include = "/Workspace/Users/foo@databricks.com/another/**" -> null - } - } - - # (1 unchanged block hidden) - } - -Plan: 0 to add, 1 to change, 0 to destroy. - - -Error: this bind operation requires user confirmation, but the current console does not support prompting. -To proceed, use --auto-approve after reviewing the plan above. - diff --git a/acceptance/bundle/deployment/bind/pipelines/update/out.bind-fail.direct.txt b/acceptance/bundle/deployment/bind/pipelines/update/out.bind-fail.txt similarity index 100% rename from acceptance/bundle/deployment/bind/pipelines/update/out.bind-fail.direct.txt rename to acceptance/bundle/deployment/bind/pipelines/update/out.bind-fail.txt diff --git a/acceptance/bundle/deployment/bind/pipelines/update/out.deploy.requests.direct.json b/acceptance/bundle/deployment/bind/pipelines/update/out.deploy.requests.json similarity index 100% rename from acceptance/bundle/deployment/bind/pipelines/update/out.deploy.requests.direct.json rename to acceptance/bundle/deployment/bind/pipelines/update/out.deploy.requests.json diff --git a/acceptance/bundle/deployment/bind/pipelines/update/out.deploy.requests.terraform.json b/acceptance/bundle/deployment/bind/pipelines/update/out.deploy.requests.terraform.json deleted file mode 100644 index 3c8d1946b83..00000000000 --- a/acceptance/bundle/deployment/bind/pipelines/update/out.deploy.requests.terraform.json +++ /dev/null @@ -1,37 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-pipeline-recreate/default/artifacts/.internal" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-pipeline-recreate/default/files" - } -} -{ - "method": "PUT", - "path": "/api/2.0/pipelines/[NEW_PIPELINE_ID]", - "body": { - "catalog": "main", - "channel": "CURRENT", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-pipeline-recreate/default/state/metadata.json" - }, - "edition": "ADVANCED", - "id": "[NEW_PIPELINE_ID]", - "libraries": [ - { - "notebook": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-pipeline-recreate/default/files/nb" - } - } - ], - "name": "test-pipeline", - "storage": "dbfs:/pipelines/[NEW_PIPELINE_ID]" - } -} diff --git a/acceptance/bundle/deployment/bind/pipelines/update/out.test.toml b/acceptance/bundle/deployment/bind/pipelines/update/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/deployment/bind/pipelines/update/out.test.toml +++ b/acceptance/bundle/deployment/bind/pipelines/update/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/pipelines/update/script b/acceptance/bundle/deployment/bind/pipelines/update/script index fc1590c43f7..68ed3eca1f2 100644 --- a/acceptance/bundle/deployment/bind/pipelines/update/script +++ b/acceptance/bundle/deployment/bind/pipelines/update/script @@ -2,7 +2,7 @@ NEW_PIPELINE_ID=$($CLI pipelines create --json @pipeline.json | jq -r .pipeline_ add_repl $NEW_PIPELINE_ID NEW_PIPELINE_ID rm -f "$OUT_REQUESTS" -trace musterr $CLI bundle deployment bind foo $NEW_PIPELINE_ID &> out.bind-fail.$DATABRICKS_BUNDLE_ENGINE.txt +trace musterr $CLI bundle deployment bind foo $NEW_PIPELINE_ID &> out.bind-fail.txt print_requests.py '^//import-file/' '^//workspace/delete' rm -f "$OUT_REQUESTS" @@ -14,4 +14,4 @@ trace $CLI bundle plan rm -f "$OUT_REQUESTS" trace $CLI bundle deploy --auto-approve -trace print_requests.py '^//import-file/' '^//workspace/delete' '^//telemetry-ext' > out.deploy.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py '^//import-file/' '^//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 ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/deployment/bind/postgres_database/out.test.toml +++ b/acceptance/bundle/deployment/bind/postgres_database/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/postgres_role/out.test.toml b/acceptance/bundle/deployment/bind/postgres_role/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/deployment/bind/postgres_role/out.test.toml +++ b/acceptance/bundle/deployment/bind/postgres_role/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] 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 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/deployment/bind/postgres_snapshot_schedule/out.test.toml +++ b/acceptance/bundle/deployment/bind/postgres_snapshot_schedule/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/postgres_snapshot_schedule/test.toml b/acceptance/bundle/deployment/bind/postgres_snapshot_schedule/test.toml index dc7816a8cd1..e41822d5fb9 100644 --- a/acceptance/bundle/deployment/bind/postgres_snapshot_schedule/test.toml +++ b/acceptance/bundle/deployment/bind/postgres_snapshot_schedule/test.toml @@ -3,7 +3,6 @@ Cloud = false # The snapshot schedule was added to the Postgres API in databricks-sdk-go # v0.177.0, which the pinned Terraform provider does not yet include, so there is # no databricks_..._snapshot_schedule resource. Run the direct engine only. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ ".databricks" diff --git a/acceptance/bundle/deployment/bind/quality-monitor/out.test.toml b/acceptance/bundle/deployment/bind/quality-monitor/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/deployment/bind/quality-monitor/out.test.toml +++ b/acceptance/bundle/deployment/bind/quality-monitor/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/registered-model/out.test.toml b/acceptance/bundle/deployment/bind/registered-model/out.test.toml index 9b8ddfcd2bd..f68b4a89c36 100644 --- a/acceptance/bundle/deployment/bind/registered-model/out.test.toml +++ b/acceptance/bundle/deployment/bind/registered-model/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/schema/out.test.toml b/acceptance/bundle/deployment/bind/schema/out.test.toml index 9b8ddfcd2bd..f68b4a89c36 100644 --- a/acceptance/bundle/deployment/bind/schema/out.test.toml +++ b/acceptance/bundle/deployment/bind/schema/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/secret-scope/out.test.toml b/acceptance/bundle/deployment/bind/secret-scope/out.test.toml index 9b8ddfcd2bd..f68b4a89c36 100644 --- a/acceptance/bundle/deployment/bind/secret-scope/out.test.toml +++ b/acceptance/bundle/deployment/bind/secret-scope/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/sql_warehouse/out.test.toml b/acceptance/bundle/deployment/bind/sql_warehouse/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/deployment/bind/sql_warehouse/out.test.toml +++ b/acceptance/bundle/deployment/bind/sql_warehouse/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] 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 d73c45e3119..f68b4a89c36 100644 --- a/acceptance/bundle/deployment/bind/vector_search_endpoint/out.test.toml +++ b/acceptance/bundle/deployment/bind/vector_search_endpoint/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/vector_search_endpoint/test.toml b/acceptance/bundle/deployment/bind/vector_search_endpoint/test.toml index 2c0fd37fd17..a26bade48d0 100644 --- a/acceptance/bundle/deployment/bind/vector_search_endpoint/test.toml +++ b/acceptance/bundle/deployment/bind/vector_search_endpoint/test.toml @@ -4,5 +4,3 @@ Ignore = [ ".databricks", "databricks.yml", ] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] 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 12effa8e96d..c32648754d8 100644 --- a/acceptance/bundle/deployment/bind/vector_search_index/out.test.toml +++ b/acceptance/bundle/deployment/bind/vector_search_index/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/bind/vector_search_index/test.toml b/acceptance/bundle/deployment/bind/vector_search_index/test.toml index fd516d4d0f3..2b3acff2f47 100644 --- a/acceptance/bundle/deployment/bind/vector_search_index/test.toml +++ b/acceptance/bundle/deployment/bind/vector_search_index/test.toml @@ -7,5 +7,3 @@ Ignore = [ ".databricks", "databricks.yml", ] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/deployment/bind/volume/out.test.toml b/acceptance/bundle/deployment/bind/volume/out.test.toml index 9b8ddfcd2bd..f68b4a89c36 100644 --- a/acceptance/bundle/deployment/bind/volume/out.test.toml +++ b/acceptance/bundle/deployment/bind/volume/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] 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 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/deployment/unbind/engine-from-config/out.test.toml +++ b/acceptance/bundle/deployment/unbind/engine-from-config/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/unbind/engine-from-config/test.toml b/acceptance/bundle/deployment/unbind/engine-from-config/test.toml index 501c5e1294d..5c721ad6e79 100644 --- a/acceptance/bundle/deployment/unbind/engine-from-config/test.toml +++ b/acceptance/bundle/deployment/unbind/engine-from-config/test.toml @@ -1,4 +1,2 @@ Cloud = false # test leaves deployed job Ignore = [".databricks"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/deployment/unbind/grants/out.test.toml b/acceptance/bundle/deployment/unbind/grants/out.test.toml index 9b8ddfcd2bd..f68b4a89c36 100644 --- a/acceptance/bundle/deployment/unbind/grants/out.test.toml +++ b/acceptance/bundle/deployment/unbind/grants/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/unbind/job/out.test.toml b/acceptance/bundle/deployment/unbind/job/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/deployment/unbind/job/out.test.toml +++ b/acceptance/bundle/deployment/unbind/job/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/unbind/permissions/out.test.toml b/acceptance/bundle/deployment/unbind/permissions/out.test.toml index 9b8ddfcd2bd..f68b4a89c36 100644 --- a/acceptance/bundle/deployment/unbind/permissions/out.test.toml +++ b/acceptance/bundle/deployment/unbind/permissions/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/deployment/unbind/python-job/out.test.toml b/acceptance/bundle/deployment/unbind/python-job/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/deployment/unbind/python-job/out.test.toml +++ b/acceptance/bundle/deployment/unbind/python-job/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/destroy/all-resources/out.test.toml b/acceptance/bundle/destroy/all-resources/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/destroy/all-resources/out.test.toml +++ b/acceptance/bundle/destroy/all-resources/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/destroy/force-lock-node-limit/out.test.toml b/acceptance/bundle/destroy/force-lock-node-limit/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/destroy/force-lock-node-limit/out.test.toml +++ b/acceptance/bundle/destroy/force-lock-node-limit/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/destroy/jobs-and-pipeline/out.test.toml b/acceptance/bundle/destroy/jobs-and-pipeline/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/destroy/jobs-and-pipeline/out.test.toml +++ b/acceptance/bundle/destroy/jobs-and-pipeline/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/destroy/lineage-mismatch-after-redeploy/out.test.toml b/acceptance/bundle/destroy/lineage-mismatch-after-redeploy/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/destroy/lineage-mismatch-after-redeploy/out.test.toml +++ b/acceptance/bundle/destroy/lineage-mismatch-after-redeploy/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/destroy/root-path-name-target/out.test.toml b/acceptance/bundle/destroy/root-path-name-target/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/destroy/root-path-name-target/out.test.toml +++ b/acceptance/bundle/destroy/root-path-name-target/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/destroy/root-path-not-scoped/out.test.toml b/acceptance/bundle/destroy/root-path-not-scoped/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/destroy/root-path-not-scoped/out.test.toml +++ b/acceptance/bundle/destroy/root-path-not-scoped/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/destroy/sibling-target/out.test.toml b/acceptance/bundle/destroy/sibling-target/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/destroy/sibling-target/out.test.toml +++ b/acceptance/bundle/destroy/sibling-target/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/dms/bind-unbind-unsupported/out.test.toml b/acceptance/bundle/dms/bind-unbind-unsupported/out.test.toml index 9921e91a794..88e6fbd847c 100644 --- a/acceptance/bundle/dms/bind-unbind-unsupported/out.test.toml +++ b/acceptance/bundle/dms/bind-unbind-unsupported/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/dms/declined-deploy/out.test.toml b/acceptance/bundle/dms/declined-deploy/out.test.toml index 23c07f70dca..84b22ba6735 100644 --- a/acceptance/bundle/dms/declined-deploy/out.test.toml +++ b/acceptance/bundle/dms/declined-deploy/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/dms/depends-on/out.test.toml b/acceptance/bundle/dms/depends-on/out.test.toml index 23c07f70dca..84b22ba6735 100644 --- a/acceptance/bundle/dms/depends-on/out.test.toml +++ b/acceptance/bundle/dms/depends-on/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/dms/deployment-metadata-change/out.test.toml b/acceptance/bundle/dms/deployment-metadata-change/out.test.toml index 23c07f70dca..84b22ba6735 100644 --- a/acceptance/bundle/dms/deployment-metadata-change/out.test.toml +++ b/acceptance/bundle/dms/deployment-metadata-change/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/dms/empty-grants/out.test.toml b/acceptance/bundle/dms/empty-grants/out.test.toml index 9921e91a794..88e6fbd847c 100644 --- a/acceptance/bundle/dms/empty-grants/out.test.toml +++ b/acceptance/bundle/dms/empty-grants/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/dms/existing-state/out.test.toml b/acceptance/bundle/dms/existing-state/out.test.toml index d73c45e3119..f68b4a89c36 100644 --- a/acceptance/bundle/dms/existing-state/out.test.toml +++ b/acceptance/bundle/dms/existing-state/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/dms/failed-delete/out.test.toml b/acceptance/bundle/dms/failed-delete/out.test.toml index 9921e91a794..88e6fbd847c 100644 --- a/acceptance/bundle/dms/failed-delete/out.test.toml +++ b/acceptance/bundle/dms/failed-delete/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/dms/failed-recreate/out.test.toml b/acceptance/bundle/dms/failed-recreate/out.test.toml index 9921e91a794..88e6fbd847c 100644 --- a/acceptance/bundle/dms/failed-recreate/out.test.toml +++ b/acceptance/bundle/dms/failed-recreate/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/dms/failed-update-permissions/out.test.toml b/acceptance/bundle/dms/failed-update-permissions/out.test.toml index 9921e91a794..88e6fbd847c 100644 --- a/acceptance/bundle/dms/failed-update-permissions/out.test.toml +++ b/acceptance/bundle/dms/failed-update-permissions/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/dms/multiple-resources/out.test.toml b/acceptance/bundle/dms/multiple-resources/out.test.toml index 23c07f70dca..84b22ba6735 100644 --- a/acceptance/bundle/dms/multiple-resources/out.test.toml +++ b/acceptance/bundle/dms/multiple-resources/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/dms/no-drift/out.test.toml b/acceptance/bundle/dms/no-drift/out.test.toml index 23c07f70dca..84b22ba6735 100644 --- a/acceptance/bundle/dms/no-drift/out.test.toml +++ b/acceptance/bundle/dms/no-drift/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/dms/no-resources/out.test.toml b/acceptance/bundle/dms/no-resources/out.test.toml index 23c07f70dca..84b22ba6735 100644 --- a/acceptance/bundle/dms/no-resources/out.test.toml +++ b/acceptance/bundle/dms/no-resources/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/dms/operation-upload-fails-once/out.test.toml b/acceptance/bundle/dms/operation-upload-fails-once/out.test.toml index 9921e91a794..88e6fbd847c 100644 --- a/acceptance/bundle/dms/operation-upload-fails-once/out.test.toml +++ b/acceptance/bundle/dms/operation-upload-fails-once/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/dms/plan-without-dms/out.test.toml b/acceptance/bundle/dms/plan-without-dms/out.test.toml index 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/dms/plan-without-dms/out.test.toml +++ b/acceptance/bundle/dms/plan-without-dms/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/dms/provenance/out.test.toml b/acceptance/bundle/dms/provenance/out.test.toml index 23c07f70dca..84b22ba6735 100644 --- a/acceptance/bundle/dms/provenance/out.test.toml +++ b/acceptance/bundle/dms/provenance/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/dms/record-failure/out.test.toml b/acceptance/bundle/dms/record-failure/out.test.toml index 23c07f70dca..84b22ba6735 100644 --- a/acceptance/bundle/dms/record-failure/out.test.toml +++ b/acceptance/bundle/dms/record-failure/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/dms/stale-plan/out.test.toml b/acceptance/bundle/dms/stale-plan/out.test.toml index f7ae4fc905f..ef2679cdd20 100644 --- a/acceptance/bundle/dms/stale-plan/out.test.toml +++ b/acceptance/bundle/dms/stale-plan/out.test.toml @@ -1,4 +1,3 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/dms/state-features/out.test.toml b/acceptance/bundle/dms/state-features/out.test.toml index 23c07f70dca..84b22ba6735 100644 --- a/acceptance/bundle/dms/state-features/out.test.toml +++ b/acceptance/bundle/dms/state-features/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/dms/successful-recreate/out.test.toml b/acceptance/bundle/dms/successful-recreate/out.test.toml index 23c07f70dca..84b22ba6735 100644 --- a/acceptance/bundle/dms/successful-recreate/out.test.toml +++ b/acceptance/bundle/dms/successful-recreate/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/dms/test.toml b/acceptance/bundle/dms/test.toml index 940d5bf58ad..99a9a653781 100644 --- a/acceptance/bundle/dms/test.toml +++ b/acceptance/bundle/dms/test.toml @@ -2,7 +2,6 @@ Cloud = true # Deployment Metadata Service (DMS) recording is only supported by the direct # engine; it is a no-op on terraform. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] RecordRequests = true diff --git a/acceptance/bundle/dms/version-never-created/out.test.toml b/acceptance/bundle/dms/version-never-created/out.test.toml index 9921e91a794..88e6fbd847c 100644 --- a/acceptance/bundle/dms/version-never-created/out.test.toml +++ b/acceptance/bundle/dms/version-never-created/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/empty_string_dropped/app/app.py b/acceptance/bundle/empty_string_dropped/app/app.py deleted file mode 100644 index ad1e64f9fb0..00000000000 --- a/acceptance/bundle/empty_string_dropped/app/app.py +++ /dev/null @@ -1,5 +0,0 @@ -import http.server, os - -http.server.HTTPServer( - ("", int(os.environ["DATABRICKS_APP_PORT"])), http.server.SimpleHTTPRequestHandler -).serve_forever() diff --git a/acceptance/bundle/empty_string_dropped/base.yml b/acceptance/bundle/empty_string_dropped/base.yml deleted file mode 100644 index 16c893adb0b..00000000000 --- a/acceptance/bundle/empty_string_dropped/base.yml +++ /dev/null @@ -1,101 +0,0 @@ -bundle: - name: test-bundle - -# Deployable skeleton per resource. gen_empty_config.py fills every settable -# string leaf under the blocks present here with "" and records it. Coverage is -# scoped to the blocks below: we include one side of each mutually-exclusive -# choice (aws_attributes not gcp, s3 log conf not dbfs/volumes, git_source -# present) because including both would make terraform abort. Only resources that -# deploy on BOTH engines belong here. -# -# Fields set to a real value here are treated as required/meaningful and left -# alone; everything else settable-and-string is emptied. -resources: - apps: - my_app: - # App names are globally unique in the workspace; the two targets deploy to - # the same fake workspace, so scope the name per target to avoid a 409. - name: test-app-${bundle.target} - source_code_path: ./app - - clusters: - my_cluster: - num_workers: 1 - # spark_version is tagged omitempty in the SDK but required by terraform's - # schema and the backend, so it must have a real value or the deploy fails. - spark_version: 13.3.x-scala2.12 - aws_attributes: - availability: SPOT - cluster_log_conf: - s3: - destination: s3://test-bucket/logs - - jobs: - my_job: - max_concurrent_runs: 1 - git_source: - git_url: https://example.com/repo - git_provider: gitHub - git_branch: main - job_clusters: - - job_cluster_key: main - new_cluster: - num_workers: 1 - spark_version: 13.3.x-scala2.12 - aws_attributes: - availability: SPOT - cluster_log_conf: - s3: - destination: s3://test-bucket/logs - - pipelines: - my_pipeline: - libraries: - - file: - path: pipeline.py - clusters: - - label: default - aws_attributes: - availability: SPOT - - sql_warehouses: - my_warehouse: - name: test-warehouse - cluster_size: 2X-Small - auto_stop_mins: 10 - max_num_clusters: 1 - min_num_clusters: 1 - - models: - my_model: - name: test-model - - experiments: - my_experiment: - name: /Users/${workspace.current_user.userName}/test-experiment - - registered_models: - my_registered_model: - name: test-registered-model - catalog_name: main - schema_name: default - - schemas: - my_schema: - catalog_name: main - name: test-schema - - volumes: - my_volume: - name: test-volume - catalog_name: main - schema_name: default - - database_instances: - my_db_instance: - name: test-db-instance - capacity: CU_1 - -targets: - tf: - direct: diff --git a/acceptance/bundle/empty_string_dropped/databricks.yml b/acceptance/bundle/empty_string_dropped/databricks.yml deleted file mode 100644 index 80ff85d9762..00000000000 --- a/acceptance/bundle/empty_string_dropped/databricks.yml +++ /dev/null @@ -1,138 +0,0 @@ -# Generated by gen_empty_config.py. Do not edit; edit base.yml and regenerate. -bundle: - name: test-bundle -resources: - apps: - my_app: - budget_policy_id: '' - description: '' - name: test-app-${bundle.target} - source_code_path: ./app - space: '' - usage_policy_id: '' - clusters: - my_cluster: - aws_attributes: - availability: SPOT - instance_profile_arn: '' - zone_id: '' - cluster_log_conf: - s3: - canned_acl: '' - destination: s3://test-bucket/logs - encryption_type: '' - endpoint: '' - kms_key: '' - region: '' - cluster_name: '' - node_type_id: '' - num_workers: 1 - policy_id: '' - single_user_name: '' - spark_version: 13.3.x-scala2.12 - database_instances: - my_db_instance: - capacity: CU_1 - name: test-db-instance - usage_policy_id: '' - experiments: - my_experiment: - artifact_location: '' - name: /Users/${workspace.current_user.userName}/test-experiment - jobs: - my_job: - budget_policy_id: '' - description: '' - git_source: - git_branch: main - git_provider: gitHub - git_url: https://example.com/repo - job_clusters: - - job_cluster_key: main - new_cluster: - aws_attributes: - availability: SPOT - instance_profile_arn: '' - zone_id: '' - cluster_log_conf: - s3: - canned_acl: '' - destination: s3://test-bucket/logs - encryption_type: '' - endpoint: '' - kms_key: '' - region: '' - cluster_name: '' - node_type_id: '' - num_workers: 1 - policy_id: '' - single_user_name: '' - spark_version: 13.3.x-scala2.12 - max_concurrent_runs: 1 - name: '' - parent_path: '' - usage_policy_id: '' - models: - my_model: - description: '' - name: test-model - pipelines: - my_pipeline: - budget_policy_id: '' - clusters: - - aws_attributes: - availability: SPOT - instance_profile_arn: '' - zone_id: '' - driver_instance_pool_id: '' - driver_node_type_id: '' - instance_pool_id: '' - label: default - node_type_id: '' - policy_id: '' - libraries: - - file: - path: pipeline.py - jar: '' - whl: '' - name: '' - root_path: '' - serverless_compute_id: '' - usage_policy_id: '' - registered_models: - my_registered_model: - catalog_name: main - comment: '' - created_by: '' - full_name: '' - metastore_id: '' - name: test-registered-model - owner: '' - schema_name: default - storage_location: '' - updated_by: '' - schemas: - my_schema: - catalog_name: main - comment: '' - name: test-schema - storage_root: '' - sql_warehouses: - my_warehouse: - auto_stop_mins: 10 - cluster_size: 2X-Small - instance_profile_arn: '' - max_num_clusters: 1 - min_num_clusters: 1 - name: test-warehouse - volumes: - my_volume: - catalog_name: main - comment: '' - name: test-volume - schema_name: default - storage_location: '' - volume_path: '' -targets: - direct: null - tf: null diff --git a/acceptance/bundle/empty_string_dropped/empty_sent.py b/acceptance/bundle/empty_string_dropped/empty_sent.py deleted file mode 100755 index 0a8f74a698b..00000000000 --- a/acceptance/bundle/empty_string_dropped/empty_sent.py +++ /dev/null @@ -1,166 +0,0 @@ -#!/usr/bin/env python3 -"""Classify empty-string handling by diffing terraform vs direct create requests. - -Both engines deploy the same config, so their create requests have the same -shape. From the request logs we collect, per engine, the body fields sent with an -empty-string value; comparing the two sets splits three ways: - - out.empty_sent_by_terraform_only.txt sent "" by terraform, not by direct - out.empty_sent_by_direct_only.txt sent "" by direct, not by terraform - out.empty_sent_by_both.txt sent "" by both - -The fourth bucket -- fields set to "" in config that BOTH engines dropped -- is -not visible in the request logs (they're absent from both bodies), so it is -recovered from databricks.yml: - - out.empty_dropped_by_both.txt set "" in config, sent by neither - -Terraform drops empty optional strings via omitempty (SDKv2 resources), so today -direct_only lists the gap; both/terraform_only capture the exceptions (a required -field with no omitempty, or a plugin-framework resource that serializes ""). -""" - -import json -from pathlib import Path - -# Substring uniquely identifying each resource type's create-request path, used -# to attribute a config field to the request it should appear in. -CREATE_PATHS = { - "apps": "/apps", - "clusters": "clusters/create", - "jobs": "jobs/create", - "pipelines": "/pipelines", - "sql_warehouses": "/warehouses", - "models": "/mlflow/registered-models", - "experiments": "/experiments/create", - "registered_models": "/unity-catalog/models", - "schemas": "/unity-catalog/schemas", - "volumes": "/unity-catalog/volumes", - "database_instances": "/database/instances", -} - - -def read_json_many(text): - """Decode concatenated JSON objects (the out.requests..json format).""" - decoder = json.JSONDecoder() - objects = [] - pos = 0 - while pos < len(text): - while pos < len(text) and text[pos].isspace(): - pos += 1 - if pos >= len(text): - break - obj, pos = decoder.raw_decode(text, pos) - objects.append(obj) - return objects - - -def empty_field_paths(obj, prefix): - """Yield dotted field paths whose value is an empty string.""" - if isinstance(obj, dict): - for key, value in obj.items(): - child = f"{prefix}.{key}" if prefix else key - if value == "": - yield child - else: - yield from empty_field_paths(value, child) - elif isinstance(obj, list): - for item in obj: - yield from empty_field_paths(item, prefix) - - -def empty_sent(engine): - """Return {" "} for body fields sent with value "".""" - out = set() - for req in read_json_many(Path(f"out.requests.{engine}.json").read_text()): - for field in empty_field_paths(req.get("body", {}), ""): - out.add(f"{req.get('path', '')} {field}") - return out - - -def config_empty_fields(): - """Return {" "} for every "" leaf in databricks.yml. - - Uses a minimal indentation parser (the harness python is stdlib-only, no - PyYAML). databricks.yml is generator output with a fixed 2-space style, block - mappings, and "- " list items -- not arbitrary YAML. - """ - out = set() - # stack of (indent, key) for the current mapping path within a resource - stack = [] - for raw in Path("databricks.yml").read_text().splitlines(): - if not raw.strip() or raw.lstrip().startswith("#"): - continue - indent = len(raw) - len(raw.lstrip(" ")) - line = raw.strip() - # A "- " list item shares its parent's field path; treat the inline - # "key: value" after it at the item indent. - if line.startswith("- "): - line = line[2:] - indent += 2 - if ":" not in line: - continue - key, _, value = line.partition(":") - key, value = key.strip(), value.strip() - while stack and stack[-1][0] >= indent: - stack.pop() - path = [k for _, k in stack] + [key] - # resources...: the create path is fixed by rtype. - if len(path) >= 2 and path[0] == "resources" and path[1] in CREATE_PATHS: - if value in ("''", '""'): - field = ".".join(path[3:]) # drop resources.. - out.add(f"{CREATE_PATHS[path[1]]} {field}") - if not value: - stack.append((indent, key)) - return out - - -def sent_fields(*engines): - """Return {" "} for ALL body fields (any value) sent.""" - out = set() - for engine in engines: - for req in read_json_many(Path(f"out.requests.{engine}.json").read_text()): - for field in all_field_paths(req.get("body", {}), ""): - out.add(f"{req.get('path', '')} {field}") - return out - - -def all_field_paths(obj, prefix): - """Yield every dotted field path present in a body, regardless of value.""" - if isinstance(obj, dict): - for key, value in obj.items(): - child = f"{prefix}.{key}" if prefix else key - yield child - yield from all_field_paths(value, child) - elif isinstance(obj, list): - for item in obj: - yield from all_field_paths(item, prefix) - - -def sent_somewhere(entry, sent): - """True if entry (create-path substring + field) matches any sent full-path entry.""" - create_path, field = entry.split(" ", 1) - return any(create_path in path and field == f for path, f in (s.split(" ", 1) for s in sent)) - - -def main(): - tf = empty_sent("terraform") - direct = empty_sent("direct") - - _write("out.empty_sent_by_terraform_only.txt", tf - direct) - _write("out.empty_sent_by_direct_only.txt", direct - tf) - _write("out.empty_sent_by_both.txt", tf & direct) - - # Dropped by both: set to "" in config but present in neither request body - # (present with any value = not dropped, so match on field presence). - present = sent_fields("terraform", "direct") - dropped_by_both = {e for e in config_empty_fields() if not sent_somewhere(e, present)} - _write("out.empty_dropped_by_both.txt", dropped_by_both) - - -def _write(name, entries): - Path(name).write_text("".join(entry + "\n" for entry in sorted(entries))) - - -if __name__ == "__main__": - main() diff --git a/acceptance/bundle/empty_string_dropped/gen_empty_config.py b/acceptance/bundle/empty_string_dropped/gen_empty_config.py deleted file mode 100644 index e2e2cf79d38..00000000000 --- a/acceptance/bundle/empty_string_dropped/gen_empty_config.py +++ /dev/null @@ -1,129 +0,0 @@ -#!/usr/bin/env python3 -"""Generate databricks.yml with every settable string field set to "". - -base.yml defines a deployable skeleton per resource, including whichever nested -blocks we want to cover (job_clusters[*].new_cluster, git_source, one cloud -attributes block, ...). This script walks every resource subtree and sets every -settable string LEAF (including nested ones) that the base doesn't already set -to "". Coverage is therefore scoped to the blocks present in base.yml, which is -how we avoid mutually-exclusive blocks (aws vs gcp attributes, git_source vs -none) that would make terraform abort. - -A field is settable/eligible when out.fields.txt types it as `string` (this -skips enums, which are named types) with flag ALL or INPUT, and it is not -output_only (.generated.yml), a bundle-framework field, or a -known terraform-erroring field. - -Run from the repo root; writes databricks.yml in the test directory: - acceptance/bundle/empty_string_dropped/gen_empty_config.py -""" - -import re -from pathlib import Path - -import yaml - -FIELDS = Path("acceptance/bundle/refschema/out.fields.txt") -CONFIGS = Path("bundle/direct/dresources/configs") -GENERATED_SUFFIX = ".generated.yml" -TESTDIR = Path("acceptance/bundle/empty_string_dropped") -BASE = TESTDIR / "base.yml" - -# Bundle-framework fields present on every resource; not real API inputs. -FRAMEWORK_FIELDS = {"id", "url", "modified_status"} - -# Leaf field names that make terraform error at plan time (ConflictsWith, enum -# validation on string-typed fields, computed attributes), so no request is -# recorded. Applied per resource type. Matched by leaf name at any depth. -TERRAFORM_ERRORS = { - "clusters": {"instance_pool_id", "driver_instance_pool_id", "driver_node_type_id"}, - "jobs": { - "instance_pool_id", - "driver_instance_pool_id", - "driver_node_type_id", - # git_source: branch/commit/tag are mutually exclusive; base sets branch. - "git_commit", - "git_tag", - }, - "pipelines": {"channel", "edition", "catalog", "storage", "schema", "target"}, - "sql_warehouses": {"creator_name"}, -} - - -def string_leaf_parents(): - """Map resource type -> {parent_schema_path: {leaf field names}}. - - Schema paths mirror out.fields.txt: dotted segments, list elements marked - with "[*]" (e.g. "job_clusters[*].new_cluster"). Only string leaves that are - real object fields are kept: names ending in "[*]" (string-array elements) or - "*" (map values) are skipped. - """ - pat = re.compile(r"^resources\.([a-z_]+)\.\*\.(.+)$") - result = {} - for line in FIELDS.read_text().splitlines(): - parts = line.split("\t") - if len(parts) < 3: - continue - path, typ, flag = parts[0], parts[1], parts[2] - if typ != "string" or flag not in ("ALL", "INPUT"): - continue - m = pat.match(path) - if not m: - continue - rtype, rel = m.group(1), m.group(2) - if rel.endswith(("[*]", ".*")) or rel == "*": - continue - parent, _, leaf = rel.rpartition(".") - result.setdefault(rtype, {}).setdefault(parent, set()).add(leaf) - return result - - -def output_only_fields(): - """Map resource type -> {output_only field paths} (user cannot set).""" - result = {} - for path in sorted(CONFIGS.glob("*" + GENERATED_SUFFIX)): - spec = yaml.safe_load(path.read_text()) or {} - fields = set() - for entry in spec.get("ignore_remote_changes") or []: - if str(entry.get("reason", "")).startswith("spec:output_only"): - fields.add(entry["field"]) - result[path.name.removesuffix(GENERATED_SUFFIX)] = fields - return result - - -def fill(node, schema_path, parents, excluded): - """Recursively set settable string leaves under node to ""; recurse into blocks. - - schema_path uses out.fields.txt syntax (list elements marked "[*]") to look up - eligible leaves for the current object. - """ - if isinstance(node, dict): - for leaf in parents.get(schema_path, set()): - if leaf not in node and leaf not in excluded: - node[leaf] = "" - for key, value in list(node.items()): - child = f"{schema_path}.{key}" if schema_path else key - fill(value, child, parents, excluded) - elif isinstance(node, list): - for item in node: - fill(item, schema_path + "[*]", parents, excluded) - - -def main(): - parents = string_leaf_parents() - output_only = output_only_fields() - base = yaml.safe_load(BASE.read_text()) - - for rtype, entries in sorted(base.get("resources", {}).items()): - excluded = output_only.get(rtype, set()) | FRAMEWORK_FIELDS | TERRAFORM_ERRORS.get(rtype, set()) - for cfg in entries.values(): - fill(cfg, "", parents.get(rtype, {}), excluded) - - (TESTDIR / "databricks.yml").write_text( - "# Generated by gen_empty_config.py. Do not edit; edit base.yml and regenerate.\n" - + yaml.dump(base, sort_keys=True, default_flow_style=False) - ) - - -if __name__ == "__main__": - main() diff --git a/acceptance/bundle/empty_string_dropped/out.empty_dropped_by_both.txt b/acceptance/bundle/empty_string_dropped/out.empty_dropped_by_both.txt deleted file mode 100644 index 1e5d5eb2a6b..00000000000 --- a/acceptance/bundle/empty_string_dropped/out.empty_dropped_by_both.txt +++ /dev/null @@ -1,58 +0,0 @@ -/apps budget_policy_id -/apps space -/apps usage_policy_id -/database/instances usage_policy_id -/experiments/create artifact_location -/mlflow/registered-models description -/pipelines budget_policy_id -/pipelines clusters.aws_attributes.instance_profile_arn -/pipelines clusters.aws_attributes.zone_id -/pipelines clusters.driver_instance_pool_id -/pipelines clusters.driver_node_type_id -/pipelines clusters.instance_pool_id -/pipelines clusters.node_type_id -/pipelines clusters.policy_id -/pipelines libraries.jar -/pipelines libraries.whl -/pipelines name -/pipelines serverless_compute_id -/pipelines usage_policy_id -/unity-catalog/models comment -/unity-catalog/models created_by -/unity-catalog/models full_name -/unity-catalog/models metastore_id -/unity-catalog/models owner -/unity-catalog/models storage_location -/unity-catalog/models updated_by -/unity-catalog/schemas comment -/unity-catalog/schemas storage_root -/unity-catalog/volumes comment -/unity-catalog/volumes storage_location -/unity-catalog/volumes volume_path -/warehouses instance_profile_arn -clusters/create aws_attributes.instance_profile_arn -clusters/create aws_attributes.zone_id -clusters/create cluster_log_conf.s3.canned_acl -clusters/create cluster_log_conf.s3.encryption_type -clusters/create cluster_log_conf.s3.endpoint -clusters/create cluster_log_conf.s3.kms_key -clusters/create cluster_log_conf.s3.region -clusters/create cluster_name -clusters/create node_type_id -clusters/create policy_id -clusters/create single_user_name -jobs/create budget_policy_id -jobs/create description -jobs/create job_clusters.new_cluster.aws_attributes.instance_profile_arn -jobs/create job_clusters.new_cluster.aws_attributes.zone_id -jobs/create job_clusters.new_cluster.cluster_log_conf.s3.canned_acl -jobs/create job_clusters.new_cluster.cluster_log_conf.s3.encryption_type -jobs/create job_clusters.new_cluster.cluster_log_conf.s3.endpoint -jobs/create job_clusters.new_cluster.cluster_log_conf.s3.kms_key -jobs/create job_clusters.new_cluster.cluster_log_conf.s3.region -jobs/create job_clusters.new_cluster.cluster_name -jobs/create job_clusters.new_cluster.node_type_id -jobs/create job_clusters.new_cluster.policy_id -jobs/create job_clusters.new_cluster.single_user_name -jobs/create parent_path -jobs/create usage_policy_id diff --git a/acceptance/bundle/empty_string_dropped/out.empty_sent_by_both.txt b/acceptance/bundle/empty_string_dropped/out.empty_sent_by_both.txt deleted file mode 100644 index ea9330c71cd..00000000000 --- a/acceptance/bundle/empty_string_dropped/out.empty_sent_by_both.txt +++ /dev/null @@ -1 +0,0 @@ -/api/2.0/apps description diff --git a/acceptance/bundle/empty_string_dropped/out.requests.direct.json b/acceptance/bundle/empty_string_dropped/out.requests.direct.json deleted file mode 100644 index c9bba29b9fa..00000000000 --- a/acceptance/bundle/empty_string_dropped/out.requests.direct.json +++ /dev/null @@ -1,156 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/apps", - "q": { - "no_compute": "true" - }, - "body": { - "description": "", - "name": "test-app-direct" - } -} -{ - "method": "POST", - "path": "/api/2.0/database/instances", - "body": { - "capacity": "CU_1", - "name": "test-db-instance" - } -} -{ - "method": "POST", - "path": "/api/2.0/mlflow/experiments/create", - "body": { - "name": "/Users/[USERNAME]/test-experiment" - } -} -{ - "method": "POST", - "path": "/api/2.0/mlflow/registered-models/create", - "body": { - "name": "test-model" - } -} -{ - "method": "POST", - "path": "/api/2.0/pipelines", - "body": { - "channel": "CURRENT", - "clusters": [ - { - "aws_attributes": { - "availability": "SPOT" - }, - "label": "default" - } - ], - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/direct/state/metadata.json" - }, - "edition": "ADVANCED", - "libraries": [ - { - "file": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/direct/files/pipeline.py" - } - } - ], - "root_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/direct/files" - } -} -{ - "method": "POST", - "path": "/api/2.0/sql/warehouses", - "body": { - "auto_stop_mins": 10, - "cluster_size": "2X-Small", - "enable_photon": true, - "max_num_clusters": 1, - "min_num_clusters": 1, - "name": "test-warehouse", - "spot_instance_policy": "COST_OPTIMIZED" - } -} -{ - "method": "POST", - "path": "/api/2.1/clusters/create", - "body": { - "autotermination_minutes": 60, - "aws_attributes": { - "availability": "SPOT" - }, - "cluster_log_conf": { - "s3": { - "destination": "s3://test-bucket/logs" - } - }, - "num_workers": 1, - "spark_version": "13.3.x-scala2.12" - } -} -{ - "method": "POST", - "path": "/api/2.1/unity-catalog/models", - "body": { - "catalog_name": "main", - "name": "test-registered-model", - "schema_name": "default" - } -} -{ - "method": "POST", - "path": "/api/2.1/unity-catalog/schemas", - "body": { - "catalog_name": "main", - "name": "test-schema" - } -} -{ - "method": "POST", - "path": "/api/2.1/unity-catalog/volumes", - "body": { - "catalog_name": "main", - "name": "test-volume", - "schema_name": "default", - "volume_type": "MANAGED" - } -} -{ - "method": "POST", - "path": "/api/2.2/jobs/create", - "body": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/direct/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "git_source": { - "git_branch": "main", - "git_provider": "gitHub", - "git_url": "https://example.com/repo" - }, - "job_clusters": [ - { - "job_cluster_key": "main", - "new_cluster": { - "aws_attributes": { - "availability": "SPOT" - }, - "cluster_log_conf": { - "s3": { - "destination": "s3://test-bucket/logs" - } - }, - "num_workers": 1, - "spark_version": "13.3.x-scala2.12" - } - } - ], - "max_concurrent_runs": 1, - "queue": { - "enabled": true - } - } -} diff --git a/acceptance/bundle/empty_string_dropped/out.requests.terraform.json b/acceptance/bundle/empty_string_dropped/out.requests.terraform.json deleted file mode 100644 index b2e9c328cd2..00000000000 --- a/acceptance/bundle/empty_string_dropped/out.requests.terraform.json +++ /dev/null @@ -1,157 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/apps", - "q": { - "no_compute": "true" - }, - "body": { - "description": "", - "name": "test-app-tf" - } -} -{ - "method": "POST", - "path": "/api/2.0/database/instances", - "body": { - "capacity": "CU_1", - "name": "test-db-instance" - } -} -{ - "method": "POST", - "path": "/api/2.0/mlflow/experiments/create", - "body": { - "name": "/Users/[USERNAME]/test-experiment" - } -} -{ - "method": "POST", - "path": "/api/2.0/mlflow/registered-models/create", - "body": { - "name": "test-model" - } -} -{ - "method": "POST", - "path": "/api/2.0/pipelines", - "body": { - "channel": "CURRENT", - "clusters": [ - { - "aws_attributes": { - "availability": "SPOT" - }, - "label": "default" - } - ], - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/tf/state/metadata.json" - }, - "edition": "ADVANCED", - "libraries": [ - { - "file": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/tf/files/pipeline.py" - } - } - ], - "root_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/tf/files" - } -} -{ - "method": "POST", - "path": "/api/2.0/sql/warehouses", - "body": { - "auto_stop_mins": 10, - "cluster_size": "2X-Small", - "enable_photon": true, - "max_num_clusters": 1, - "min_num_clusters": 1, - "name": "test-warehouse", - "spot_instance_policy": "COST_OPTIMIZED" - } -} -{ - "method": "POST", - "path": "/api/2.1/clusters/create", - "body": { - "autotermination_minutes": 60, - "aws_attributes": { - "availability": "SPOT" - }, - "cluster_log_conf": { - "s3": { - "destination": "s3://test-bucket/logs" - } - }, - "num_workers": 1, - "spark_version": "13.3.x-scala2.12" - } -} -{ - "method": "POST", - "path": "/api/2.1/unity-catalog/models", - "body": { - "catalog_name": "main", - "name": "test-registered-model", - "schema_name": "default" - } -} -{ - "method": "POST", - "path": "/api/2.1/unity-catalog/schemas", - "body": { - "catalog_name": "main", - "name": "test-schema" - } -} -{ - "method": "POST", - "path": "/api/2.1/unity-catalog/volumes", - "body": { - "catalog_name": "main", - "name": "test-volume", - "schema_name": "default", - "volume_type": "MANAGED" - } -} -{ - "method": "POST", - "path": "/api/2.2/jobs/create", - "body": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/tf/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "git_source": { - "git_branch": "main", - "git_provider": "gitHub", - "git_url": "https://example.com/repo" - }, - "job_clusters": [ - { - "job_cluster_key": "main", - "new_cluster": { - "aws_attributes": { - "availability": "SPOT" - }, - "cluster_log_conf": { - "s3": { - "destination": "s3://test-bucket/logs" - } - }, - "num_workers": 1, - "spark_version": "13.3.x-scala2.12" - } - } - ], - "max_concurrent_runs": 1, - "name": "Untitled", - "queue": { - "enabled": true - } - } -} diff --git a/acceptance/bundle/empty_string_dropped/out.test.toml b/acceptance/bundle/empty_string_dropped/out.test.toml deleted file mode 100644 index 59b56a2037c..00000000000 --- a/acceptance/bundle/empty_string_dropped/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/empty_string_dropped/out.validate.json b/acceptance/bundle/empty_string_dropped/out.validate.json deleted file mode 100644 index e627b2a428f..00000000000 --- a/acceptance/bundle/empty_string_dropped/out.validate.json +++ /dev/null @@ -1,135 +0,0 @@ -{ - "apps": { - "my_app": { - "description": "", - "name": "test-app-direct", - "source_code_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/direct/files/app" - } - }, - "clusters": { - "my_cluster": { - "autotermination_minutes": 60, - "aws_attributes": { - "availability": "SPOT" - }, - "cluster_log_conf": { - "s3": { - "destination": "s3://test-bucket/logs" - } - }, - "num_workers": 1, - "spark_version": "13.3.x-scala2.12" - } - }, - "database_instances": { - "my_db_instance": { - "capacity": "CU_1", - "name": "test-db-instance" - } - }, - "experiments": { - "my_experiment": { - "name": "/Users/[USERNAME]/test-experiment" - } - }, - "jobs": { - "my_job": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/direct/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "git_source": { - "git_branch": "main", - "git_provider": "gitHub", - "git_url": "https://example.com/repo" - }, - "job_clusters": [ - { - "job_cluster_key": "main", - "new_cluster": { - "aws_attributes": { - "availability": "SPOT" - }, - "cluster_log_conf": { - "s3": { - "destination": "s3://test-bucket/logs" - } - }, - "num_workers": 1, - "spark_version": "13.3.x-scala2.12" - } - } - ], - "max_concurrent_runs": 1, - "queue": { - "enabled": true - } - } - }, - "models": { - "my_model": { - "name": "test-model" - } - }, - "pipelines": { - "my_pipeline": { - "channel": "CURRENT", - "clusters": [ - { - "aws_attributes": { - "availability": "SPOT" - }, - "label": "default" - } - ], - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/direct/state/metadata.json" - }, - "edition": "ADVANCED", - "libraries": [ - { - "file": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/direct/files/pipeline.py" - } - } - ], - "root_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/direct/files" - } - }, - "registered_models": { - "my_registered_model": { - "catalog_name": "main", - "name": "test-registered-model", - "schema_name": "default" - } - }, - "schemas": { - "my_schema": { - "catalog_name": "main", - "name": "test-schema" - } - }, - "sql_warehouses": { - "my_warehouse": { - "auto_stop_mins": 10, - "cluster_size": "2X-Small", - "enable_photon": true, - "max_num_clusters": 1, - "min_num_clusters": 1, - "name": "test-warehouse", - "spot_instance_policy": "COST_OPTIMIZED" - } - }, - "volumes": { - "my_volume": { - "catalog_name": "main", - "name": "test-volume", - "schema_name": "default", - "volume_path": "/Volumes/main/default/test-volume", - "volume_type": "MANAGED" - } - } -} diff --git a/acceptance/bundle/empty_string_dropped/output.txt b/acceptance/bundle/empty_string_dropped/output.txt deleted file mode 100644 index 95f915214f4..00000000000 --- a/acceptance/bundle/empty_string_dropped/output.txt +++ /dev/null @@ -1,32 +0,0 @@ - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -t tf -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/tf/files... -Created apps.my_app -Created clusters.my_cluster -Created database_instances.my_db_instance -Created experiments.my_experiment -Created jobs.my_job -Created models.my_model -Created pipelines.my_pipeline -Created registered_models.my_registered_model -Created schemas.my_schema -Created sql_warehouses.my_warehouse -Created volumes.my_volume -Files: 9 uploaded, 0 deleted -Resources: 11 created, 0 changed, 0 deleted, 0 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle deploy -t direct -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/direct/files... -Created apps.my_app -Created clusters.my_cluster -Created database_instances.my_db_instance -Created experiments.my_experiment -Created jobs.my_job -Created models.my_model -Created pipelines.my_pipeline -Created registered_models.my_registered_model -Created schemas.my_schema -Created sql_warehouses.my_warehouse -Created volumes.my_volume -Files: 10 uploaded, 0 deleted -Resources: 11 created, 0 changed, 0 deleted, 0 unchanged diff --git a/acceptance/bundle/empty_string_dropped/pipeline.py b/acceptance/bundle/empty_string_dropped/pipeline.py deleted file mode 100644 index e1b4968c112..00000000000 --- a/acceptance/bundle/empty_string_dropped/pipeline.py +++ /dev/null @@ -1,6 +0,0 @@ -import dlt - - -@dlt.table -def my_table(): - return spark.range(1) diff --git a/acceptance/bundle/empty_string_dropped/script b/acceptance/bundle/empty_string_dropped/script deleted file mode 100644 index a03c479c071..00000000000 --- a/acceptance/bundle/empty_string_dropped/script +++ /dev/null @@ -1,21 +0,0 @@ -# databricks.yml is committed, generated by gen_empty_config.py with every -# settable string field set to "". Deploy through each engine (separate target => -# separate state), record create requests, and empty_sent.py classifies which -# "" fields each engine sends. -# -# Baseline: terraform drops "" via omitempty, direct sends it. As direct handling -# changes, out.empty_sent_by_direct_only.txt (the gap) shrinks. - -# Resolved config the engines see. Today every "" field is still present here; a -# fix in the initialize phase would drop them, and this golden would show that. -$CLI bundle validate -o json -t direct | nostamp | jq .resources > out.validate.json - -# Exclude non-create traffic: workspace file ops, telemetry (nondeterministic), and the -# deployment history calls the DMS run adds. -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -t tf -print_requests.py --nostamp ^//api/2.0/workspace ^//telemetry ^//api/2.0/bundle --sort > out.requests.terraform.json - -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle deploy -t direct -print_requests.py --nostamp ^//api/2.0/workspace ^//telemetry ^//api/2.0/bundle --sort > out.requests.direct.json - -$TESTDIR/empty_sent.py diff --git a/acceptance/bundle/empty_string_dropped/test.toml b/acceptance/bundle/empty_string_dropped/test.toml deleted file mode 100644 index 1a82f9b843a..00000000000 --- a/acceptance/bundle/empty_string_dropped/test.toml +++ /dev/null @@ -1,11 +0,0 @@ -Cloud = false -RecordRequests = true - -# This test drives both engines itself (one bundle per engine via a per-deploy -# DATABRICKS_BUNDLE_ENGINE), so pin the matrix to a single value to run once. -# The value only selects the CI runner; the script sets the engine explicitly. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] - -Ignore = [ - ".databricks", -] diff --git a/acceptance/bundle/empty_string_variable/out.test.toml b/acceptance/bundle/empty_string_variable/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/empty_string_variable/out.test.toml +++ b/acceptance/bundle/empty_string_variable/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/empty_string_variable/test.toml b/acceptance/bundle/empty_string_variable/test.toml deleted file mode 100644 index 6aab6ad6906..00000000000 --- a/acceptance/bundle/empty_string_variable/test.toml +++ /dev/null @@ -1,2 +0,0 @@ -# validate does not deploy, so engine choice is irrelevant: run once on direct. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/environments/dependencies/out.test.toml b/acceptance/bundle/environments/dependencies/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/environments/dependencies/out.test.toml +++ b/acceptance/bundle/environments/dependencies/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/escaped_refs/out.plan.direct.json b/acceptance/bundle/escaped_refs/out.plan.json similarity index 100% rename from acceptance/bundle/escaped_refs/out.plan.direct.json rename to acceptance/bundle/escaped_refs/out.plan.json diff --git a/acceptance/bundle/escaped_refs/out.plan.terraform.json b/acceptance/bundle/escaped_refs/out.plan.terraform.json deleted file mode 100644 index c984c20adea..00000000000 --- a/acceptance/bundle/escaped_refs/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.example_ingestion_job": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/escaped_refs/out.test.toml b/acceptance/bundle/escaped_refs/out.test.toml index bf4f0e7d3c6..f7fafbcc731 100644 --- a/acceptance/bundle/escaped_refs/out.test.toml +++ b/acceptance/bundle/escaped_refs/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/escaped_refs/script b/acceptance/bundle/escaped_refs/script index 2eacefcf553..2cce0c25096 100644 --- a/acceptance/bundle/escaped_refs/script +++ b/acceptance/bundle/escaped_refs/script @@ -18,7 +18,7 @@ title "Plan (json)" trace $CLI bundle plan -o json > .databricks/tmp.plan.json # The golden gets the stamped-out copy; the replay below reads the raw one, which still carries # the DMS headers deploy --plan validates. -nostamp < .databricks/tmp.plan.json > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +nostamp < .databricks/tmp.plan.json > out.plan.json # Not traced: the READPLAN variant adds "--plan ...", and the point of that variant is # that the payload below is identical either way. diff --git a/acceptance/bundle/experimental/skip_name_prefix_for_schema/out.test.toml b/acceptance/bundle/experimental/skip_name_prefix_for_schema/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/experimental/skip_name_prefix_for_schema/out.test.toml +++ b/acceptance/bundle/experimental/skip_name_prefix_for_schema/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/alert/out.test.toml b/acceptance/bundle/generate/alert/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/generate/alert/out.test.toml +++ b/acceptance/bundle/generate/alert/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/alert_existing_id_not_found/out.test.toml b/acceptance/bundle/generate/alert_existing_id_not_found/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/alert_existing_id_not_found/out.test.toml +++ b/acceptance/bundle/generate/alert_existing_id_not_found/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/app_git_backed/out.test.toml b/acceptance/bundle/generate/app_git_backed/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/app_git_backed/out.test.toml +++ b/acceptance/bundle/generate/app_git_backed/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/app_not_yet_deployed/out.test.toml b/acceptance/bundle/generate/app_not_yet_deployed/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/app_not_yet_deployed/out.test.toml +++ b/acceptance/bundle/generate/app_not_yet_deployed/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/app_subfolders/out.test.toml b/acceptance/bundle/generate/app_subfolders/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/app_subfolders/out.test.toml +++ b/acceptance/bundle/generate/app_subfolders/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/auto-bind/out.test.toml b/acceptance/bundle/generate/auto-bind/out.test.toml index 19131430a06..f68b4a89c36 100644 --- a/acceptance/bundle/generate/auto-bind/out.test.toml +++ b/acceptance/bundle/generate/auto-bind/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] -EnvMatrix.DMS = ["", "true"] +EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/generate/auto-bind/test.toml b/acceptance/bundle/generate/auto-bind/test.toml index 3f4ff3564c9..a075a267e00 100644 --- a/acceptance/bundle/generate/auto-bind/test.toml +++ b/acceptance/bundle/generate/auto-bind/test.toml @@ -12,4 +12,6 @@ Ignore = [ # Setting this environment variable prevents that conversion on windows. Env.MSYS_NO_PATHCONV = "1" -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] +# bind is not supported for a target that records deployment history, so exercise +# only the non-recording variant. +EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/generate/dashboard-inplace/out.test.toml b/acceptance/bundle/generate/dashboard-inplace/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/dashboard-inplace/out.test.toml +++ b/acceptance/bundle/generate/dashboard-inplace/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/dashboard/out.test.toml b/acceptance/bundle/generate/dashboard/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/dashboard/out.test.toml +++ b/acceptance/bundle/generate/dashboard/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/dashboard_existing_id_not_found/out.test.toml b/acceptance/bundle/generate/dashboard_existing_id_not_found/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/dashboard_existing_id_not_found/out.test.toml +++ b/acceptance/bundle/generate/dashboard_existing_id_not_found/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/dashboard_existing_path_nominal/out.test.toml b/acceptance/bundle/generate/dashboard_existing_path_nominal/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/dashboard_existing_path_nominal/out.test.toml +++ b/acceptance/bundle/generate/dashboard_existing_path_nominal/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/dashboard_existing_path_not_found/out.test.toml b/acceptance/bundle/generate/dashboard_existing_path_not_found/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/dashboard_existing_path_not_found/out.test.toml +++ b/acceptance/bundle/generate/dashboard_existing_path_not_found/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/designer_job/out.test.toml b/acceptance/bundle/generate/designer_job/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/designer_job/out.test.toml +++ b/acceptance/bundle/generate/designer_job/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/genie_space/out.test.toml b/acceptance/bundle/generate/genie_space/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/genie_space/out.test.toml +++ b/acceptance/bundle/generate/genie_space/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/genie_space_existing_id_not_found/out.test.toml b/acceptance/bundle/generate/genie_space_existing_id_not_found/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/genie_space_existing_id_not_found/out.test.toml +++ b/acceptance/bundle/generate/genie_space_existing_id_not_found/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/genie_space_inplace/out.test.toml b/acceptance/bundle/generate/genie_space_inplace/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/generate/genie_space_inplace/out.test.toml +++ b/acceptance/bundle/generate/genie_space_inplace/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/genie_space_inplace/test.toml b/acceptance/bundle/generate/genie_space_inplace/test.toml index 723c9907976..cdaa88d84ec 100644 --- a/acceptance/bundle/generate/genie_space_inplace/test.toml +++ b/acceptance/bundle/generate/genie_space_inplace/test.toml @@ -1,5 +1,4 @@ # Genie spaces are only deployed via the direct deployment engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] [[Repls]] Old = "[0-9a-f]{32}" diff --git a/acceptance/bundle/generate/git_job/out.test.toml b/acceptance/bundle/generate/git_job/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/git_job/out.test.toml +++ b/acceptance/bundle/generate/git_job/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/include_warning/out.test.toml b/acceptance/bundle/generate/include_warning/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/include_warning/out.test.toml +++ b/acceptance/bundle/generate/include_warning/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/ipynb_job/out.test.toml b/acceptance/bundle/generate/ipynb_job/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/ipynb_job/out.test.toml +++ b/acceptance/bundle/generate/ipynb_job/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/job_nested_notebooks/out.test.toml b/acceptance/bundle/generate/job_nested_notebooks/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/job_nested_notebooks/out.test.toml +++ b/acceptance/bundle/generate/job_nested_notebooks/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/lakeflow_pipelines/out.test.toml b/acceptance/bundle/generate/lakeflow_pipelines/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/lakeflow_pipelines/out.test.toml +++ b/acceptance/bundle/generate/lakeflow_pipelines/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/pipeline/out.test.toml b/acceptance/bundle/generate/pipeline/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/pipeline/out.test.toml +++ b/acceptance/bundle/generate/pipeline/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/pipeline_and_deploy/out.test.toml b/acceptance/bundle/generate/pipeline_and_deploy/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/generate/pipeline_and_deploy/out.test.toml +++ b/acceptance/bundle/generate/pipeline_and_deploy/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/pipeline_with_glob/out.test.toml b/acceptance/bundle/generate/pipeline_with_glob/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/pipeline_with_glob/out.test.toml +++ b/acceptance/bundle/generate/pipeline_with_glob/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/pipeline_with_sql/out.test.toml b/acceptance/bundle/generate/pipeline_with_sql/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/pipeline_with_sql/out.test.toml +++ b/acceptance/bundle/generate/pipeline_with_sql/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/python_job/out.test.toml b/acceptance/bundle/generate/python_job/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/python_job/out.test.toml +++ b/acceptance/bundle/generate/python_job/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/python_job_and_deploy/out.test.toml b/acceptance/bundle/generate/python_job_and_deploy/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/generate/python_job_and_deploy/out.test.toml +++ b/acceptance/bundle/generate/python_job_and_deploy/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/generate/spark_python_task_job/out.test.toml b/acceptance/bundle/generate/spark_python_task_job/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/generate/spark_python_task_job/out.test.toml +++ b/acceptance/bundle/generate/spark_python_task_job/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/git-metadata/out.test.toml b/acceptance/bundle/git-metadata/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/git-metadata/out.test.toml +++ b/acceptance/bundle/git-metadata/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/git-metadata/test.toml b/acceptance/bundle/git-metadata/test.toml index 9bf71f50ad4..96cdf4cd428 100644 --- a/acceptance/bundle/git-metadata/test.toml +++ b/acceptance/bundle/git-metadata/test.toml @@ -1,5 +1,4 @@ # Reading .git is independent of the deploy engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # The commit differs on every run. [[Repls]] diff --git a/acceptance/bundle/git-permerror/out.test.toml b/acceptance/bundle/git-permerror/out.test.toml index 56f228d004e..8c2cb31de53 100644 --- a/acceptance/bundle/git-permerror/out.test.toml +++ b/acceptance/bundle/git-permerror/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/hashing/new-cli-on-old-state/out.test.toml b/acceptance/bundle/hashing/new-cli-on-old-state/out.test.toml index d0b77dbc454..2ab253adc73 100644 --- a/acceptance/bundle/hashing/new-cli-on-old-state/out.test.toml +++ b/acceptance/bundle/hashing/new-cli-on-old-state/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [] diff --git a/acceptance/bundle/hashing/old-cli-on-new-state/out.test.toml b/acceptance/bundle/hashing/old-cli-on-new-state/out.test.toml index d0b77dbc454..2ab253adc73 100644 --- a/acceptance/bundle/hashing/old-cli-on-new-state/out.test.toml +++ b/acceptance/bundle/hashing/old-cli-on-new-state/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [] diff --git a/acceptance/bundle/hashing/test.toml b/acceptance/bundle/hashing/test.toml index 9ae55e94ef8..37e53e3ce25 100644 --- a/acceptance/bundle/hashing/test.toml +++ b/acceptance/bundle/hashing/test.toml @@ -1,7 +1,6 @@ # Cross-version state compat for direct-engine content hashing: $CLI hashes serialized_dashboard # in state; $CLI_1_16_1 (an old release) predates hashed_fields and stores it verbatim. # Direct-only and local, so the state reads are deterministic. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [] Ignore = ["databricks.yml"] diff --git a/acceptance/bundle/help/bundle-deploy/out.test.toml b/acceptance/bundle/help/bundle-deploy/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/help/bundle-deploy/out.test.toml +++ b/acceptance/bundle/help/bundle-deploy/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/help/bundle-deployment-migrate/out.test.toml b/acceptance/bundle/help/bundle-deployment-migrate/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/help/bundle-deployment-migrate/out.test.toml +++ b/acceptance/bundle/help/bundle-deployment-migrate/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/help/bundle-deployment/out.test.toml b/acceptance/bundle/help/bundle-deployment/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/help/bundle-deployment/out.test.toml +++ b/acceptance/bundle/help/bundle-deployment/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/help/bundle-destroy/out.test.toml b/acceptance/bundle/help/bundle-destroy/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/help/bundle-destroy/out.test.toml +++ b/acceptance/bundle/help/bundle-destroy/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/help/bundle-generate-dashboard/out.test.toml b/acceptance/bundle/help/bundle-generate-dashboard/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/help/bundle-generate-dashboard/out.test.toml +++ b/acceptance/bundle/help/bundle-generate-dashboard/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/help/bundle-generate-job/out.test.toml b/acceptance/bundle/help/bundle-generate-job/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/help/bundle-generate-job/out.test.toml +++ b/acceptance/bundle/help/bundle-generate-job/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/help/bundle-generate-pipeline/out.test.toml b/acceptance/bundle/help/bundle-generate-pipeline/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/help/bundle-generate-pipeline/out.test.toml +++ b/acceptance/bundle/help/bundle-generate-pipeline/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/help/bundle-generate/out.test.toml b/acceptance/bundle/help/bundle-generate/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/help/bundle-generate/out.test.toml +++ b/acceptance/bundle/help/bundle-generate/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/help/bundle-init/out.test.toml b/acceptance/bundle/help/bundle-init/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/help/bundle-init/out.test.toml +++ b/acceptance/bundle/help/bundle-init/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/help/bundle-open/out.test.toml b/acceptance/bundle/help/bundle-open/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/help/bundle-open/out.test.toml +++ b/acceptance/bundle/help/bundle-open/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/help/bundle-run/out.test.toml b/acceptance/bundle/help/bundle-run/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/help/bundle-run/out.test.toml +++ b/acceptance/bundle/help/bundle-run/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/help/bundle-schema/out.test.toml b/acceptance/bundle/help/bundle-schema/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/help/bundle-schema/out.test.toml +++ b/acceptance/bundle/help/bundle-schema/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/help/bundle-summary/out.test.toml b/acceptance/bundle/help/bundle-summary/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/help/bundle-summary/out.test.toml +++ b/acceptance/bundle/help/bundle-summary/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/help/bundle-sync/out.test.toml b/acceptance/bundle/help/bundle-sync/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/help/bundle-sync/out.test.toml +++ b/acceptance/bundle/help/bundle-sync/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/help/bundle-validate/out.test.toml b/acceptance/bundle/help/bundle-validate/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/help/bundle-validate/out.test.toml +++ b/acceptance/bundle/help/bundle-validate/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/help/bundle/out.test.toml b/acceptance/bundle/help/bundle/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/help/bundle/out.test.toml +++ b/acceptance/bundle/help/bundle/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/includes/glob_in_root_path/out.test.toml b/acceptance/bundle/includes/glob_in_root_path/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/includes/glob_in_root_path/out.test.toml +++ b/acceptance/bundle/includes/glob_in_root_path/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/includes/include_outside_root/out.test.toml b/acceptance/bundle/includes/include_outside_root/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/includes/include_outside_root/out.test.toml +++ b/acceptance/bundle/includes/include_outside_root/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/includes/non_yaml_in_include/out.test.toml b/acceptance/bundle/includes/non_yaml_in_include/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/includes/non_yaml_in_include/out.test.toml +++ b/acceptance/bundle/includes/non_yaml_in_include/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/includes/plan_multifile/out.test.toml b/acceptance/bundle/includes/plan_multifile/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/includes/plan_multifile/out.test.toml +++ b/acceptance/bundle/includes/plan_multifile/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/includes/yml_outside_root/out.test.toml b/acceptance/bundle/includes/yml_outside_root/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/includes/yml_outside_root/out.test.toml +++ b/acceptance/bundle/includes/yml_outside_root/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/integration_whl/base/out.test.toml b/acceptance/bundle/integration_whl/base/out.test.toml index 2fbe66e8d02..8bfa768b35b 100644 --- a/acceptance/bundle/integration_whl/base/out.test.toml +++ b/acceptance/bundle/integration_whl/base/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/integration_whl/custom_params/out.test.toml b/acceptance/bundle/integration_whl/custom_params/out.test.toml index 2fbe66e8d02..8bfa768b35b 100644 --- a/acceptance/bundle/integration_whl/custom_params/out.test.toml +++ b/acceptance/bundle/integration_whl/custom_params/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/integration_whl/interactive_cluster/out.test.toml b/acceptance/bundle/integration_whl/interactive_cluster/out.test.toml index 2fbe66e8d02..8bfa768b35b 100644 --- a/acceptance/bundle/integration_whl/interactive_cluster/out.test.toml +++ b/acceptance/bundle/integration_whl/interactive_cluster/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/integration_whl/interactive_cluster_dynamic_version/out.test.toml b/acceptance/bundle/integration_whl/interactive_cluster_dynamic_version/out.test.toml index bed2babe8f0..2a5a8204f13 100644 --- a/acceptance/bundle/integration_whl/interactive_cluster_dynamic_version/out.test.toml +++ b/acceptance/bundle/integration_whl/interactive_cluster_dynamic_version/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DATA_SECURITY_MODE = ["USER_ISOLATION", "SINGLE_USER"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/integration_whl/interactive_single_user/out.terraform.txt b/acceptance/bundle/integration_whl/interactive_single_user/out.terraform.txt deleted file mode 100644 index c9ac86bb078..00000000000 --- a/acceptance/bundle/integration_whl/interactive_single_user/out.terraform.txt +++ /dev/null @@ -1,6 +0,0 @@ -Hello from my func -Got arguments: -['my_test_code', 'one', 'two'] -UPDATED MY FUNC -Got arguments: -['my_test_code', 'one', 'two'] diff --git a/acceptance/bundle/integration_whl/interactive_single_user/out.test.toml b/acceptance/bundle/integration_whl/interactive_single_user/out.test.toml index 2fbe66e8d02..8bfa768b35b 100644 --- a/acceptance/bundle/integration_whl/interactive_single_user/out.test.toml +++ b/acceptance/bundle/integration_whl/interactive_single_user/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/integration_whl/interactive_single_user/out.direct.txt b/acceptance/bundle/integration_whl/interactive_single_user/out.txt similarity index 100% rename from acceptance/bundle/integration_whl/interactive_single_user/out.direct.txt rename to acceptance/bundle/integration_whl/interactive_single_user/out.txt diff --git a/acceptance/bundle/integration_whl/interactive_single_user/script b/acceptance/bundle/integration_whl/interactive_single_user/script index 25227da81ce..62f516d0a5b 100644 --- a/acceptance/bundle/integration_whl/interactive_single_user/script +++ b/acceptance/bundle/integration_whl/interactive_single_user/script @@ -8,9 +8,9 @@ trace $CLI bundle deploy # Add all resource IDs to runtime replacements to avoid pattern matching ambiguity replace_ids.py -trace $CLI bundle run some_other_job > out.$DATABRICKS_BUNDLE_ENGINE.txt +trace $CLI bundle run some_other_job > out.txt title "Make a change to code without version change and run the job again" update_file.py my_test_code/__main__.py 'Hello from my func' 'UPDATED MY FUNC' trace $CLI bundle deploy -qq -trace $CLI bundle run some_other_job >> out.$DATABRICKS_BUNDLE_ENGINE.txt +trace $CLI bundle run some_other_job >> out.txt diff --git a/acceptance/bundle/integration_whl/serverless/out.test.toml b/acceptance/bundle/integration_whl/serverless/out.test.toml index 2fbe66e8d02..8bfa768b35b 100644 --- a/acceptance/bundle/integration_whl/serverless/out.test.toml +++ b/acceptance/bundle/integration_whl/serverless/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/integration_whl/serverless_custom_params/out.test.toml b/acceptance/bundle/integration_whl/serverless_custom_params/out.test.toml index 2fbe66e8d02..8bfa768b35b 100644 --- a/acceptance/bundle/integration_whl/serverless_custom_params/out.test.toml +++ b/acceptance/bundle/integration_whl/serverless_custom_params/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/integration_whl/serverless_dynamic_version/out.test.toml b/acceptance/bundle/integration_whl/serverless_dynamic_version/out.test.toml index 2fbe66e8d02..8bfa768b35b 100644 --- a/acceptance/bundle/integration_whl/serverless_dynamic_version/out.test.toml +++ b/acceptance/bundle/integration_whl/serverless_dynamic_version/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/integration_whl/serverless_extras/out.test.toml b/acceptance/bundle/integration_whl/serverless_extras/out.test.toml index 2fbe66e8d02..8bfa768b35b 100644 --- a/acceptance/bundle/integration_whl/serverless_extras/out.test.toml +++ b/acceptance/bundle/integration_whl/serverless_extras/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/integration_whl/serverless_extras_dynamic_version/out.test.toml b/acceptance/bundle/integration_whl/serverless_extras_dynamic_version/out.test.toml index 2fbe66e8d02..8bfa768b35b 100644 --- a/acceptance/bundle/integration_whl/serverless_extras_dynamic_version/out.test.toml +++ b/acceptance/bundle/integration_whl/serverless_extras_dynamic_version/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/integration_whl/wrapper/out.test.toml b/acceptance/bundle/integration_whl/wrapper/out.test.toml index e700e9c2d60..14134330c80 100644 --- a/acceptance/bundle/integration_whl/wrapper/out.test.toml +++ b/acceptance/bundle/integration_whl/wrapper/out.test.toml @@ -2,5 +2,4 @@ Cloud = true CloudSlow = true CloudEnvs.aws = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/integration_whl/wrapper_custom_params/out.test.toml b/acceptance/bundle/integration_whl/wrapper_custom_params/out.test.toml index e700e9c2d60..14134330c80 100644 --- a/acceptance/bundle/integration_whl/wrapper_custom_params/out.test.toml +++ b/acceptance/bundle/integration_whl/wrapper_custom_params/out.test.toml @@ -2,5 +2,4 @@ Cloud = true CloudSlow = true CloudEnvs.aws = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/invariant/continue_293/out.test.toml b/acceptance/bundle/invariant/continue_293/out.test.toml index ed4df27cf9c..34de84fc68a 100644 --- a/acceptance/bundle/invariant/continue_293/out.test.toml +++ b/acceptance/bundle/invariant/continue_293/out.test.toml @@ -1,5 +1,4 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] EnvMatrix.INPUT_CONFIG = [ "alert.yml.tmpl", diff --git a/acceptance/bundle/invariant/continue_293/output.txt b/acceptance/bundle/invariant/continue_293/output.txt index 03524f59807..e9d149fec08 100644 --- a/acceptance/bundle/invariant/continue_293/output.txt +++ b/acceptance/bundle/invariant/continue_293/output.txt @@ -1,4 +1,5 @@ >>> [CLI_293] --version Databricks CLI v0.293.0 -INPUT_CONFIG_OK + +Exit code: 1 diff --git a/acceptance/bundle/invariant/delete_idempotent/out.test.toml b/acceptance/bundle/invariant/delete_idempotent/out.test.toml index c1dbc9c5eb5..519e51ab3b9 100644 --- a/acceptance/bundle/invariant/delete_idempotent/out.test.toml +++ b/acceptance/bundle/invariant/delete_idempotent/out.test.toml @@ -1,5 +1,4 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] EnvMatrix.INPUT_CONFIG = [ "alert.yml.tmpl", diff --git a/acceptance/bundle/invariant/destroy_idempotent/out.test.toml b/acceptance/bundle/invariant/destroy_idempotent/out.test.toml index c1dbc9c5eb5..519e51ab3b9 100644 --- a/acceptance/bundle/invariant/destroy_idempotent/out.test.toml +++ b/acceptance/bundle/invariant/destroy_idempotent/out.test.toml @@ -1,5 +1,4 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] EnvMatrix.INPUT_CONFIG = [ "alert.yml.tmpl", diff --git a/acceptance/bundle/invariant/migrate/out.test.toml b/acceptance/bundle/invariant/migrate/out.test.toml deleted file mode 100644 index fbdc7b564a7..00000000000 --- a/acceptance/bundle/invariant/migrate/out.test.toml +++ /dev/null @@ -1,47 +0,0 @@ -Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] -EnvMatrix.INPUT_CONFIG = [ - "alert.yml.tmpl", - "app.yml.tmpl", - "cluster.yml.tmpl", - "cluster_apply_policy_default_values.yml.tmpl", - "dashboard.yml.tmpl", - "job_apply_policy_default_values_job_cluster.yml.tmpl", - "job_apply_policy_default_values_task_cluster.yml.tmpl", - "job_apply_policy_default_values_for_each_task.yml.tmpl", - "database_catalog.yml.tmpl", - "database_instance.yml.tmpl", - "experiment.yml.tmpl", - "job.yml.tmpl", - "job_pydabs_10_tasks.yml.tmpl", - "job_escaped_refs.yml.tmpl", - "job_run_job_ref.yml.tmpl", - "job_table_update_trigger.yml.tmpl", - "job_with_depends_on.yml.tmpl", - "job_with_task.yml.tmpl", - "model.yml.tmpl", - "model_with_permissions.yml.tmpl", - "model_serving_endpoint.yml.tmpl", - "pipeline.yml.tmpl", - "pipeline_allow_duplicate_names.yml.tmpl", - "pipeline_apply_policy_default_values.yml.tmpl", - "pipeline_config_dots.yml.tmpl", - "postgres_branch.yml.tmpl", - "postgres_catalog.yml.tmpl", - "postgres_database.yml.tmpl", - "postgres_endpoint.yml.tmpl", - "postgres_project.yml.tmpl", - "postgres_role.yml.tmpl", - "postgres_synced_table.yml.tmpl", - "registered_model.yml.tmpl", - "schema.yml.tmpl", - "schema_empty_grants.yml.tmpl", - "schema_uppercase_name.yml.tmpl", - "secret_scope.yml.tmpl", - "secret_scope_default_backend_type.yml.tmpl", - "synced_database_table.yml.tmpl", - "volume.yml.tmpl", - "volume_external.yml.tmpl", - "volume_path_job_ref.yml.tmpl" -] diff --git a/acceptance/bundle/invariant/migrate/output.txt b/acceptance/bundle/invariant/migrate/output.txt deleted file mode 100644 index 7a28cb73a58..00000000000 --- a/acceptance/bundle/invariant/migrate/output.txt +++ /dev/null @@ -1 +0,0 @@ -INPUT_CONFIG_OK diff --git a/acceptance/bundle/invariant/migrate/script b/acceptance/bundle/invariant/migrate/script deleted file mode 100644 index 4cd19571951..00000000000 --- a/acceptance/bundle/invariant/migrate/script +++ /dev/null @@ -1,24 +0,0 @@ -# Invariant to test: migrate is successful, no drift after deploy -# Additional checks: no internal errors / panics in any commands - -unset DATABRICKS_BUNDLE_ENGINE - -invariant_setup - -invariant_deploy LOG.deploy DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy - -MIGRATE_ARGS="" -# The terraform provider sorts depends_on entries alphabetically by task_key on Read -# (see terraform-provider-databricks PR #3000). Since depends_on uses TypeList -# (order-sensitive), terraform plan reports positional drift when the bundle config -# specifies depends_on in a different order than the provider's sorted state. -# This is a false positive -- the logical dependencies are identical. -if [[ "$INPUT_CONFIG" == "job_with_depends_on.yml.tmpl" ]]; then - MIGRATE_ARGS="--noplancheck" -fi - -trace $CLI bundle deployment migrate $MIGRATE_ARGS &> LOG.migrate - -cat LOG.migrate | contains.py '!panic:' '!internal error' > /dev/null - -invariant_verify_no_drift diff --git a/acceptance/bundle/invariant/migrate/test.toml b/acceptance/bundle/invariant/migrate/test.toml deleted file mode 100644 index f2d627584c5..00000000000 --- a/acceptance/bundle/invariant/migrate/test.toml +++ /dev/null @@ -1,55 +0,0 @@ -# Recording needs a bundle it has seen from the start. This test seeds a state file, -# so recording refuses it. TODO(DMS): drop this once existing state can be -# handed over to the service (see the TODO in dstate.Open). -EnvMatrix.DMS = [""] - -# vector_search_endpoints and vector_search_indexes have no terraform converter -EnvMatrixExclude.no_vector_search_endpoint = ["INPUT_CONFIG=vector_search_endpoint.yml.tmpl"] -EnvMatrixExclude.no_vector_search_index = ["INPUT_CONFIG=vector_search_index.yml.tmpl"] - -# job_runs is a direct-only resource with no terraform converter, so the -# terraform deploy that seeds the migration fails for it. -EnvMatrixExclude.no_job_run = ["INPUT_CONFIG=job_run.yml.tmpl"] - -# Error: Catalog resources are only supported with direct deployment mode -EnvMatrixExclude.no_catalog = ["INPUT_CONFIG=catalog.yml.tmpl"] -EnvMatrixExclude.no_catalog_optional_fields = ["INPUT_CONFIG=catalog_optional_fields.yml.tmpl"] -EnvMatrixExclude.no_external_location = ["INPUT_CONFIG=external_location.yml.tmpl"] -# uc_trailing_slash includes a catalog, which is direct-only (see above). -EnvMatrixExclude.no_uc_trailing_slash = ["INPUT_CONFIG=uc_trailing_slash.yml.tmpl"] -# Genie spaces are direct-only too; the terraform deploy that seeds the migration fails for them. -EnvMatrixExclude.no_genie_space = ["INPUT_CONFIG=genie_space.yml.tmpl"] -# Instance pools are direct-only; the terraform deploy that seeds the migration fails for them. -EnvMatrixExclude.no_instance_pool = ["INPUT_CONFIG=instance_pool.yml.tmpl"] -# Cluster policies are direct-only; the terraform deploy that seeds the migration fails for them. -EnvMatrixExclude.no_cluster_policy = ["INPUT_CONFIG=cluster_policy.yml.tmpl"] -# AI Gateway securables are direct-only; the terraform deploy that seeds the migration fails for them. -EnvMatrixExclude.no_model_service = ["INPUT_CONFIG=model_service.yml.tmpl"] - -# Cross-resource permission references (e.g. ${resources.jobs.job_b.permissions[0].level}) -# don't work in terraform mode: the terraform interpolator converts the path to -# ${databricks_job.job_b.permissions[0].level}, but Terraform's databricks_job resource -# does not expose permissions as output attributes (permissions are a separate -# databricks_permissions resource in terraform), so the literal unresolved string -# ends up as the permission level value. -EnvMatrixExclude.no_permission_ref = ["INPUT_CONFIG=job_permission_ref.yml.tmpl"] -EnvMatrixExclude.no_cross_resource_ref = ["INPUT_CONFIG=job_cross_resource_ref.yml.tmpl"] - -# Grant cross-references require the EmbeddedSlice pattern not present in terraform mode. -EnvMatrixExclude.no_grant_ref = ["INPUT_CONFIG=schema_grant_ref.yml.tmpl"] - -# SQL warehouses currently failing with migration with permanent drift. TODO: fix this. -EnvMatrixExclude.no_sql_warehouse = ["INPUT_CONFIG=sql_warehouse.yml.tmpl"] - -# The 1000-task scale case is covered by no_drift. Running it here adds ~1.5 min -# per variant (deploy + migrate + plan at 1000 tasks) without incremental coverage. -EnvMatrixExclude.no_pydabs_1000_tasks = ["INPUT_CONFIG=job_pydabs_1000_tasks.yml.tmpl"] - -# migrate deploys via Terraform first, and the TF provider rejects an uppercase -# volume schema_name ("inconsistent final plan"). Covered by no_drift on direct. -EnvMatrixExclude.no_volume_uppercase = ["INPUT_CONFIG=volume_uppercase_name.yml.tmpl"] - -EnvMatrixExclude.no_secret = ["INPUT_CONFIG=secret.yml.tmpl"] - -# Terraform types sampling_fraction as an integer and truncates 0.5; covered by no_drift. -EnvMatrixExclude.no_model_serving_endpoint_telemetry = ["INPUT_CONFIG=model_serving_endpoint_telemetry.yml.tmpl"] diff --git a/acceptance/bundle/invariant/no_drift/out.test.toml b/acceptance/bundle/invariant/no_drift/out.test.toml index e2ffcb138a0..dcde6a50c64 100644 --- a/acceptance/bundle/invariant/no_drift/out.test.toml +++ b/acceptance/bundle/invariant/no_drift/out.test.toml @@ -1,5 +1,4 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.INPUT_CONFIG = [ "alert.yml.tmpl", diff --git a/acceptance/bundle/invariant/test.toml b/acceptance/bundle/invariant/test.toml index 0dd45a06b37..f3422c92269 100644 --- a/acceptance/bundle/invariant/test.toml +++ b/acceptance/bundle/invariant/test.toml @@ -12,12 +12,6 @@ Ignore = [ "app", ] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = [ - "direct", - # These tests work on terraform but commented out to save time on test run - #"terraform", -] - EnvMatrix.INPUT_CONFIG = [ "alert.yml.tmpl", "app.yml.tmpl", diff --git a/acceptance/bundle/libraries/maven/out.test.toml b/acceptance/bundle/libraries/maven/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/libraries/maven/out.test.toml +++ b/acceptance/bundle/libraries/maven/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/libraries/outside_of_bundle_root/out.test.toml b/acceptance/bundle/libraries/outside_of_bundle_root/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/libraries/outside_of_bundle_root/out.test.toml +++ b/acceptance/bundle/libraries/outside_of_bundle_root/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/libraries/pypi/out.test.toml b/acceptance/bundle/libraries/pypi/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/libraries/pypi/out.test.toml +++ b/acceptance/bundle/libraries/pypi/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/lifecycle/prevent-destroy/out.terraform.txt b/acceptance/bundle/lifecycle/prevent-destroy/out.terraform.txt deleted file mode 100644 index 4baf1cc6d1f..00000000000 --- a/acceptance/bundle/lifecycle/prevent-destroy/out.terraform.txt +++ /dev/null @@ -1,153 +0,0 @@ - ->>> musterr [CLI] bundle destroy --auto-approve -Error: exit status 1 - -Error: Instance cannot be destroyed - - on bundle.tf.json line 15, in resource.databricks_pipeline: - 15: "my_pipelines": { - -Resource databricks_pipeline.my_pipelines has lifecycle.prevent_destroy set, -but the plan calls for this resource to be destroyed. To avoid this error and -continue with the plan, either disable lifecycle.prevent_destroy or reduce -the scope of the plan using the -target flag. - -Error: Instance cannot be destroyed - - on bundle.tf.json line 38, in resource.databricks_schema: - 38: "my_schema": { - -Resource databricks_schema.my_schema has lifecycle.prevent_destroy set, but -the plan calls for this resource to be destroyed. To avoid this error and -continue with the plan, either disable lifecycle.prevent_destroy or reduce -the scope of the plan using the -target flag. - - - ->>> errcode [CLI] bundle plan -Error: exit status 1 - -Error: Instance cannot be destroyed - - on bundle.tf.json line 15, in resource.databricks_pipeline: - 15: "my_pipelines": { - -Resource databricks_pipeline.my_pipelines has lifecycle.prevent_destroy set, -but the plan calls for this resource to be destroyed. To avoid this error and -continue with the plan, either disable lifecycle.prevent_destroy or reduce -the scope of the plan using the -target flag. - - - -Exit code: 1 - ->>> musterr [CLI] bundle deploy -qq -Error: exit status 1 - -Error: Instance cannot be destroyed - - on bundle.tf.json line 15, in resource.databricks_pipeline: - 15: "my_pipelines": { - -Resource databricks_pipeline.my_pipelines has lifecycle.prevent_destroy set, -but the plan calls for this resource to be destroyed. To avoid this error and -continue with the plan, either disable lifecycle.prevent_destroy or reduce -the scope of the plan using the -target flag. - - - ->>> errcode [CLI] bundle plan -Error: exit status 1 - -Error: Instance cannot be destroyed - - on bundle.tf.json line 15, in resource.databricks_pipeline: - 15: "my_pipelines": { - -Resource databricks_pipeline.my_pipelines has lifecycle.prevent_destroy set, -but the plan calls for this resource to be destroyed. To avoid this error and -continue with the plan, either disable lifecycle.prevent_destroy or reduce -the scope of the plan using the -target flag. - -Error: Instance cannot be destroyed - - on bundle.tf.json line 38, in resource.databricks_schema: - 38: "my_schema": { - -Resource databricks_schema.my_schema has lifecycle.prevent_destroy set, but -the plan calls for this resource to be destroyed. To avoid this error and -continue with the plan, either disable lifecycle.prevent_destroy or reduce -the scope of the plan using the -target flag. - - - -Exit code: 1 - ->>> musterr [CLI] bundle deploy -qq -Error: exit status 1 - -Error: Instance cannot be destroyed - - on bundle.tf.json line 15, in resource.databricks_pipeline: - 15: "my_pipelines": { - -Resource databricks_pipeline.my_pipelines has lifecycle.prevent_destroy set, -but the plan calls for this resource to be destroyed. To avoid this error and -continue with the plan, either disable lifecycle.prevent_destroy or reduce -the scope of the plan using the -target flag. - -Error: Instance cannot be destroyed - - on bundle.tf.json line 38, in resource.databricks_schema: - 38: "my_schema": { - -Resource databricks_schema.my_schema has lifecycle.prevent_destroy set, but -the plan calls for this resource to be destroyed. To avoid this error and -continue with the plan, either disable lifecycle.prevent_destroy or reduce -the scope of the plan using the -target flag. - - - ->>> errcode [CLI] bundle plan -recreate pipelines.my_pipelines -recreate schemas.my_schema - -Plan: 2 to add, 0 to change, 2 to delete, 0 unchanged - ->>> [CLI] bundle deploy --auto-approve -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/prevent-destroy/default/files... - -This action will result in the deletion or recreation of the following UC schemas. Any underlying data may be lost: - recreate resources.schemas.my_schema - -This action will result in the deletion or recreation of the following Lakeflow Spark Declarative Pipelines along with the -Streaming Tables (STs) and Materialized Views (MVs) managed by them. Recreating the pipelines will -restore the defined STs and MVs through full refresh. Note that recreation is necessary when pipeline -properties such as the 'catalog' or 'storage' are changed: - recreate resources.pipelines.my_pipelines -Recreated pipelines.my_pipelines -Recreated schemas.my_schema -Files: 3 uploaded, 0 deleted -Resources: 2 created, 0 changed, 2 deleted, 0 unchanged - ->>> errcode [CLI] bundle plan -delete pipelines.my_pipelines -delete schemas.my_schema - -Plan: 0 to add, 0 to change, 2 to delete, 0 unchanged - ->>> [CLI] bundle deploy --auto-approve -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/prevent-destroy/default/files... - -This action will result in the deletion or recreation of the following UC schemas. Any underlying data may be lost: - delete resources.schemas.my_schema - -This action will result in the deletion or recreation of the following Lakeflow Spark Declarative Pipelines along with the -Streaming Tables (STs) and Materialized Views (MVs) managed by them. Recreating the pipelines will -restore the defined STs and MVs through full refresh. Note that recreation is necessary when pipeline -properties such as the 'catalog' or 'storage' are changed: - delete resources.pipelines.my_pipelines -Deleted pipelines.my_pipelines -Deleted schemas.my_schema -Files: 1 uploaded, 2 deleted -Resources: 0 created, 0 changed, 2 deleted, 0 unchanged diff --git a/acceptance/bundle/lifecycle/prevent-destroy/out.test.toml b/acceptance/bundle/lifecycle/prevent-destroy/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/lifecycle/prevent-destroy/out.test.toml +++ b/acceptance/bundle/lifecycle/prevent-destroy/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/lifecycle/prevent-destroy/out.direct.txt b/acceptance/bundle/lifecycle/prevent-destroy/out.txt similarity index 100% rename from acceptance/bundle/lifecycle/prevent-destroy/out.direct.txt rename to acceptance/bundle/lifecycle/prevent-destroy/out.txt diff --git a/acceptance/bundle/lifecycle/prevent-destroy/script b/acceptance/bundle/lifecycle/prevent-destroy/script index 06fea3fdef6..a2c90cea5b5 100644 --- a/acceptance/bundle/lifecycle/prevent-destroy/script +++ b/acceptance/bundle/lifecycle/prevent-destroy/script @@ -3,30 +3,30 @@ trace $CLI bundle validate trace $CLI bundle deploy trace errcode $CLI bundle plan -trace musterr $CLI bundle destroy --auto-approve >>out.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 +trace musterr $CLI bundle destroy --auto-approve >>out.txt 2>&1 # Note: In Terraform provider v1.98.0+, changing the catalog no longer triggers recreation. # We use storage location instead, which still requires recreation. # Changing from catalog to storage, deploy must fail because pipeline will be recreated update_file.py resources/pipeline.yml ' catalog: main' ' storage: "dbfs:/my-storage"' -trace errcode $CLI bundle plan >>out.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 -trace musterr $CLI bundle deploy -qq >>out.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 +trace errcode $CLI bundle plan >>out.txt 2>&1 +trace musterr $CLI bundle deploy -qq >>out.txt 2>&1 # Changing the schema name, deploy must fail because schema will be recreated update_file.py resources/schema.yml 'name: test-schema' 'name: test-schema-new' -trace errcode $CLI bundle plan >>out.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 -trace musterr $CLI bundle deploy -qq >>out.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 +trace errcode $CLI bundle plan >>out.txt 2>&1 +trace musterr $CLI bundle deploy -qq >>out.txt 2>&1 # Removing the prevent_destroy, deploy must succeed update_file.py resources/pipeline.yml 'prevent_destroy: true' 'prevent_destroy: false' update_file.py resources/schema.yml 'prevent_destroy: true' 'prevent_destroy: false' -trace errcode $CLI bundle plan >>out.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 -trace $CLI bundle deploy --auto-approve >>out.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 +trace errcode $CLI bundle plan >>out.txt 2>&1 +trace $CLI bundle deploy --auto-approve >>out.txt 2>&1 update_file.py resources/pipeline.yml 'prevent_destroy: false' 'prevent_destroy: true' update_file.py resources/schema.yml 'prevent_destroy: false' 'prevent_destroy: true' # Removing the pipeline and schema, deploy must succeed rm resources/pipeline.yml resources/schema.yml -trace errcode $CLI bundle plan >>out.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 -trace $CLI bundle deploy --auto-approve >>out.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 +trace errcode $CLI bundle plan >>out.txt 2>&1 +trace $CLI bundle deploy --auto-approve >>out.txt 2>&1 diff --git a/acceptance/bundle/lifecycle/started-validation/out.terraform.txt b/acceptance/bundle/lifecycle/started-validation/out.terraform.txt deleted file mode 100644 index ef87f528c1c..00000000000 --- a/acceptance/bundle/lifecycle/started-validation/out.terraform.txt +++ /dev/null @@ -1,11 +0,0 @@ - ->>> errcode [CLI] bundle plan -Warning: unknown field: started - at resources.jobs.my_job.lifecycle - in databricks.yml:9:9 - -Error: lifecycle.started is only supported in direct deployment mode - in databricks.yml:16:18 - - -Exit code: 1 diff --git a/acceptance/bundle/lifecycle/started-validation/out.test.toml b/acceptance/bundle/lifecycle/started-validation/out.test.toml index dd4cf5e8994..a927a5fbc06 100644 --- a/acceptance/bundle/lifecycle/started-validation/out.test.toml +++ b/acceptance/bundle/lifecycle/started-validation/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/lifecycle/started-validation/out.direct.txt b/acceptance/bundle/lifecycle/started-validation/out.txt similarity index 100% rename from acceptance/bundle/lifecycle/started-validation/out.direct.txt rename to acceptance/bundle/lifecycle/started-validation/out.txt diff --git a/acceptance/bundle/lifecycle/started-validation/script b/acceptance/bundle/lifecycle/started-validation/script index ff9d8c04540..d8d063aa7aa 100644 --- a/acceptance/bundle/lifecycle/started-validation/script +++ b/acceptance/bundle/lifecycle/started-validation/script @@ -1 +1 @@ -trace errcode $CLI bundle plan >> out.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 +trace errcode $CLI bundle plan >> out.txt 2>&1 diff --git a/acceptance/bundle/lifecycle/started-validation/test.toml b/acceptance/bundle/lifecycle/started-validation/test.toml index 35e689a72ad..601384fdf96 100644 --- a/acceptance/bundle/lifecycle/started-validation/test.toml +++ b/acceptance/bundle/lifecycle/started-validation/test.toml @@ -1,3 +1 @@ Ignore = [".databricks"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/lifecycle/started/out.test.toml b/acceptance/bundle/lifecycle/started/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/lifecycle/started/out.test.toml +++ b/acceptance/bundle/lifecycle/started/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/lifecycle/started/test.toml b/acceptance/bundle/lifecycle/started/test.toml index 6374f1d67a5..731086bc182 100644 --- a/acceptance/bundle/lifecycle/started/test.toml +++ b/acceptance/bundle/lifecycle/started/test.toml @@ -1,5 +1,3 @@ Cloud = false Ignore = [".databricks"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/local_state_staleness/out.test.toml b/acceptance/bundle/local_state_staleness/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/local_state_staleness/out.test.toml +++ b/acceptance/bundle/local_state_staleness/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/migrate/added-direct-only/databricks.yml b/acceptance/bundle/migrate/added-direct-only/databricks.yml deleted file mode 100644 index 8f2a40d4f2b..00000000000 --- a/acceptance/bundle/migrate/added-direct-only/databricks.yml +++ /dev/null @@ -1,7 +0,0 @@ -bundle: - name: test-bundle - -resources: - #instance_pools: {pool: {instance_pool_name: "My Pool", node_type_id: "Standard_DS3_v2", idle_instance_autotermination_minutes: 60}} - jobs: - job_a: {name: "Job A"} diff --git a/acceptance/bundle/migrate/added-direct-only/out.test.toml b/acceptance/bundle/migrate/added-direct-only/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/added-direct-only/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/added-direct-only/output.txt b/acceptance/bundle/migrate/added-direct-only/output.txt deleted file mode 100644 index 3b6e7ae1142..00000000000 --- a/acceptance/bundle/migrate/added-direct-only/output.txt +++ /dev/null @@ -1,63 +0,0 @@ - -=== Deploy with terraform (instance_pools is commented out; terraform cannot deploy it) ->>> [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created jobs.job_a -Files: 2 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged - -=== Add a direct-only resource to the config without deploying it ->>> update_file.py databricks.yml #instance_pools instance_pools - -=== Deploying on terraform rejects it, which is what sends the user to migrate ->>> musterr [CLI] bundle deploy -Error: Instance Pool resources are only supported with direct deployment mode - in databricks.yml:5:19 - -Instance Pool resources require direct deployment mode. Please set the DATABRICKS_BUNDLE_ENGINE environment variable to 'direct' or set 'bundle.engine: direct' in your databricks.yml to use instance_pool resources. -Learn more at https://docs.databricks.com/dev-tools/bundles/direct - - -=== Migration ignores the direct-only resource; it will be created on the next deploy ->>> [CLI] bundle deployment migrate -Success! Migrated 1 resources to direct engine state file: [TEST_TMP_DIR]/.databricks/bundle/default/resources.json - -Validate the migration by running "databricks bundle plan", there should be no actions planned. - -The state file is not synchronized to the workspace yet. To do that and finalize the migration, run "bundle deploy". - -To undo the migration, remove [TEST_TMP_DIR]/.databricks/bundle/default/resources.json and rename [TEST_TMP_DIR]/.databricks/bundle/default/terraform/terraform.tfstate.backup to [TEST_TMP_DIR]/.databricks/bundle/default/terraform/terraform.tfstate - - -=== After migration: plan shows the direct-only resource as "to add" ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle plan -create instance_pools.pool - -Plan: 1 to add, 0 to change, 0 to delete, 1 unchanged - -=== Deploy creates it; verify via recorded requests ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created instance_pools.pool -Files: 1 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 1 unchanged - ->>> print_requests.py //instance-pools/create -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/direct auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.0/instance-pools/create", - "body": { - "idle_instance_autotermination_minutes": 60, - "instance_pool_name": "My Pool", - "node_type_id": "Standard_DS3_v2" - } -} - -=== No further actions planned ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 2 unchanged diff --git a/acceptance/bundle/migrate/added-direct-only/script b/acceptance/bundle/migrate/added-direct-only/script deleted file mode 100644 index e500a603b6d..00000000000 --- a/acceptance/bundle/migrate/added-direct-only/script +++ /dev/null @@ -1,26 +0,0 @@ -export DATABRICKS_BUNDLE_ENGINE=terraform - -title "Deploy with terraform (instance_pools is commented out; terraform cannot deploy it)" -trace $CLI bundle deploy - -title "Add a direct-only resource to the config without deploying it" -trace update_file.py databricks.yml "#instance_pools" "instance_pools" - -title "Deploying on terraform rejects it, which is what sends the user to migrate" -trace musterr $CLI bundle deploy - -title "Migration ignores the direct-only resource; it will be created on the next deploy" -trace $CLI bundle deployment migrate - -title "After migration: plan shows the direct-only resource as \"to add\"" -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle plan - -title "Deploy creates it; verify via recorded requests" -rm "$OUT_REQUESTS" -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle deploy -trace print_requests.py //instance-pools/create - -title "No further actions planned" -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle plan - -rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/migrate/added/databricks.yml b/acceptance/bundle/migrate/added/databricks.yml deleted file mode 100644 index e245a4f02b5..00000000000 --- a/acceptance/bundle/migrate/added/databricks.yml +++ /dev/null @@ -1,7 +0,0 @@ -bundle: - name: migrate-added-test - -resources: - jobs: - job_a: {name: "Job A"} - #job_b: {name: "Job B"} diff --git a/acceptance/bundle/migrate/added/out.test.toml b/acceptance/bundle/migrate/added/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/added/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/added/output.txt b/acceptance/bundle/migrate/added/output.txt deleted file mode 100644 index 609d0237d6e..00000000000 --- a/acceptance/bundle/migrate/added/output.txt +++ /dev/null @@ -1,54 +0,0 @@ - ->>> [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/migrate-added-test/default/files... -Created jobs.job_a -Files: 2 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged - ->>> [CLI] bundle deployment migrate -Success! Migrated 1 resources to direct engine state file: [TEST_TMP_DIR]/.databricks/bundle/default/resources.json - -Validate the migration by running "databricks bundle plan", there should be no actions planned. - -The state file is not synchronized to the workspace yet. To do that and finalize the migration, run "bundle deploy". - -To undo the migration, remove [TEST_TMP_DIR]/.databricks/bundle/default/resources.json and rename [TEST_TMP_DIR]/.databricks/bundle/default/terraform/terraform.tfstate.backup to [TEST_TMP_DIR]/.databricks/bundle/default/terraform/terraform.tfstate - - ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle plan -create jobs.job_b - -Plan: 1 to add, 0 to change, 0 to delete, 1 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/migrate-added-test/default/files... -Created jobs.job_b -Files: 1 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 1 unchanged - ->>> print_requests.py //jobs/create -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/direct auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.2/jobs/create", - "body": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-added-test/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "Job B", - "queue": { - "enabled": true - } - } -} - ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 2 unchanged diff --git a/acceptance/bundle/migrate/added/script b/acceptance/bundle/migrate/added/script deleted file mode 100644 index 78846a084bf..00000000000 --- a/acceptance/bundle/migrate/added/script +++ /dev/null @@ -1,23 +0,0 @@ -export DATABRICKS_BUNDLE_ENGINE=terraform - -# Deploy with terraform (only job_a; job_b is commented out) -trace $CLI bundle deploy - -# Uncomment job_b (add it to config without deploying) -update_file.py databricks.yml "#job_b" "job_b" - -# job_b skipped, will be created on next deploy -trace $CLI bundle deployment migrate - -# After migration: plan shows job_b as "to add" -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle plan | contains.py "1 to add" - -# Deploy creates job_b; verify via recorded requests -rm "$OUT_REQUESTS" -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle deploy -trace print_requests.py //jobs/create - -# No further actions planned -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle plan | contains.py "2 unchanged" - -rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/migrate/auto-migrate-clean/databricks.yml b/acceptance/bundle/migrate/auto-migrate-clean/databricks.yml deleted file mode 100644 index 7acc0c3576e..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-clean/databricks.yml +++ /dev/null @@ -1,7 +0,0 @@ -bundle: - name: test-bundle - -resources: - jobs: - test_job: - name: "Test Auto-Migrate Job" diff --git a/acceptance/bundle/migrate/auto-migrate-clean/out.plan_update.direct.json b/acceptance/bundle/migrate/auto-migrate-clean/out.plan_update.direct.json deleted file mode 100644 index 0ee7d34a8ca..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-clean/out.plan_update.direct.json +++ /dev/null @@ -1,69 +0,0 @@ -{ - "plan_version": [PLAN_VERSION], - "cli_version": "[CLI_VERSION]", - "lineage": "[UUID]", - "serial": 3, - "plan": { - "resources.jobs.test_job": { - "action": "update", - "new_state": { - "value": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "Test Auto-Migrate Job (renamed)", - "queue": { - "enabled": true - } - } - }, - "remote_state": { - "created_time": [UNIX_TIME_MILLIS], - "creator_user_name": "[USERNAME]", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "email_notifications": {}, - "format": "MULTI_TASK", - "job_id": [NUMID], - "max_concurrent_runs": 1, - "name": "Test Auto-Migrate Job", - "queue": { - "enabled": true - }, - "run_as_user_name": "[USERNAME]", - "timeout_seconds": 0, - "webhook_notifications": {} - }, - "changes": { - "email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "name": { - "action": "update", - "old": "Test Auto-Migrate Job", - "new": "Test Auto-Migrate Job (renamed)", - "remote": "Test Auto-Migrate Job" - }, - "timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "webhook_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - } - } - } - } -} diff --git a/acceptance/bundle/migrate/auto-migrate-clean/out.test.toml b/acceptance/bundle/migrate/auto-migrate-clean/out.test.toml deleted file mode 100644 index bf0f576652e..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-clean/out.test.toml +++ /dev/null @@ -1,4 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] -EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/migrate/auto-migrate-clean/output.txt b/acceptance/bundle/migrate/auto-migrate-clean/output.txt deleted file mode 100644 index a358b635116..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-clean/output.txt +++ /dev/null @@ -1,71 +0,0 @@ - -=== Initial deploy uses terraform engine (no bundle.engine set, override via env var) ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created jobs.test_job -Files: 3 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged - ->>> print_migration_telemetry -direct_drymigrate_success true -direct_drymigrate_warnings false - -=== Opt in to direct engine via config and redeploy: dry-run is clean, auto-migration triggers ->>> update_file.py databricks.yml name: test-bundle name: test-bundle - engine: direct - ->>> [CLI] bundle deploy -Warn: Direct engine selected via bundle.engine setting at [TEST_TMP_DIR]/databricks.yml:3:11 but the existing state uses "terraform". Deploying on "terraform"; will attempt to migrate the state to the direct engine after this deploy. -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 1 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 1 unchanged -Migrating state to direct deployment engine (selected via bundle.engine setting at [TEST_TMP_DIR]/databricks.yml:3:11)... -Migrated 1 resource to direct deployment engine. - ->>> print_migration_telemetry -direct_migrated_via_config true - -=== Direct-engine state is now in place; terraform state is backed up - ->>> find .databricks/bundle -name resources.json -type f -.databricks/bundle/default/resources.json - ->>> find .databricks/bundle -name terraform.tfstate* -type f -.databricks/bundle/default/terraform/terraform.tfstate.backup - -=== Remote state also reflects the migration (force-pull surfaces workspace state) - ->>> [CLI] bundle debug states --force-pull -resources.json: remote direct state serial=3 lineage="[UUID]" -[TEST_TMP_DIR]/.databricks/bundle/default/resources.json: local direct state serial=3 lineage="[UUID]" - -=== Subsequent plan under direct is a no-op ->>> [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 1 unchanged - -=== Subsequent deploy under direct is a no-op ->>> [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 0 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 1 unchanged - ->>> print_migration_telemetry - -=== Modify the config — plan shows the pending update ->>> update_file.py databricks.yml Test Auto-Migrate Job Test Auto-Migrate Job (renamed) - ->>> [CLI] bundle plan -update jobs.test_job - -Plan: 0 to add, 1 to change, 0 to delete, 0 unchanged - -=== Deploy picks up the update (with and without --plan) -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Updated jobs.test_job -Files: 2 uploaded, 0 deleted -Resources: 0 created, 1 changed, 0 deleted, 0 unchanged - ->>> print_migration_telemetry - ->>> [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 1 unchanged diff --git a/acceptance/bundle/migrate/auto-migrate-clean/script b/acceptance/bundle/migrate/auto-migrate-clean/script deleted file mode 100644 index eb0b970ddc3..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-clean/script +++ /dev/null @@ -1,43 +0,0 @@ -export DATABRICKS_BUNDLE_ENGINE= - -# Each call to print_migration_telemetry inspects "$OUT_REQUESTS"; clear -# it after each call so the next deploy's telemetry stands alone. -title "Initial deploy uses terraform engine (no bundle.engine set, override via env var)" -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -title "Opt in to direct engine via config and redeploy: dry-run is clean, auto-migration triggers" -trace update_file.py databricks.yml "name: test-bundle" $'name: test-bundle\n engine: direct' -trace $CLI bundle deploy -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -title "Direct-engine state is now in place; terraform state is backed up\n" -trace find .databricks/bundle -name "resources.json" -type f -trace find .databricks/bundle -name "terraform.tfstate*" -type f - -title "Remote state also reflects the migration (force-pull surfaces workspace state)\n" -trace $CLI bundle debug states --force-pull - -title "Subsequent plan under direct is a no-op" -trace $CLI bundle plan | contains.py "1 unchanged" - -title "Subsequent deploy under direct is a no-op" -trace $CLI bundle deploy -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -title "Modify the config — plan shows the pending update" -trace update_file.py databricks.yml "Test Auto-Migrate Job" "Test Auto-Migrate Job (renamed)" -trace $CLI bundle plan -$CLI bundle plan -o json > out.plan_update.direct.json - -title "Deploy picks up the update (with and without --plan)\n" -$CLI bundle deploy $(readplanarg out.plan_update.direct.json) -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -trace $CLI bundle plan | contains.py "1 unchanged" - -rm -f "$OUT_REQUESTS" diff --git a/acceptance/bundle/migrate/auto-migrate-clean/test.toml b/acceptance/bundle/migrate/auto-migrate-clean/test.toml deleted file mode 100644 index 513685bc005..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-clean/test.toml +++ /dev/null @@ -1,5 +0,0 @@ -EnvMatrix.READPLAN = ["", "1"] - -# Migrating an existing deployment is not supported with deployment-history recording, so this -# test only runs without it (recording is covered by bundle/dms). -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/auto-migrate-default/databricks.yml b/acceptance/bundle/migrate/auto-migrate-default/databricks.yml deleted file mode 100644 index 7acc0c3576e..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-default/databricks.yml +++ /dev/null @@ -1,7 +0,0 @@ -bundle: - name: test-bundle - -resources: - jobs: - test_job: - name: "Test Auto-Migrate Job" diff --git a/acceptance/bundle/migrate/auto-migrate-default/out.test.toml b/acceptance/bundle/migrate/auto-migrate-default/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-default/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/auto-migrate-default/output.txt b/acceptance/bundle/migrate/auto-migrate-default/output.txt deleted file mode 100644 index 33950c186e3..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-default/output.txt +++ /dev/null @@ -1,50 +0,0 @@ - -=== Initial deploy opts out of direct, so it uses the terraform engine ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created jobs.test_job -Files: 2 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged - ->>> print_migration_telemetry -direct_drymigrate_success true -direct_drymigrate_warnings false - -=== Redeploy with nothing set: direct is the default, so auto-migration triggers ->>> [CLI] bundle deploy -Notice: the direct deployment engine is the default as of CLI v1.14.0. - -This bundle will be automatically migrated to use the direct deployment engine after this deployment. - -Learn more: https://docs.databricks.com/dev-tools/bundles/direct - -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 0 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 1 unchanged -Migrating state to direct deployment engine (selected via default)... -Migrated 1 resource to direct deployment engine. - ->>> print_migration_telemetry -direct_migrated_via_default true - -=== Direct-engine state is now in place; terraform state is backed up - ->>> find .databricks/bundle -name resources.json -type f -.databricks/bundle/default/resources.json - ->>> find .databricks/bundle -name terraform.tfstate* -type f -.databricks/bundle/default/terraform/terraform.tfstate.backup - -=== Remote state also reflects the migration (force-pull surfaces workspace state) - ->>> [CLI] bundle debug states --force-pull -resources.json: remote direct state serial=3 lineage="[UUID]" -[TEST_TMP_DIR]/.databricks/bundle/default/resources.json: local direct state serial=3 lineage="[UUID]" - -=== Subsequent deploy is a no-op on direct ->>> [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 0 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 1 unchanged - ->>> print_migration_telemetry diff --git a/acceptance/bundle/migrate/auto-migrate-default/script b/acceptance/bundle/migrate/auto-migrate-default/script deleted file mode 100644 index eb138273aff..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-default/script +++ /dev/null @@ -1,24 +0,0 @@ -export DATABRICKS_BUNDLE_ENGINE= - -title "Initial deploy opts out of direct, so it uses the terraform engine" -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -title "Redeploy with nothing set: direct is the default, so auto-migration triggers" -trace $CLI bundle deploy -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -title "Direct-engine state is now in place; terraform state is backed up\n" -trace find .databricks/bundle -name "resources.json" -type f -trace find .databricks/bundle -name "terraform.tfstate*" -type f - -title "Remote state also reflects the migration (force-pull surfaces workspace state)\n" -trace $CLI bundle debug states --force-pull - -title "Subsequent deploy is a no-op on direct" -trace $CLI bundle deploy -trace print_migration_telemetry - -rm -f "$OUT_REQUESTS" diff --git a/acceptance/bundle/migrate/auto-migrate-direct-only-envvar/databricks.yml b/acceptance/bundle/migrate/auto-migrate-direct-only-envvar/databricks.yml deleted file mode 100644 index 8f2a40d4f2b..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-direct-only-envvar/databricks.yml +++ /dev/null @@ -1,7 +0,0 @@ -bundle: - name: test-bundle - -resources: - #instance_pools: {pool: {instance_pool_name: "My Pool", node_type_id: "Standard_DS3_v2", idle_instance_autotermination_minutes: 60}} - jobs: - job_a: {name: "Job A"} diff --git a/acceptance/bundle/migrate/auto-migrate-direct-only-envvar/out.test.toml b/acceptance/bundle/migrate/auto-migrate-direct-only-envvar/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-direct-only-envvar/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/auto-migrate-direct-only-envvar/output.txt b/acceptance/bundle/migrate/auto-migrate-direct-only-envvar/output.txt deleted file mode 100644 index 527b9a89921..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-direct-only-envvar/output.txt +++ /dev/null @@ -1,54 +0,0 @@ - -=== Deploy with terraform (instance_pools is commented out; terraform cannot deploy it) ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created jobs.job_a -Files: 2 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged - -=== Add a direct-only resource to the config ->>> update_file.py databricks.yml #instance_pools instance_pools - -=== Opt in via env var only: deploy migrates the state, ignoring the direct-only resource ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle deploy -Warn: Direct engine selected via DATABRICKS_BUNDLE_ENGINE environment variable but the existing state uses "terraform". Deploying on "terraform"; will attempt to migrate the state to the direct engine after this deploy. -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 1 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 2 unchanged -Migrating state to direct deployment engine (selected via DATABRICKS_BUNDLE_ENGINE environment variable)... -Migrated 1 resource to direct deployment engine. - ->>> print_migration_telemetry -direct_migrated_via_env true - -=== The direct-only resource is created on the next deploy ->>> [CLI] bundle plan -create instance_pools.pool - -Plan: 1 to add, 0 to change, 0 to delete, 1 unchanged - ->>> [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created instance_pools.pool -Files: 0 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 1 unchanged - ->>> print_requests.py //instance-pools/create -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/direct auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.0/instance-pools/create", - "body": { - "idle_instance_autotermination_minutes": 60, - "instance_pool_name": "My Pool", - "node_type_id": "Standard_DS3_v2" - } -} - -=== No further actions planned ->>> [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 2 unchanged diff --git a/acceptance/bundle/migrate/auto-migrate-direct-only-envvar/script b/acceptance/bundle/migrate/auto-migrate-direct-only-envvar/script deleted file mode 100644 index 702cf582a3a..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-direct-only-envvar/script +++ /dev/null @@ -1,23 +0,0 @@ -export DATABRICKS_BUNDLE_ENGINE= - -title "Deploy with terraform (instance_pools is commented out; terraform cannot deploy it)" -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -rm -f "$OUT_REQUESTS" - -title "Add a direct-only resource to the config" -trace update_file.py databricks.yml "#instance_pools" "instance_pools" - -title "Opt in via env var only: deploy migrates the state, ignoring the direct-only resource" -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle deploy -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -title "The direct-only resource is created on the next deploy" -trace $CLI bundle plan -trace $CLI bundle deploy -trace print_requests.py //instance-pools/create - -title "No further actions planned" -trace $CLI bundle plan - -rm -f "$OUT_REQUESTS" diff --git a/acceptance/bundle/migrate/auto-migrate-direct-only/databricks.yml b/acceptance/bundle/migrate/auto-migrate-direct-only/databricks.yml deleted file mode 100644 index 8f2a40d4f2b..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-direct-only/databricks.yml +++ /dev/null @@ -1,7 +0,0 @@ -bundle: - name: test-bundle - -resources: - #instance_pools: {pool: {instance_pool_name: "My Pool", node_type_id: "Standard_DS3_v2", idle_instance_autotermination_minutes: 60}} - jobs: - job_a: {name: "Job A"} diff --git a/acceptance/bundle/migrate/auto-migrate-direct-only/out.test.toml b/acceptance/bundle/migrate/auto-migrate-direct-only/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-direct-only/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/auto-migrate-direct-only/output.txt b/acceptance/bundle/migrate/auto-migrate-direct-only/output.txt deleted file mode 100644 index 513b0254a18..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-direct-only/output.txt +++ /dev/null @@ -1,64 +0,0 @@ - -=== Deploy with terraform (instance_pools is commented out; terraform cannot deploy it) ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created jobs.job_a -Files: 2 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged - -=== Add a direct-only resource and opt in to the direct engine via config ->>> update_file.py databricks.yml #instance_pools instance_pools - ->>> update_file.py databricks.yml name: test-bundle name: test-bundle - engine: direct - -=== Plan skips the direct-only resource, since this run still uses terraform ->>> [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 2 unchanged - ->>> [CLI] bundle plan -o json -json.plan.resources.instance_pools.pool.action = "skip"; - -=== Deploy migrates the state, skipping the direct-only resource ->>> [CLI] bundle deploy -Warn: Direct engine selected via bundle.engine setting at [TEST_TMP_DIR]/databricks.yml:3:11 but the existing state uses "terraform". Deploying on "terraform"; will attempt to migrate the state to the direct engine after this deploy. -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 1 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 2 unchanged -Migrating state to direct deployment engine (selected via bundle.engine setting at [TEST_TMP_DIR]/databricks.yml:3:11)... -Migrated 1 resource to direct deployment engine. - ->>> print_migration_telemetry -direct_migrated_via_config true - -=== The direct-only resource is created on the next deploy ->>> [CLI] bundle plan -create instance_pools.pool - -Plan: 1 to add, 0 to change, 0 to delete, 1 unchanged - ->>> [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created instance_pools.pool -Files: 0 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 1 unchanged - ->>> print_requests.py //instance-pools/create -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/direct auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.0/instance-pools/create", - "body": { - "idle_instance_autotermination_minutes": 60, - "instance_pool_name": "My Pool", - "node_type_id": "Standard_DS3_v2" - } -} - -=== No further actions planned ->>> [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 2 unchanged diff --git a/acceptance/bundle/migrate/auto-migrate-direct-only/script b/acceptance/bundle/migrate/auto-migrate-direct-only/script deleted file mode 100644 index 0725c42d31c..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-direct-only/script +++ /dev/null @@ -1,28 +0,0 @@ -export DATABRICKS_BUNDLE_ENGINE= - -title "Deploy with terraform (instance_pools is commented out; terraform cannot deploy it)" -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -rm -f "$OUT_REQUESTS" - -title "Add a direct-only resource and opt in to the direct engine via config" -trace update_file.py databricks.yml "#instance_pools" "instance_pools" -trace update_file.py databricks.yml "name: test-bundle" $'name: test-bundle\n engine: direct' - -title "Plan skips the direct-only resource, since this run still uses terraform" -trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | gron.py | grep instance_pools - -title "Deploy migrates the state, skipping the direct-only resource" -trace $CLI bundle deploy -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -title "The direct-only resource is created on the next deploy" -trace $CLI bundle plan -trace $CLI bundle deploy -trace print_requests.py //instance-pools/create - -title "No further actions planned" -trace $CLI bundle plan - -rm -f "$OUT_REQUESTS" diff --git a/acceptance/bundle/migrate/auto-migrate-empty-tfstate/databricks.yml b/acceptance/bundle/migrate/auto-migrate-empty-tfstate/databricks.yml deleted file mode 100644 index bd74d8e74b9..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-empty-tfstate/databricks.yml +++ /dev/null @@ -1,3 +0,0 @@ -bundle: - name: test-bundle - engine: direct diff --git a/acceptance/bundle/migrate/auto-migrate-empty-tfstate/out.test.toml b/acceptance/bundle/migrate/auto-migrate-empty-tfstate/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-empty-tfstate/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/auto-migrate-empty-tfstate/output.txt b/acceptance/bundle/migrate/auto-migrate-empty-tfstate/output.txt deleted file mode 100644 index 06e544ad5fc..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-empty-tfstate/output.txt +++ /dev/null @@ -1,48 +0,0 @@ - -=== Deploy with bundle.engine: direct and an empty terraform state — sweep, don't migrate ->>> [CLI] bundle deploy -Warn: Direct engine selected via bundle.engine setting at [TEST_TMP_DIR]/databricks.yml:3:11 but the existing state uses "terraform". Deploying on "terraform"; will attempt to migrate the state to the direct engine after this deploy. -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 2 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 0 unchanged -Removing empty terraform state; direct engine will be used on the next deploy (selected via bundle.engine setting at [TEST_TMP_DIR]/databricks.yml:3:11)... - -=== Terraform state is renamed to .backup; no resources.json (empty state, nothing to persist) - ->>> find .databricks/bundle -name resources.json -type f - ->>> find .databricks/bundle -name terraform.tfstate* -type f -.databricks/bundle/default/terraform/terraform.tfstate.backup - -=== Sweep is recorded in telemetry as via-config - ->>> print_migration_telemetry -direct_migrated_via_config true - -=== Sweep also affected the workspace: .backup uploaded, terraform.tfstate deleted - ->>> print_requests.py //workspace-files/import-file //workspace/delete --sort -"POST /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files/databricks.yml" -"POST /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files/script" -"POST /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock" -"POST /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock" -"POST /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deployment.json" -"POST /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json" -"POST /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/terraform.tfstate" -"POST /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/terraform.tfstate.backup" -"POST /api/2.0/workspace/delete" -"POST /api/2.0/workspace/delete" -"POST /api/2.0/workspace/delete" - -=== debug states confirms no terraform.tfstate anywhere; only .backup remains - ->>> [CLI] bundle debug states --force-pull - - -=== Next deploy uses direct engine by default (no more mismatch warning) ->>> [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 0 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 0 unchanged - ->>> print_migration_telemetry diff --git a/acceptance/bundle/migrate/auto-migrate-empty-tfstate/script b/acceptance/bundle/migrate/auto-migrate-empty-tfstate/script deleted file mode 100644 index e72b1cadab4..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-empty-tfstate/script +++ /dev/null @@ -1,31 +0,0 @@ -# A terraform.tfstate with no databricks_* resources has no state to -# migrate. When the user has opted in to direct, sweep the empty terraform -# state aside (locally + remotely) so the next deploy picks the direct -# engine by default instead of getting stuck on a permanent mismatch warning. - -mkdir -p .databricks/bundle/default/terraform -cat > .databricks/bundle/default/terraform/terraform.tfstate <<'EOF' -{"version": 4, "serial": 1, "lineage": "test-lineage", "resources": []} -EOF - -title "Deploy with bundle.engine: direct and an empty terraform state — sweep, don't migrate" -trace $CLI bundle deploy 2>&1 | contains.py 'Removing empty terraform state' '!Migrating state to direct' - -title "Terraform state is renamed to .backup; no resources.json (empty state, nothing to persist)\n" -trace find .databricks/bundle -name "resources.json" -type f -trace find .databricks/bundle -name "terraform.tfstate*" -type f - -title "Sweep is recorded in telemetry as via-config\n" -trace print_migration_telemetry - -title "Sweep also affected the workspace: .backup uploaded, terraform.tfstate deleted\n" -trace print_requests.py //workspace-files/import-file //workspace/delete --sort | jq '.method + " " + .path' | contains.py 'terraform.tfstate.backup' 'workspace/delete' - -title "debug states confirms no terraform.tfstate anywhere; only .backup remains\n" -trace $CLI bundle debug states --force-pull - -title "Next deploy uses direct engine by default (no more mismatch warning)" -trace $CLI bundle deploy 2>&1 | contains.py '!does not match the existing state' -trace print_migration_telemetry - -rm -f "$OUT_REQUESTS" diff --git a/acceptance/bundle/migrate/auto-migrate-envvar/databricks.yml b/acceptance/bundle/migrate/auto-migrate-envvar/databricks.yml deleted file mode 100644 index 7acc0c3576e..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-envvar/databricks.yml +++ /dev/null @@ -1,7 +0,0 @@ -bundle: - name: test-bundle - -resources: - jobs: - test_job: - name: "Test Auto-Migrate Job" diff --git a/acceptance/bundle/migrate/auto-migrate-envvar/out.test.toml b/acceptance/bundle/migrate/auto-migrate-envvar/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-envvar/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/auto-migrate-envvar/output.txt b/acceptance/bundle/migrate/auto-migrate-envvar/output.txt deleted file mode 100644 index a0f04340420..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-envvar/output.txt +++ /dev/null @@ -1,37 +0,0 @@ - -=== Initial deploy uses terraform engine ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created jobs.test_job -Files: 2 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged - ->>> print_migration_telemetry -direct_drymigrate_success true -direct_drymigrate_warnings false - -=== Opt in via env var only (no bundle.engine in config): auto-migration triggers ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle deploy -Warn: Direct engine selected via DATABRICKS_BUNDLE_ENGINE environment variable but the existing state uses "terraform". Deploying on "terraform"; will attempt to migrate the state to the direct engine after this deploy. -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 0 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 1 unchanged -Migrating state to direct deployment engine (selected via DATABRICKS_BUNDLE_ENGINE environment variable)... -Migrated 1 resource to direct deployment engine. - ->>> print_migration_telemetry -direct_migrated_via_env true - -=== Direct-engine state is now in place; terraform state is backed up - ->>> find .databricks/bundle -name resources.json -type f -.databricks/bundle/default/resources.json - ->>> find .databricks/bundle -name terraform.tfstate* -type f -.databricks/bundle/default/terraform/terraform.tfstate.backup - -=== Remote state also reflects the migration (force-pull surfaces workspace state) - ->>> [CLI] bundle debug states --force-pull -resources.json: remote direct state serial=3 lineage="[UUID]" -[TEST_TMP_DIR]/.databricks/bundle/default/resources.json: local direct state serial=3 lineage="[UUID]" diff --git a/acceptance/bundle/migrate/auto-migrate-envvar/script b/acceptance/bundle/migrate/auto-migrate-envvar/script deleted file mode 100644 index 8377687a9b6..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-envvar/script +++ /dev/null @@ -1,20 +0,0 @@ -export DATABRICKS_BUNDLE_ENGINE= - -title "Initial deploy uses terraform engine" -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -title "Opt in via env var only (no bundle.engine in config): auto-migration triggers" -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle deploy -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -title "Direct-engine state is now in place; terraform state is backed up\n" -trace find .databricks/bundle -name "resources.json" -type f -trace find .databricks/bundle -name "terraform.tfstate*" -type f - -title "Remote state also reflects the migration (force-pull surfaces workspace state)\n" -trace $CLI bundle debug states --force-pull - -rm -f "$OUT_REQUESTS" diff --git a/acceptance/bundle/migrate/auto-migrate-plan-failure/databricks.yml b/acceptance/bundle/migrate/auto-migrate-plan-failure/databricks.yml deleted file mode 100644 index 8eed9482e74..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-plan-failure/databricks.yml +++ /dev/null @@ -1,7 +0,0 @@ -bundle: - name: test-bundle - -resources: - jobs: - test_job: - name: "Test Auto-Migrate Plan Failure" diff --git a/acceptance/bundle/migrate/auto-migrate-plan-failure/out.test.toml b/acceptance/bundle/migrate/auto-migrate-plan-failure/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-plan-failure/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/auto-migrate-plan-failure/output.txt b/acceptance/bundle/migrate/auto-migrate-plan-failure/output.txt deleted file mode 100644 index 410ec2b580e..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-plan-failure/output.txt +++ /dev/null @@ -1,55 +0,0 @@ - -=== Initial deploy on terraform ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created jobs.test_job -Files: 2 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged - ->>> print_migration_telemetry -direct_drymigrate_success true -direct_drymigrate_warnings false - -=== Inject GET failure so the plan check blocks the migration ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle deploy -Warn: Direct engine selected via DATABRICKS_BUNDLE_ENGINE environment variable but the existing state uses "terraform". Deploying on "terraform"; will attempt to migrate the state to the direct engine after this deploy. -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 0 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 1 unchanged -Warn: post-deploy dry-run migration to direct: cannot plan resources.jobs.test_job: reading id="[NUMID]": Fault injected by test. (403 INJECTED): Endpoint: GET [DATABRICKS_URL]/api/2.2/jobs/get?job_id=[NUMID] -HTTP Status: 403 Forbidden -API error_code: INJECTED -API message: Fault injected by test. -Warn: post-deploy dry-run migration to direct: planning failed -Warn: The warnings above are from a dry-run migration to the direct deployment engine (https://docs.databricks.com/aws/en/dev-tools/bundles/direct). -Your deployment is not affected and works normally, but you may experience these issues when migrating to the direct deployment engine. -Please forward these warnings to dabs-feedback@databricks.com -Warn: Direct engine was selected but the migration reported issues; automatic migration to the direct deployment engine is stopped. Address the issues above or run "databricks bundle deployment migrate" manually. - ->>> print_migration_telemetry -direct_migrate_plan_error true - -=== Local state was NOT rewritten (still terraform) ->>> find .databricks/bundle -name resources.json -type f - ->>> find .databricks/bundle -name terraform.tfstate* -type f -.databricks/bundle/default/terraform/terraform.tfstate - -=== Retry: plan check passes this time, migration succeeds ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle deploy -Warn: Direct engine selected via DATABRICKS_BUNDLE_ENGINE environment variable but the existing state uses "terraform". Deploying on "terraform"; will attempt to migrate the state to the direct engine after this deploy. -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 0 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 1 unchanged -Migrating state to direct deployment engine (selected via DATABRICKS_BUNDLE_ENGINE environment variable)... -Migrated 1 resource to direct deployment engine. - ->>> print_migration_telemetry -direct_migrated_via_env true - -=== Local state is now direct ->>> find .databricks/bundle -name resources.json -type f -.databricks/bundle/default/resources.json - ->>> find .databricks/bundle -name terraform.tfstate* -type f -.databricks/bundle/default/terraform/terraform.tfstate.backup diff --git a/acceptance/bundle/migrate/auto-migrate-plan-failure/script b/acceptance/bundle/migrate/auto-migrate-plan-failure/script deleted file mode 100644 index 0e2e2ead7ed..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-plan-failure/script +++ /dev/null @@ -1,32 +0,0 @@ -export DATABRICKS_BUNDLE_ENGINE= - -title "Initial deploy on terraform" -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -title "Inject GET failure so the plan check blocks the migration" -# The plan check calls GET /api/2.2/jobs/get for each resource to compare -# local config against remote state. A 403 (non-retryable) causes the plan -# to fail → the migration is abandoned and the bundle stays on terraform. -# OFFSET=1: terraform reads the job once during its plan phase; skip that -# call and fail the 2nd one, which is the plan check's DoRead. -fault.py "GET /api/2.2/jobs/get*" 403 1 1 -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle deploy -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -title "Local state was NOT rewritten (still terraform)" -trace find .databricks/bundle -name "resources.json" -type f -trace find .databricks/bundle -name "terraform.tfstate*" -type f - -title "Retry: plan check passes this time, migration succeeds" -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle deploy -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -title "Local state is now direct" -trace find .databricks/bundle -name "resources.json" -type f -trace find .databricks/bundle -name "terraform.tfstate*" -type f - -rm -f "$OUT_REQUESTS" diff --git a/acceptance/bundle/migrate/auto-migrate-push-failure/databricks.yml b/acceptance/bundle/migrate/auto-migrate-push-failure/databricks.yml deleted file mode 100644 index a07dda12a16..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-push-failure/databricks.yml +++ /dev/null @@ -1,7 +0,0 @@ -bundle: - name: test-bundle - -resources: - jobs: - test_job: - name: "Test Auto-Migrate Push Failure" diff --git a/acceptance/bundle/migrate/auto-migrate-push-failure/out.test.toml b/acceptance/bundle/migrate/auto-migrate-push-failure/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-push-failure/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/auto-migrate-push-failure/output.txt b/acceptance/bundle/migrate/auto-migrate-push-failure/output.txt deleted file mode 100644 index cf125b4bd74..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-push-failure/output.txt +++ /dev/null @@ -1,50 +0,0 @@ - -=== Initial deploy on terraform ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created jobs.test_job -Files: 2 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged - ->>> print_migration_telemetry -direct_drymigrate_success true -direct_drymigrate_warnings false - -=== Opt in via env var; inject 403 on the resources.json push so commit fails ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle deploy -Warn: Direct engine selected via DATABRICKS_BUNDLE_ENGINE environment variable but the existing state uses "terraform". Deploying on "terraform"; will attempt to migrate the state to the direct engine after this deploy. -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 0 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 1 unchanged -Migrating state to direct deployment engine (selected via DATABRICKS_BUNDLE_ENGINE environment variable)... -Warn: automatic migration to direct engine failed: pushing direct state to workspace: access denied: /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/resources.json - ->>> print_migration_telemetry -direct_migrate_commit_error true - -=== Local state was NOT rewritten (still terraform) - ->>> find .databricks/bundle -name resources.json -type f - ->>> find .databricks/bundle -name terraform.tfstate* -type f -.databricks/bundle/default/terraform/terraform.tfstate - -=== Retry: auto-migration succeeds this time ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle deploy -Warn: Direct engine selected via DATABRICKS_BUNDLE_ENGINE environment variable but the existing state uses "terraform". Deploying on "terraform"; will attempt to migrate the state to the direct engine after this deploy. -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 0 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 1 unchanged -Migrating state to direct deployment engine (selected via DATABRICKS_BUNDLE_ENGINE environment variable)... -Migrated 1 resource to direct deployment engine. - ->>> print_migration_telemetry -direct_migrated_via_env true - -=== Local state is now direct - ->>> find .databricks/bundle -name resources.json -type f -.databricks/bundle/default/resources.json - ->>> find .databricks/bundle -name terraform.tfstate* -type f -.databricks/bundle/default/terraform/terraform.tfstate.backup diff --git a/acceptance/bundle/migrate/auto-migrate-push-failure/script b/acceptance/bundle/migrate/auto-migrate-push-failure/script deleted file mode 100644 index 283398867c7..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-push-failure/script +++ /dev/null @@ -1,30 +0,0 @@ -export DATABRICKS_BUNDLE_ENGINE= - -title "Initial deploy on terraform" -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -title "Opt in via env var; inject 403 on the resources.json push so commit fails" -# The auto-migration's commit path uploads resources.json to the workspace -# before renaming any local files. A 403 (non-retryable) fails commitMigration → -# the deploy prints a warning and leaves the local state as terraform. -fault.py "POST /api/2.0/workspace-files/import-file/Workspace/Users/$CURRENT_USER_NAME/.bundle/test-bundle/default/state/resources.json" 403 0 1 -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle deploy -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -title "Local state was NOT rewritten (still terraform)\n" -trace find .databricks/bundle -name "resources.json" -type f -trace find .databricks/bundle -name "terraform.tfstate*" -type f - -title "Retry: auto-migration succeeds this time" -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle deploy -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -title "Local state is now direct\n" -trace find .databricks/bundle -name "resources.json" -type f -trace find .databricks/bundle -name "terraform.tfstate*" -type f - -rm -f "$OUT_REQUESTS" diff --git a/acceptance/bundle/migrate/auto-migrate-tfbackup-failure/databricks.yml b/acceptance/bundle/migrate/auto-migrate-tfbackup-failure/databricks.yml deleted file mode 100644 index a16d144b0c9..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-tfbackup-failure/databricks.yml +++ /dev/null @@ -1,7 +0,0 @@ -bundle: - name: test-bundle - -resources: - jobs: - test_job: - name: "Test Auto-Migrate Backup Failure" diff --git a/acceptance/bundle/migrate/auto-migrate-tfbackup-failure/out.test.toml b/acceptance/bundle/migrate/auto-migrate-tfbackup-failure/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-tfbackup-failure/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/auto-migrate-tfbackup-failure/output.txt b/acceptance/bundle/migrate/auto-migrate-tfbackup-failure/output.txt deleted file mode 100644 index ac27fccbf49..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-tfbackup-failure/output.txt +++ /dev/null @@ -1,46 +0,0 @@ - -=== Initial deploy on terraform ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created jobs.test_job -Files: 2 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged - ->>> print_migration_telemetry -direct_drymigrate_success true -direct_drymigrate_warnings false - -=== Opt in via env var; inject 403 on the DELETE of remote terraform.tfstate ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle deploy -Warn: Direct engine selected via DATABRICKS_BUNDLE_ENGINE environment variable but the existing state uses "terraform". Deploying on "terraform"; will attempt to migrate the state to the direct engine after this deploy. -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 0 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 1 unchanged -Migrating state to direct deployment engine (selected via DATABRICKS_BUNDLE_ENGINE environment variable)... -Warn: automatic migration to direct engine failed: pushing direct state to workspace: deleting remote terraform state: Fault injected by test. - ->>> print_migration_telemetry -direct_migrate_commit_error true - -=== Local state was NOT rewritten (still terraform) - ->>> find .databricks/bundle -name resources.json -type f - ->>> find .databricks/bundle -name terraform.tfstate* -type f -.databricks/bundle/default/terraform/terraform.tfstate - -=== Retry recovers: subsequent deploy re-does the backup and completes ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 0 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 1 unchanged - ->>> print_migration_telemetry - -=== Local state is now direct - ->>> find .databricks/bundle -name resources.json -type f -.databricks/bundle/default/resources.json - ->>> find .databricks/bundle -name terraform.tfstate* -type f -.databricks/bundle/default/terraform/terraform.tfstate diff --git a/acceptance/bundle/migrate/auto-migrate-tfbackup-failure/script b/acceptance/bundle/migrate/auto-migrate-tfbackup-failure/script deleted file mode 100644 index 426ee04a73b..00000000000 --- a/acceptance/bundle/migrate/auto-migrate-tfbackup-failure/script +++ /dev/null @@ -1,32 +0,0 @@ -export DATABRICKS_BUNDLE_ENGINE= - -title "Initial deploy on terraform" -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -title "Opt in via env var; inject 403 on the DELETE of remote terraform.tfstate" -# resources.json is uploaded successfully; then we back up terraform.tfstate to -# .backup and delete the original. Fault the second workspace/delete call -# (skipping the first one, which is the deploy's own artifacts cleanup) to -# fail the terraform.tfstate delete. The migration must surface a -# commit-error warning; the local state stays terraform. -fault.py "POST /api/2.0/workspace/delete" 403 1 1 -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle deploy -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -title "Local state was NOT rewritten (still terraform)\n" -trace find .databricks/bundle -name "resources.json" -type f -trace find .databricks/bundle -name "terraform.tfstate*" -type f - -title "Retry recovers: subsequent deploy re-does the backup and completes" -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle deploy -trace print_migration_telemetry -rm -f "$OUT_REQUESTS" - -title "Local state is now direct\n" -trace find .databricks/bundle -name "resources.json" -type f -trace find .databricks/bundle -name "terraform.tfstate*" -type f - -rm -f "$OUT_REQUESTS" diff --git a/acceptance/bundle/migrate/basic/databricks.yml b/acceptance/bundle/migrate/basic/databricks.yml deleted file mode 100644 index bad48e82d67..00000000000 --- a/acceptance/bundle/migrate/basic/databricks.yml +++ /dev/null @@ -1,47 +0,0 @@ -bundle: - name: migrate-basic-test - -resources: - jobs: - test_job: - name: "Test Migration Job" - tasks: - - task_key: "main" - notebook_task: - notebook_path: "./notebook.py" - volumes: - test_volume: - catalog_name: "mycat" - schema_name: "myschema" - name: "myvol" - - pipelines: - test_pipeline: - name: "Test Migration Pipeline" - tags: - # ids - myjob_id: ${resources.jobs.test_job.id} - myvolume_id: ${resources.volumes.test_volume.id} - - # local field, string: - myjob_name: ${resources.jobs.test_job.name} - volume_catalog_name: ${resources.volumes.test_volume.catalog_name} - - # remote field, int - myjob_timeout: ${resources.jobs.test_job.timeout_seconds} - - # remote field, string: - volume_storage_location: ${resources.volumes.test_volume.storage_location} - libraries: - - notebook: - path: "./pipeline.py" - -targets: - dev: - default: true - prod: - resources: - schemas: - test_schema: - catalog_name: mycat - name: myschema diff --git a/acceptance/bundle/migrate/basic/notebook.py b/acceptance/bundle/migrate/basic/notebook.py deleted file mode 100644 index 250b3c9f766..00000000000 --- a/acceptance/bundle/migrate/basic/notebook.py +++ /dev/null @@ -1,2 +0,0 @@ -# Databricks notebook source -print("Hello from test migration job") diff --git a/acceptance/bundle/migrate/basic/out.new_state.json b/acceptance/bundle/migrate/basic/out.new_state.json deleted file mode 100644 index e924cb4d005..00000000000 --- a/acceptance/bundle/migrate/basic/out.new_state.json +++ /dev/null @@ -1,94 +0,0 @@ -{ - "state_version": 3, - "cli_version": "[CLI_VERSION]", - "lineage": "[UUID]", - "serial": 6, - "state": { - "resources.jobs.test_job": { - "__id__": "[NUMID]", - "state": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "Test Migration Job", - "queue": { - "enabled": true - }, - "tasks": [ - { - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/files/notebook" - }, - "task_key": "main" - } - ] - } - }, - "resources.pipelines.test_pipeline": { - "__id__": "[UUID]", - "state": { - "channel": "CURRENT", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/state/metadata.json" - }, - "edition": "ADVANCED", - "libraries": [ - { - "notebook": { - "path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/files/pipeline" - } - } - ], - "name": "Test Migration Pipeline", - "tags": { - "myjob_id": "[NUMID]", - "myjob_name": "Test Migration Job", - "myjob_timeout": "0", - "myvolume_id": "mycat.myschema.myvol", - "volume_catalog_name": "mycat", - "volume_storage_location": "s3://[METASTORE_NAME]/metastore/[UUID]/volumes/[UUID]" - } - }, - "depends_on": [ - { - "node": "resources.jobs.test_job", - "label": "${resources.jobs.test_job.id}" - }, - { - "node": "resources.jobs.test_job", - "label": "${resources.jobs.test_job.name}" - }, - { - "node": "resources.jobs.test_job", - "label": "${resources.jobs.test_job.timeout_seconds}" - }, - { - "node": "resources.volumes.test_volume", - "label": "${resources.volumes.test_volume.catalog_name}" - }, - { - "node": "resources.volumes.test_volume", - "label": "${resources.volumes.test_volume.id}" - }, - { - "node": "resources.volumes.test_volume", - "label": "${resources.volumes.test_volume.storage_location}" - } - ] - }, - "resources.volumes.test_volume": { - "__id__": "mycat.myschema.myvol", - "state": { - "catalog_name": "mycat", - "name": "myvol", - "schema_name": "myschema", - "volume_type": "MANAGED" - } - } - } -} diff --git a/acceptance/bundle/migrate/basic/out.original_state.json b/acceptance/bundle/migrate/basic/out.original_state.json deleted file mode 100644 index 147893321a1..00000000000 --- a/acceptance/bundle/migrate/basic/out.original_state.json +++ /dev/null @@ -1,291 +0,0 @@ -{ - "version": 4, - "terraform_version": "1.5.5", - "serial": 4, - "lineage": "[UUID]", - "outputs": {}, - "resources": [ - { - "mode": "managed", - "type": "databricks_job", - "name": "test_job", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 2, - "attributes": { - "always_running": false, - "budget_policy_id": null, - "continuous": [], - "control_run_state": false, - "dbt_task": [], - "deployment": [ - { - "deployment_id": "", - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/state/metadata.json", - "version_id": "" - } - ], - "description": null, - "edit_mode": "UI_LOCKED", - "email_notifications": [ - { - "no_alert_for_skipped_runs": false, - "on_duration_warning_threshold_exceeded": [], - "on_failure": [], - "on_start": [], - "on_streaming_backlog_exceeded": [], - "on_success": [] - } - ], - "environment": [], - "existing_cluster_id": null, - "format": "MULTI_TASK", - "git_source": [], - "health": [], - "id": "[NUMID]", - "job_cluster": [], - "library": [], - "max_concurrent_runs": 1, - "max_retries": 0, - "min_retry_interval_millis": 0, - "name": "Test Migration Job", - "new_cluster": [], - "notebook_task": [], - "notification_settings": [], - "parameter": [], - "parent_path": null, - "performance_target": null, - "pipeline_task": [], - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "python_wheel_task": [], - "queue": [ - { - "enabled": true - } - ], - "retry_on_timeout": false, - "run_as": [ - { - "group_name": "", - "service_principal_name": "", - "user_name": "[USERNAME]" - } - ], - "run_job_task": [], - "schedule": [], - "spark_jar_task": [], - "spark_python_task": [], - "spark_submit_task": [], - "tags": null, - "task": [ - { - "ai_runtime_task": [], - "alert_task": [], - "clean_rooms_notebook_task": [], - "compute": [], - "condition_task": [], - "dashboard_task": [], - "dbt_cloud_task": [], - "dbt_platform_task": [], - "dbt_task": [], - "depends_on": [], - "description": "", - "disable_auto_optimization": false, - "disabled": false, - "email_notifications": [ - { - "no_alert_for_skipped_runs": false, - "on_duration_warning_threshold_exceeded": [], - "on_failure": [], - "on_start": [], - "on_streaming_backlog_exceeded": [], - "on_success": [] - } - ], - "environment_key": "", - "existing_cluster_id": "", - "for_each_task": [], - "gen_ai_compute_task": [], - "health": [], - "job_cluster_key": "", - "library": [], - "max_retries": 0, - "min_retry_interval_millis": 0, - "new_cluster": [], - "notebook_task": [ - { - "base_parameters": null, - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/files/notebook", - "source": "WORKSPACE", - "warehouse_id": "" - } - ], - "notification_settings": [], - "pipeline_task": [], - "power_bi_task": [], - "python_operator_task": [], - "python_wheel_task": [], - "retry_on_timeout": false, - "run_if": "ALL_SUCCESS", - "run_job_task": [], - "spark_jar_task": [], - "spark_python_task": [], - "spark_submit_task": [], - "sql_task": [], - "task_key": "main", - "timeout_seconds": 0, - "webhook_notifications": [] - } - ], - "timeout_seconds": 0, - "timeouts": null, - "trigger": [], - "triggers": [], - "url": "[DATABRICKS_URL]/#job/[NUMID]", - "usage_policy_id": null, - "webhook_notifications": [ - { - "on_duration_warning_threshold_exceeded": [], - "on_failure": [], - "on_start": [], - "on_streaming_backlog_exceeded": [], - "on_success": [] - } - ] - }, - "sensitive_attributes": [], - "private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxODAwMDAwMDAwMDAwLCJ1cGRhdGUiOjE4MDAwMDAwMDAwMDB9LCJzY2hlbWFfdmVyc2lvbiI6IjIifQ==" - } - ] - }, - { - "mode": "managed", - "type": "databricks_pipeline", - "name": "test_pipeline", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 0, - "attributes": { - "allow_duplicate_names": false, - "budget_policy_id": null, - "catalog": null, - "cause": null, - "channel": "CURRENT", - "cluster": [], - "cluster_id": null, - "configuration": null, - "continuous": false, - "creator_user_name": "[USERNAME]", - "deployment": [ - { - "deployment_id": "", - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/state/metadata.json", - "version_id": "" - } - ], - "development": false, - "edition": "ADVANCED", - "environment": [], - "event_log": [], - "expected_last_modified": 0, - "filters": [], - "gateway_definition": [], - "health": null, - "id": "[UUID]", - "ingestion_definition": [], - "last_modified": [UNIX_TIME_MILLIS], - "latest_updates": null, - "library": [ - { - "file": [], - "glob": [], - "jar": "", - "maven": [], - "notebook": [ - { - "path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/files/pipeline" - } - ], - "whl": "" - } - ], - "name": "Test Migration Pipeline", - "notification": [], - "photon": false, - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "restart_window": [], - "root_path": null, - "run_as": [], - "run_as_user_name": "[USERNAME]", - "schema": null, - "serverless": false, - "serverless_compute_id": null, - "state": "IDLE", - "storage": "dbfs:/pipelines/[UUID]", - "tags": { - "myjob_id": "[NUMID]", - "myjob_name": "Test Migration Job", - "myjob_timeout": "0", - "myvolume_id": "mycat.myschema.myvol", - "volume_catalog_name": "mycat", - "volume_storage_location": "s3://[METASTORE_NAME]/metastore/[UUID]/volumes/[UUID]" - }, - "target": null, - "timeouts": null, - "trigger": [], - "url": "[DATABRICKS_URL]/#joblist/pipelines/[UUID]", - "usage_policy_id": null - }, - "sensitive_attributes": [], - "private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWZhdWx0IjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjEyMDAwMDAwMDAwMDAsInVwZGF0ZSI6MTIwMDAwMDAwMDAwMH19", - "dependencies": [ - "databricks_job.test_job", - "databricks_volume.test_volume" - ] - } - ] - }, - { - "mode": "managed", - "type": "databricks_volume", - "name": "test_volume", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 0, - "attributes": { - "catalog_name": "mycat", - "comment": null, - "id": "mycat.myschema.myvol", - "name": "myvol", - "owner": "[USERNAME]", - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "schema_name": "myschema", - "storage_location": "s3://[METASTORE_NAME]/metastore/[UUID]/volumes/[UUID]", - "volume_path": "/Volumes/mycat/myschema/myvol", - "volume_type": "MANAGED" - }, - "sensitive_attributes": [], - "private": "bnVsbA==" - } - ] - } - ], - "check_results": null -} diff --git a/acceptance/bundle/migrate/basic/out.plan_update.json b/acceptance/bundle/migrate/basic/out.plan_update.json deleted file mode 100644 index 02aa38f21c5..00000000000 --- a/acceptance/bundle/migrate/basic/out.plan_update.json +++ /dev/null @@ -1,247 +0,0 @@ -{ - "plan_version": [PLAN_VERSION], - "cli_version": "[CLI_VERSION]", - "lineage": "[UUID]", - "serial": 6, - "plan": { - "resources.jobs.test_job": { - "action": "update", - "new_state": { - "value": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "Test Migrated Job", - "queue": { - "enabled": true - }, - "tasks": [ - { - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/files/notebook" - }, - "task_key": "main" - } - ] - } - }, - "remote_state": { - "created_time": [UNIX_TIME_MILLIS][0], - "creator_user_name": "[USERNAME]", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "email_notifications": {}, - "format": "MULTI_TASK", - "job_id": [NUMID], - "max_concurrent_runs": 1, - "name": "Test Migration Job", - "queue": { - "enabled": true - }, - "run_as_user_name": "[USERNAME]", - "tasks": [ - { - "email_notifications": {}, - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/files/notebook", - "source": "WORKSPACE" - }, - "run_if": "ALL_SUCCESS", - "task_key": "main", - "timeout_seconds": 0 - } - ], - "timeout_seconds": 0, - "webhook_notifications": {} - }, - "changes": { - "email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "name": { - "action": "update", - "old": "Test Migration Job", - "new": "Test Migrated Job", - "remote": "Test Migration Job" - }, - "tasks[task_key='main'].email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "tasks[task_key='main'].notebook_task.source": { - "action": "skip", - "reason": "backend_default", - "remote": "WORKSPACE" - }, - "tasks[task_key='main'].run_if": { - "action": "skip", - "reason": "backend_default", - "remote": "ALL_SUCCESS" - }, - "tasks[task_key='main'].timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "webhook_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - } - } - }, - "resources.pipelines.test_pipeline": { - "depends_on": [ - { - "node": "resources.jobs.test_job", - "label": "${resources.jobs.test_job.id}" - }, - { - "node": "resources.jobs.test_job", - "label": "${resources.jobs.test_job.name}" - }, - { - "node": "resources.jobs.test_job", - "label": "${resources.jobs.test_job.timeout_seconds}" - }, - { - "node": "resources.volumes.test_volume", - "label": "${resources.volumes.test_volume.catalog_name}" - }, - { - "node": "resources.volumes.test_volume", - "label": "${resources.volumes.test_volume.id}" - }, - { - "node": "resources.volumes.test_volume", - "label": "${resources.volumes.test_volume.storage_location}" - } - ], - "action": "update", - "new_state": { - "value": { - "channel": "CURRENT", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/state/metadata.json" - }, - "edition": "ADVANCED", - "libraries": [ - { - "notebook": { - "path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/files/pipeline" - } - } - ], - "name": "Test Migrated Pipeline", - "tags": { - "myjob_id": "[NUMID]", - "myjob_name": "Test Migrated Job", - "myjob_timeout": "${resources.jobs.test_job.timeout_seconds}", - "myvolume_id": "mycat.myschema.myvol", - "volume_catalog_name": "mycat", - "volume_storage_location": "s3://[METASTORE_NAME]/metastore/[UUID]/volumes/[UUID]" - } - }, - "vars": { - "tags.myjob_timeout": "${resources.jobs.test_job.timeout_seconds}" - } - }, - "remote_state": { - "channel": "CURRENT", - "creator_user_name": "[USERNAME]", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/state/metadata.json" - }, - "edition": "ADVANCED", - "effective_publishing_mode": "DEFAULT_PUBLISHING_MODE", - "id": "[UUID]", - "last_modified": [UNIX_TIME_MILLIS][1], - "libraries": [ - { - "notebook": { - "path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/files/pipeline" - } - } - ], - "name": "Test Migration Pipeline", - "pipeline_id": "[UUID]", - "run_as_user_name": "[USERNAME]", - "state": "IDLE", - "storage": "dbfs:/pipelines/[UUID]", - "tags": { - "myjob_id": "[NUMID]", - "myjob_name": "Test Migration Job", - "myjob_timeout": "0", - "myvolume_id": "mycat.myschema.myvol", - "volume_catalog_name": "mycat", - "volume_storage_location": "s3://[METASTORE_NAME]/metastore/[UUID]/volumes/[UUID]" - } - }, - "changes": { - "name": { - "action": "update", - "old": "Test Migration Pipeline", - "new": "Test Migrated Pipeline", - "remote": "Test Migration Pipeline" - }, - "storage": { - "action": "skip", - "reason": "backend_default", - "remote": "dbfs:/pipelines/[UUID]" - }, - "tags['myjob_name']": { - "action": "update", - "old": "Test Migration Job", - "new": "Test Migrated Job", - "remote": "Test Migration Job" - }, - "tags['myjob_timeout']": { - "action": "update", - "old": "0", - "new": "${resources.jobs.test_job.timeout_seconds}", - "remote": "0" - } - } - }, - "resources.volumes.test_volume": { - "action": "skip", - "remote_state": { - "catalog_name": "mycat", - "created_at": [UNIX_TIME_MILLIS][2], - "created_by": "[USERNAME]", - "full_name": "mycat.myschema.myvol", - "name": "myvol", - "owner": "[USERNAME]", - "schema_name": "myschema", - "storage_location": "s3://[METASTORE_NAME]/metastore/[UUID]/volumes/[UUID]", - "updated_at": [UNIX_TIME_MILLIS][2], - "volume_id": "[UUID]", - "volume_type": "MANAGED" - }, - "changes": { - "storage_location": { - "action": "skip", - "reason": "backend_default", - "remote": "s3://[METASTORE_NAME]/metastore/[UUID]/volumes/[UUID]" - } - } - } - } -} diff --git a/acceptance/bundle/migrate/basic/out.test.toml b/acceptance/bundle/migrate/basic/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/basic/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/basic/output.txt b/acceptance/bundle/migrate/basic/output.txt deleted file mode 100644 index eaaf8daa73e..00000000000 --- a/acceptance/bundle/migrate/basic/output.txt +++ /dev/null @@ -1,133 +0,0 @@ - ->>> musterr [CLI] bundle deployment migrate -Error: This command migrates the existing Terraform state file (terraform.tfstate) to a direct deployment state file (resources.json). However, no existing local or remote state was found. - -To start using direct engine, set "engine: direct" under bundle in your databricks.yml or deploy with DATABRICKS_BUNDLE_ENGINE=direct env var set. - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/files... -Created jobs.test_job -Created pipelines.test_pipeline -Created volumes.test_volume -Files: 5 uploaded, 0 deleted -Resources: 3 created, 0 changed, 0 deleted, 0 unchanged - ->>> [CLI] bundle deployment migrate -Success! Migrated 3 resources to direct engine state file: [TEST_TMP_DIR]/.databricks/bundle/dev/resources.json - -Validate the migration by running "databricks bundle plan", there should be no actions planned. - -The state file is not synchronized to the workspace yet. To do that and finalize the migration, run "bundle deploy". - -To undo the migration, remove [TEST_TMP_DIR]/.databricks/bundle/dev/resources.json and rename [TEST_TMP_DIR]/.databricks/bundle/dev/terraform/terraform.tfstate.backup to [TEST_TMP_DIR]/.databricks/bundle/dev/terraform/terraform.tfstate - - ->>> diff out.original_state.json out.backup_state.json - ->>> jq .state."resources.pipelines.test_pipeline".state.tags.volume_storage_location out.new_state.json -"s3://[METASTORE_NAME]/metastore/[UUID]/volumes/[UUID]" - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 3 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/files... -Files: 2 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 3 unchanged - -=== Should show that it's already migrated ->>> musterr [CLI] bundle deployment migrate -Error: already using direct engine -Details: [TEST_TMP_DIR]/.databricks/bundle/dev/resources.json: local direct state serial=6 lineage="[UUID]" - ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 3 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 3 unchanged - ->>> print_requests.py --get //jobs/get -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none engine/direct auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.2/jobs/get", - "q": { - "job_id": "[NUMID]" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none engine/direct auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.2/jobs/get", - "q": { - "job_id": "[NUMID]" - } -} - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/files... -Files: 0 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 3 unchanged - ->>> print_requests.py --get //jobs/get -"cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/direct auth/pat" -"cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/direct auth/pat" - -=== Should show that it's already migrated ->>> musterr [CLI] bundle deployment migrate -Error: already using direct engine -Details: [TEST_TMP_DIR]/.databricks/bundle/dev/resources.json: local direct state serial=6 lineage="[UUID]" - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle debug states -[TEST_TMP_DIR]/.databricks/bundle/dev/resources.json: local direct state serial=6 lineage="[UUID]" - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle debug states --force-pull -resources.json: remote direct state serial=6 lineage="[UUID]" -[TEST_TMP_DIR]/.databricks/bundle/dev/resources.json: local direct state serial=6 lineage="[UUID]" - -=== Extra plan: should have no drift ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 3 unchanged - -=== Update databricks.yml, run plan & update ->>> update_file.py databricks.yml Migration Migrated - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle plan -update jobs.test_job -update pipelines.test_pipeline - -Plan: 0 to add, 2 to change, 0 to delete, 1 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle plan -o json - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/files... -Updated jobs.test_job -Updated pipelines.test_pipeline -Files: 2 uploaded, 0 deleted -Resources: 0 created, 2 changed, 0 deleted, 1 unchanged - -=== Different target, still on terraform ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -t prod -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/prod/files... -Created jobs.test_job -Created pipelines.test_pipeline -Created schemas.test_schema -Created volumes.test_volume -Files: 8 uploaded, 0 deleted -Resources: 4 created, 0 changed, 0 deleted, 0 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle debug states -t prod -[TEST_TMP_DIR]/.databricks/bundle/prod/terraform/terraform.tfstate: local terraform state serial=5 lineage="[UUID]" - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle debug states -t prod --force-pull -terraform.tfstate: remote terraform state serial=5 lineage="[UUID]" -[TEST_TMP_DIR]/.databricks/bundle/prod/terraform/terraform.tfstate: local terraform state serial=5 lineage="[UUID]" diff --git a/acceptance/bundle/migrate/basic/pipeline.py b/acceptance/bundle/migrate/basic/pipeline.py deleted file mode 100644 index cd19031e962..00000000000 --- a/acceptance/bundle/migrate/basic/pipeline.py +++ /dev/null @@ -1,2 +0,0 @@ -# Databricks notebook source -# This is a test pipeline notebook diff --git a/acceptance/bundle/migrate/basic/script b/acceptance/bundle/migrate/basic/script deleted file mode 100755 index a9944a5a4d8..00000000000 --- a/acceptance/bundle/migrate/basic/script +++ /dev/null @@ -1,54 +0,0 @@ -export DATABRICKS_BUNDLE_ENGINE= -# Migrating without state, should print a message about missing state. -trace musterr $CLI bundle deployment migrate - -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -print_state.py -t dev > out.original_state.json - -trace $CLI bundle deployment migrate 2>&1 | contains.py 'Migrated 3 resources' -print_state.py -t dev > out.new_state.json -print_state.py -t dev --backup > out.backup_state.json -trace diff out.original_state.json out.backup_state.json -rm out.backup_state.json - -# check that this is stored as resolved value, not as reference: -trace jq '.state."resources.pipelines.test_pipeline".state.tags.volume_storage_location' out.new_state.json | contains.py 's3://' - -# this is expected to warn because state does not match env var, but still succeed using state engine -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle plan -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy - -title "Should show that it's already migrated" -trace musterr $CLI bundle deployment migrate - -rm "$OUT_REQUESTS" -# Both DATABRICKS_BUNDLE_ENGINE=direct and DATABRICKS_BUNDLE_ENGINE= work -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle plan | contains.py "3 unchanged" -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle plan | contains.py "3 unchanged" -trace print_requests.py --get //jobs/get | contains.py 'engine/direct' - -trace DATABRICKS_BUNDLE_ENGINE="" $CLI bundle deploy -trace print_requests.py --get //jobs/get | jq '.headers["User-Agent"][0]' | contains.py 'engine/direct' - -title "Should show that it's already migrated" -trace musterr $CLI bundle deployment migrate -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle debug states -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle debug states --force-pull - -title "Extra plan: should have no drift" -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle plan | contains.py "3 unchanged" - -rm "$OUT_REQUESTS" - -title "Update databricks.yml, run plan & update" -trace update_file.py databricks.yml Migration Migrated -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle plan -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle plan -o json | nostamp > out.plan_update.json -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle deploy - -title "Different target, still on terraform" -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -t prod -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle debug states -t prod -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle debug states -t prod --force-pull - -rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/migrate/basic/test.toml b/acceptance/bundle/migrate/basic/test.toml deleted file mode 100644 index e25c2749483..00000000000 --- a/acceptance/bundle/migrate/basic/test.toml +++ /dev/null @@ -1,2 +0,0 @@ -RecordRequests = true -IncludeRequestHeaders = ["User-Agent"] diff --git a/acceptance/bundle/migrate/dashboards/databricks.yml b/acceptance/bundle/migrate/dashboards/databricks.yml deleted file mode 100644 index dfda730b7a6..00000000000 --- a/acceptance/bundle/migrate/dashboards/databricks.yml +++ /dev/null @@ -1,11 +0,0 @@ -bundle: - name: test-bundle - -resources: - dashboards: - dashboard1: - display_name: my dashboard - warehouse_id: 123456 - embed_credentials: true - file_path: "sample-dashboard.lvdash.json" - parent_path: /Users/tester@databricks.com diff --git a/acceptance/bundle/migrate/dashboards/out.new_state.json b/acceptance/bundle/migrate/dashboards/out.new_state.json deleted file mode 100644 index c1bdc4c7b78..00000000000 --- a/acceptance/bundle/migrate/dashboards/out.new_state.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "state_version": 3, - "cli_version": "[CLI_VERSION]", - "lineage": "[UUID]", - "serial": 3, - "state": { - "resources.dashboards.dashboard1": { - "__id__": "[DASHBOARD1_ID]", - "state": { - "display_name": "my dashboard", - "embed_credentials": true, - "etag": "[NUMID]", - "parent_path": "/Workspace/Users/[USERNAME]", - "published": true, - "serialized_dashboard": "sha256:[HASH]", - "warehouse_id": "123456" - } - } - } -} diff --git a/acceptance/bundle/migrate/dashboards/out.original_state.json b/acceptance/bundle/migrate/dashboards/out.original_state.json deleted file mode 100644 index 588895fb3c5..00000000000 --- a/acceptance/bundle/migrate/dashboards/out.original_state.json +++ /dev/null @@ -1,47 +0,0 @@ -{ - "version": 4, - "terraform_version": "1.5.5", - "serial": 1, - "lineage": "[UUID]", - "outputs": {}, - "resources": [ - { - "mode": "managed", - "type": "databricks_dashboard", - "name": "dashboard1", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 0, - "attributes": { - "create_time": "[TIMESTAMP]", - "dashboard_change_detected": false, - "dashboard_id": "[DASHBOARD1_ID]", - "dataset_catalog": null, - "dataset_schema": null, - "display_name": "my dashboard", - "embed_credentials": true, - "etag": "[NUMID]", - "file_path": null, - "id": "[DASHBOARD1_ID]", - "lifecycle_state": "ACTIVE", - "md5": "b4ab6aee48485b0b5e980761d3efe936", - "parent_path": "/Users/[USERNAME]", - "path": "/Users/[USERNAME]/my dashboard.lvdash.json", - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "serialized_dashboard": "{\"pages\":[{\"displayName\":\"Dashboard test bundle-deploy-dashboard\",\"name\":\"02724bf2\",\"pageType\":\"PAGE_TYPE_CANVAS\"}]}\n", - "update_time": "[TIMESTAMP]", - "warehouse_id": "123456" - }, - "sensitive_attributes": [], - "private": "bnVsbA==" - } - ] - } - ], - "check_results": null -} diff --git a/acceptance/bundle/migrate/dashboards/out.plan_after_migrate.json b/acceptance/bundle/migrate/dashboards/out.plan_after_migrate.json deleted file mode 100644 index 37124a4c407..00000000000 --- a/acceptance/bundle/migrate/dashboards/out.plan_after_migrate.json +++ /dev/null @@ -1,65 +0,0 @@ -{ - "plan_version": [PLAN_VERSION], - "cli_version": "[CLI_VERSION]", - "lineage": "[UUID]", - "serial": 3, - "plan": { - "resources.dashboards.dashboard1": { - "action": "skip", - "remote_state": { - "create_time": "[TIMESTAMP]", - "dashboard_id": "[DASHBOARD1_ID]", - "display_name": "my dashboard", - "embed_credentials": true, - "etag": "[NUMID]", - "lifecycle_state": "ACTIVE", - "parent_path": "/Workspace/Users/[USERNAME]", - "path": "/Users/[USERNAME]/my dashboard.lvdash.json", - "published": true, - "serialized_dashboard": "{\"pages\":[{\"displayName\":\"Dashboard test bundle-deploy-dashboard\",\"name\":\"02724bf2\",\"pageType\":\"PAGE_TYPE_CANVAS\"}]}\n", - "update_time": "[TIMESTAMP]", - "warehouse_id": "123456" - }, - "changes": { - "create_time": { - "action": "skip", - "reason": "spec:output_only", - "remote": "[TIMESTAMP]" - }, - "dashboard_id": { - "action": "skip", - "reason": "spec:output_only", - "remote": "[DASHBOARD1_ID]" - }, - "etag": { - "action": "skip", - "reason": "custom", - "old": "[NUMID]", - "remote": "[NUMID]" - }, - "lifecycle_state": { - "action": "skip", - "reason": "spec:output_only", - "remote": "ACTIVE" - }, - "path": { - "action": "skip", - "reason": "spec:output_only", - "remote": "/Users/[USERNAME]/my dashboard.lvdash.json" - }, - "serialized_dashboard": { - "action": "skip", - "reason": "etag_based", - "old": "sha256:[HASH][0]", - "new": "sha256:[HASH][0]", - "remote": "sha256:[HASH][1]" - }, - "update_time": { - "action": "skip", - "reason": "spec:output_only", - "remote": "[TIMESTAMP]" - } - } - } - } -} diff --git a/acceptance/bundle/migrate/dashboards/out.test.toml b/acceptance/bundle/migrate/dashboards/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/dashboards/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/dashboards/output.txt b/acceptance/bundle/migrate/dashboards/output.txt deleted file mode 100644 index 8eca598e43c..00000000000 --- a/acceptance/bundle/migrate/dashboards/output.txt +++ /dev/null @@ -1,53 +0,0 @@ - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created dashboards.dashboard1 -Files: 3 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged - ->>> [CLI] bundle deployment migrate -Success! Migrated 1 resources to direct engine state file: [TEST_TMP_DIR]/.databricks/bundle/default/resources.json - -Validate the migration by running "databricks bundle plan", there should be no actions planned. - -The state file is not synchronized to the workspace yet. To do that and finalize the migration, run "bundle deploy". - -To undo the migration, remove [TEST_TMP_DIR]/.databricks/bundle/default/resources.json and rename [TEST_TMP_DIR]/.databricks/bundle/default/terraform/terraform.tfstate.backup to [TEST_TMP_DIR]/.databricks/bundle/default/terraform/terraform.tfstate - - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 1 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 2 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 1 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 1 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 1 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle plan -o json - ->>> print_requests.py --get //dashboards - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle deploy --auto-approve -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 1 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 1 unchanged - ->>> print_requests.py --get //dashboards - -=== Should show that it's already migrated ->>> musterr [CLI] bundle deployment migrate -Error: already using direct engine -Details: [TEST_TMP_DIR]/.databricks/bundle/default/resources.json: local direct state serial=3 lineage="[UUID]" - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle debug states -[TEST_TMP_DIR]/.databricks/bundle/default/resources.json: local direct state serial=3 lineage="[UUID]" - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle debug states --force-pull -resources.json: remote direct state serial=3 lineage="[UUID]" -[TEST_TMP_DIR]/.databricks/bundle/default/resources.json: local direct state serial=3 lineage="[UUID]" diff --git a/acceptance/bundle/migrate/dashboards/sample-dashboard.lvdash.json b/acceptance/bundle/migrate/dashboards/sample-dashboard.lvdash.json deleted file mode 100644 index 425cb33fb35..00000000000 --- a/acceptance/bundle/migrate/dashboards/sample-dashboard.lvdash.json +++ /dev/null @@ -1 +0,0 @@ -{"pages":[{"name":"02724bf2","displayName":"Dashboard test bundle-deploy-dashboard"}]} diff --git a/acceptance/bundle/migrate/dashboards/script b/acceptance/bundle/migrate/dashboards/script deleted file mode 100755 index 68fc6883eb3..00000000000 --- a/acceptance/bundle/migrate/dashboards/script +++ /dev/null @@ -1,38 +0,0 @@ -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -# Add all resource IDs to runtime replacements to avoid pattern matching ambiguity -replace_ids.py -print_state.py > out.original_state.json - -trace $CLI bundle deployment migrate 2>&1 | contains.py 'Migrated 1 resources' -print_state.py > out.new_state.json - -# this is expected to warn because state does not match env var, but still succeed using state engine -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle plan -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy - -rm "$OUT_REQUESTS" -# Both DATABRICKS_BUNDLE_ENGINE=direct and DATABRICKS_BUNDLE_ENGINE= work -# Badness: known issue with dashboards, will show up as 'recreate' see https://github.com/databricks/cli/pull/3966 -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle plan | contains.py "1 unchanged" -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle plan | contains.py "1 unchanged" -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle plan -o json | nostamp > out.plan_after_migrate.json -trace print_requests.py --get //dashboards | contains.py 'engine/direct' > /dev/null - -trace DATABRICKS_BUNDLE_ENGINE="" $CLI bundle deploy --auto-approve -trace print_requests.py --get //dashboards | jq '.headers["User-Agent"][0]' | contains.py 'engine/direct' > /dev/null - -title "Should show that it's already migrated" -trace musterr $CLI bundle deployment migrate -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle debug states -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle debug states --force-pull - -rm "$OUT_REQUESTS" - -# Uncomment once 'recreate' bug is fixed -#title "Update databricks.yml, run plan & update" -#trace update_file.py databricks.yml dashboard DASHBOARD -#trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle plan -#trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle plan -o json | nostamp > out.plan_update.json -#trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle deploy - -#rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/migrate/default-python/databricks.yml b/acceptance/bundle/migrate/default-python/databricks.yml deleted file mode 100644 index 87eddb69ad1..00000000000 --- a/acceptance/bundle/migrate/default-python/databricks.yml +++ /dev/null @@ -1,47 +0,0 @@ -bundle: - name: migrate-basic-test - -resources: - jobs: - test_job: - name: "Test Migration Job" - tasks: - - task_key: "main" - notebook_task: - notebook_path: "./notebook.py" - volumes: - test_volume: - catalog_name: "mycat" - schema_name: "myschema" - name: "myvol" - - pipelines: - test_pipeline: - name: "Test Migration Pipeline" - tags: - # ids - myjob_id: ${resources.jobs.test_job.id} - myvolume_id: ${resources.volumes.test_volume.id} - - # local field, string: - myjob_name: ${resources.jobs.test_job.name} - volume_catalog_name: ${resources.volumes.test_volume.catalog_name} - - # remote field, int, null - myjob_timeout: ${resources.jobs.test_job.timeout_seconds} - - # remote field, string: - volume_storage_location: ${resources.volumes.test_volume.storage_location} - libraries: - - notebook: - path: "./pipeline.py" - -targets: - dev: - default: true - prod: - resources: - schemas: - test_schema: - catalog_name: mycat - name: myschema diff --git a/acceptance/bundle/migrate/default-python/input.json b/acceptance/bundle/migrate/default-python/input.json deleted file mode 100644 index 2c4416c00c6..00000000000 --- a/acceptance/bundle/migrate/default-python/input.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "project_name": "my_default_python", - "include_notebook": "yes", - "include_dlt": "yes", - "include_python": "yes", - "serverless": "no" -} diff --git a/acceptance/bundle/migrate/default-python/notebook.py b/acceptance/bundle/migrate/default-python/notebook.py deleted file mode 100644 index 250b3c9f766..00000000000 --- a/acceptance/bundle/migrate/default-python/notebook.py +++ /dev/null @@ -1,2 +0,0 @@ -# Databricks notebook source -print("Hello from test migration job") diff --git a/acceptance/bundle/migrate/default-python/out.plan_after_deploy.json b/acceptance/bundle/migrate/default-python/out.plan_after_deploy.json deleted file mode 100644 index 2ec4018e820..00000000000 --- a/acceptance/bundle/migrate/default-python/out.plan_after_deploy.json +++ /dev/null @@ -1,352 +0,0 @@ -{ - "plan_version": [PLAN_VERSION], - "cli_version": "[CLI_VERSION]", - "lineage": "[UUID]", - "serial": 6, - "plan": { - "resources.jobs.sample_job": { - "depends_on": [ - { - "node": "resources.pipelines.my_default_python_etl", - "label": "${resources.pipelines.my_default_python_etl.id}" - } - ], - "action": "update", - "new_state": { - "value": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "job_clusters": [ - { - "job_cluster_key": "job_cluster", - "new_cluster": { - "autoscale": { - "max_workers": 4, - "min_workers": 1 - }, - "data_security_mode": "DATA_SECURITY_MODE_AUTO", - "node_type_id": "[NODE_TYPE_ID]", - "spark_version": "16.4.x-scala2.12" - } - } - ], - "max_concurrent_runs": 4, - "name": "[dev [USERNAME]] sample_job", - "parameters": [ - { - "default": "hive_metastore", - "name": "catalog" - }, - { - "default": "[USERNAME]", - "name": "schema" - } - ], - "queue": { - "enabled": true - }, - "tags": { - "dev": "[USERNAME]" - }, - "tasks": [ - { - "job_cluster_key": "job_cluster", - "libraries": [ - { - "whl": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl" - } - ], - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/sample_notebook" - }, - "task_key": "notebook_task" - }, - { - "depends_on": [ - { - "task_key": "notebook_task" - } - ], - "job_cluster_key": "job_cluster", - "libraries": [ - { - "whl": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl" - } - ], - "python_wheel_task": { - "entry_point": "main", - "package_name": "my_default_python", - "parameters": [ - "--catalog", - "hive_metastore", - "--schema", - "[USERNAME]" - ] - }, - "task_key": "python_wheel_task" - }, - { - "depends_on": [ - { - "task_key": "notebook_task" - } - ], - "pipeline_task": { - "pipeline_id": "[UUID]" - }, - "task_key": "refresh_pipeline" - } - ], - "trigger": { - "pause_status": "PAUSED", - "periodic": { - "interval": 1, - "unit": "DAYS" - } - } - } - }, - "remote_state": { - "created_time": [UNIX_TIME_MILLIS][0], - "creator_user_name": "[USERNAME]", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "email_notifications": {}, - "format": "MULTI_TASK", - "job_clusters": [ - { - "job_cluster_key": "job_cluster", - "new_cluster": { - "autoscale": { - "max_workers": 4, - "min_workers": 1 - }, - "data_security_mode": "DATA_SECURITY_MODE_AUTO", - "node_type_id": "[NODE_TYPE_ID]", - "spark_version": "16.4.x-scala2.12" - } - } - ], - "job_id": [NUMID], - "max_concurrent_runs": 4, - "name": "[dev [USERNAME]] sample_job", - "parameters": [ - { - "default": "hive_metastore", - "name": "catalog" - }, - { - "default": "[USERNAME]", - "name": "schema" - } - ], - "queue": { - "enabled": true - }, - "run_as_user_name": "[USERNAME]", - "tags": { - "dev": "[USERNAME]" - }, - "tasks": [ - { - "email_notifications": {}, - "job_cluster_key": "job_cluster", - "libraries": [ - { - "whl": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][1]-py3-none-any.whl" - } - ], - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/sample_notebook", - "source": "WORKSPACE" - }, - "run_if": "ALL_SUCCESS", - "task_key": "notebook_task", - "timeout_seconds": 0 - }, - { - "depends_on": [ - { - "task_key": "notebook_task" - } - ], - "email_notifications": {}, - "job_cluster_key": "job_cluster", - "libraries": [ - { - "whl": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][1]-py3-none-any.whl" - } - ], - "python_wheel_task": { - "entry_point": "main", - "package_name": "my_default_python", - "parameters": [ - "--catalog", - "hive_metastore", - "--schema", - "[USERNAME]" - ] - }, - "run_if": "ALL_SUCCESS", - "task_key": "python_wheel_task", - "timeout_seconds": 0 - }, - { - "depends_on": [ - { - "task_key": "notebook_task" - } - ], - "email_notifications": {}, - "pipeline_task": { - "pipeline_id": "[UUID]" - }, - "run_if": "ALL_SUCCESS", - "task_key": "refresh_pipeline", - "timeout_seconds": 0 - } - ], - "timeout_seconds": 0, - "trigger": { - "pause_status": "PAUSED", - "periodic": { - "interval": 1, - "unit": "DAYS" - } - }, - "webhook_notifications": {} - }, - "changes": { - "email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "tasks[task_key='notebook_task'].email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "tasks[task_key='notebook_task'].libraries[0].whl": { - "action": "update", - "old": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][1]-py3-none-any.whl", - "new": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl", - "remote": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][1]-py3-none-any.whl" - }, - "tasks[task_key='notebook_task'].notebook_task.source": { - "action": "skip", - "reason": "backend_default", - "remote": "WORKSPACE" - }, - "tasks[task_key='notebook_task'].run_if": { - "action": "skip", - "reason": "backend_default", - "remote": "ALL_SUCCESS" - }, - "tasks[task_key='notebook_task'].timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "tasks[task_key='python_wheel_task'].email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "tasks[task_key='python_wheel_task'].libraries[0].whl": { - "action": "update", - "old": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][1]-py3-none-any.whl", - "new": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl", - "remote": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][1]-py3-none-any.whl" - }, - "tasks[task_key='python_wheel_task'].run_if": { - "action": "skip", - "reason": "backend_default", - "remote": "ALL_SUCCESS" - }, - "tasks[task_key='python_wheel_task'].timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "tasks[task_key='refresh_pipeline'].email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "tasks[task_key='refresh_pipeline'].run_if": { - "action": "skip", - "reason": "backend_default", - "remote": "ALL_SUCCESS" - }, - "tasks[task_key='refresh_pipeline'].timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "webhook_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - } - } - }, - "resources.pipelines.my_default_python_etl": { - "action": "skip", - "remote_state": { - "channel": "CURRENT", - "creator_user_name": "[USERNAME]", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/state/metadata.json" - }, - "development": true, - "edition": "ADVANCED", - "effective_publishing_mode": "DEFAULT_PUBLISHING_MODE", - "environment": { - "dependencies": [ - "--editable /Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files" - ] - }, - "id": "[UUID]", - "last_modified": [UNIX_TIME_MILLIS][1], - "libraries": [ - { - "glob": { - "include": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/my_default_python_etl/transformations/**" - } - } - ], - "name": "[dev [USERNAME]] my_default_python_etl", - "pipeline_id": "[UUID]", - "root_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/my_default_python_etl", - "run_as_user_name": "[USERNAME]", - "schema": "[USERNAME]", - "state": "IDLE", - "storage": "dbfs:/pipelines/[UUID]", - "tags": { - "dev": "[USERNAME]" - } - }, - "changes": { - "storage": { - "action": "skip", - "reason": "backend_default", - "remote": "dbfs:/pipelines/[UUID]" - } - } - } - } -} diff --git a/acceptance/bundle/migrate/default-python/out.plan_after_migration.json b/acceptance/bundle/migrate/default-python/out.plan_after_migration.json deleted file mode 100644 index de570cc7ade..00000000000 --- a/acceptance/bundle/migrate/default-python/out.plan_after_migration.json +++ /dev/null @@ -1,352 +0,0 @@ -{ - "plan_version": [PLAN_VERSION], - "cli_version": "[CLI_VERSION]", - "lineage": "[UUID]", - "serial": 5, - "plan": { - "resources.jobs.sample_job": { - "depends_on": [ - { - "node": "resources.pipelines.my_default_python_etl", - "label": "${resources.pipelines.my_default_python_etl.id}" - } - ], - "action": "update", - "new_state": { - "value": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "job_clusters": [ - { - "job_cluster_key": "job_cluster", - "new_cluster": { - "autoscale": { - "max_workers": 4, - "min_workers": 1 - }, - "data_security_mode": "DATA_SECURITY_MODE_AUTO", - "node_type_id": "[NODE_TYPE_ID]", - "spark_version": "16.4.x-scala2.12" - } - } - ], - "max_concurrent_runs": 4, - "name": "[dev [USERNAME]] sample_job", - "parameters": [ - { - "default": "hive_metastore", - "name": "catalog" - }, - { - "default": "[USERNAME]", - "name": "schema" - } - ], - "queue": { - "enabled": true - }, - "tags": { - "dev": "[USERNAME]" - }, - "tasks": [ - { - "job_cluster_key": "job_cluster", - "libraries": [ - { - "whl": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl" - } - ], - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/sample_notebook" - }, - "task_key": "notebook_task" - }, - { - "depends_on": [ - { - "task_key": "notebook_task" - } - ], - "job_cluster_key": "job_cluster", - "libraries": [ - { - "whl": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl" - } - ], - "python_wheel_task": { - "entry_point": "main", - "package_name": "my_default_python", - "parameters": [ - "--catalog", - "hive_metastore", - "--schema", - "[USERNAME]" - ] - }, - "task_key": "python_wheel_task" - }, - { - "depends_on": [ - { - "task_key": "notebook_task" - } - ], - "pipeline_task": { - "pipeline_id": "[UUID]" - }, - "task_key": "refresh_pipeline" - } - ], - "trigger": { - "pause_status": "PAUSED", - "periodic": { - "interval": 1, - "unit": "DAYS" - } - } - } - }, - "remote_state": { - "created_time": [UNIX_TIME_MILLIS][0], - "creator_user_name": "[USERNAME]", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "email_notifications": {}, - "format": "MULTI_TASK", - "job_clusters": [ - { - "job_cluster_key": "job_cluster", - "new_cluster": { - "autoscale": { - "max_workers": 4, - "min_workers": 1 - }, - "data_security_mode": "DATA_SECURITY_MODE_AUTO", - "node_type_id": "[NODE_TYPE_ID]", - "spark_version": "16.4.x-scala2.12" - } - } - ], - "job_id": [NUMID], - "max_concurrent_runs": 4, - "name": "[dev [USERNAME]] sample_job", - "parameters": [ - { - "default": "hive_metastore", - "name": "catalog" - }, - { - "default": "[USERNAME]", - "name": "schema" - } - ], - "queue": { - "enabled": true - }, - "run_as_user_name": "[USERNAME]", - "tags": { - "dev": "[USERNAME]" - }, - "tasks": [ - { - "email_notifications": {}, - "job_cluster_key": "job_cluster", - "libraries": [ - { - "whl": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][1]-py3-none-any.whl" - } - ], - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/sample_notebook", - "source": "WORKSPACE" - }, - "run_if": "ALL_SUCCESS", - "task_key": "notebook_task", - "timeout_seconds": 0 - }, - { - "depends_on": [ - { - "task_key": "notebook_task" - } - ], - "email_notifications": {}, - "job_cluster_key": "job_cluster", - "libraries": [ - { - "whl": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][1]-py3-none-any.whl" - } - ], - "python_wheel_task": { - "entry_point": "main", - "package_name": "my_default_python", - "parameters": [ - "--catalog", - "hive_metastore", - "--schema", - "[USERNAME]" - ] - }, - "run_if": "ALL_SUCCESS", - "task_key": "python_wheel_task", - "timeout_seconds": 0 - }, - { - "depends_on": [ - { - "task_key": "notebook_task" - } - ], - "email_notifications": {}, - "pipeline_task": { - "pipeline_id": "[UUID]" - }, - "run_if": "ALL_SUCCESS", - "task_key": "refresh_pipeline", - "timeout_seconds": 0 - } - ], - "timeout_seconds": 0, - "trigger": { - "pause_status": "PAUSED", - "periodic": { - "interval": 1, - "unit": "DAYS" - } - }, - "webhook_notifications": {} - }, - "changes": { - "email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "tasks[task_key='notebook_task'].email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "tasks[task_key='notebook_task'].libraries[0].whl": { - "action": "update", - "old": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][2]-py3-none-any.whl", - "new": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl", - "remote": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][1]-py3-none-any.whl" - }, - "tasks[task_key='notebook_task'].notebook_task.source": { - "action": "skip", - "reason": "backend_default", - "remote": "WORKSPACE" - }, - "tasks[task_key='notebook_task'].run_if": { - "action": "skip", - "reason": "backend_default", - "remote": "ALL_SUCCESS" - }, - "tasks[task_key='notebook_task'].timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "tasks[task_key='python_wheel_task'].email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "tasks[task_key='python_wheel_task'].libraries[0].whl": { - "action": "update", - "old": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][2]-py3-none-any.whl", - "new": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl", - "remote": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][1]-py3-none-any.whl" - }, - "tasks[task_key='python_wheel_task'].run_if": { - "action": "skip", - "reason": "backend_default", - "remote": "ALL_SUCCESS" - }, - "tasks[task_key='python_wheel_task'].timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "tasks[task_key='refresh_pipeline'].email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "tasks[task_key='refresh_pipeline'].run_if": { - "action": "skip", - "reason": "backend_default", - "remote": "ALL_SUCCESS" - }, - "tasks[task_key='refresh_pipeline'].timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "webhook_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - } - } - }, - "resources.pipelines.my_default_python_etl": { - "action": "skip", - "remote_state": { - "channel": "CURRENT", - "creator_user_name": "[USERNAME]", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/state/metadata.json" - }, - "development": true, - "edition": "ADVANCED", - "effective_publishing_mode": "DEFAULT_PUBLISHING_MODE", - "environment": { - "dependencies": [ - "--editable /Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files" - ] - }, - "id": "[UUID]", - "last_modified": [UNIX_TIME_MILLIS][1], - "libraries": [ - { - "glob": { - "include": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/my_default_python_etl/transformations/**" - } - } - ], - "name": "[dev [USERNAME]] my_default_python_etl", - "pipeline_id": "[UUID]", - "root_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/my_default_python_etl", - "run_as_user_name": "[USERNAME]", - "schema": "[USERNAME]", - "state": "IDLE", - "storage": "dbfs:/pipelines/[UUID]", - "tags": { - "dev": "[USERNAME]" - } - }, - "changes": { - "storage": { - "action": "skip", - "reason": "backend_default", - "remote": "dbfs:/pipelines/[UUID]" - } - } - } - } -} diff --git a/acceptance/bundle/migrate/default-python/out.state_after_migration.json b/acceptance/bundle/migrate/default-python/out.state_after_migration.json deleted file mode 100644 index 484db23fd94..00000000000 --- a/acceptance/bundle/migrate/default-python/out.state_after_migration.json +++ /dev/null @@ -1,143 +0,0 @@ -{ - "state_version": 3, - "cli_version": "[CLI_VERSION]", - "lineage": "[UUID]", - "serial": 5, - "state": { - "resources.jobs.sample_job": { - "__id__": "[NUMID]", - "state": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "job_clusters": [ - { - "job_cluster_key": "job_cluster", - "new_cluster": { - "autoscale": { - "max_workers": 4, - "min_workers": 1 - }, - "data_security_mode": "DATA_SECURITY_MODE_AUTO", - "node_type_id": "[NODE_TYPE_ID]", - "spark_version": "16.4.x-scala2.12" - } - } - ], - "max_concurrent_runs": 4, - "name": "[dev [USERNAME]] sample_job", - "parameters": [ - { - "default": "hive_metastore", - "name": "catalog" - }, - { - "default": "[USERNAME]", - "name": "schema" - } - ], - "queue": { - "enabled": true - }, - "tags": { - "dev": "[USERNAME]" - }, - "tasks": [ - { - "job_cluster_key": "job_cluster", - "libraries": [ - { - "whl": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl" - } - ], - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/sample_notebook" - }, - "task_key": "notebook_task" - }, - { - "depends_on": [ - { - "task_key": "notebook_task" - } - ], - "job_cluster_key": "job_cluster", - "libraries": [ - { - "whl": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl" - } - ], - "python_wheel_task": { - "entry_point": "main", - "package_name": "my_default_python", - "parameters": [ - "--catalog", - "hive_metastore", - "--schema", - "[USERNAME]" - ] - }, - "task_key": "python_wheel_task" - }, - { - "depends_on": [ - { - "task_key": "notebook_task" - } - ], - "pipeline_task": { - "pipeline_id": "[UUID]" - }, - "task_key": "refresh_pipeline" - } - ], - "trigger": { - "pause_status": "PAUSED", - "periodic": { - "interval": 1, - "unit": "DAYS" - } - } - }, - "depends_on": [ - { - "node": "resources.pipelines.my_default_python_etl", - "label": "${resources.pipelines.my_default_python_etl.id}" - } - ] - }, - "resources.pipelines.my_default_python_etl": { - "__id__": "[UUID]", - "state": { - "channel": "CURRENT", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/state/metadata.json" - }, - "development": true, - "edition": "ADVANCED", - "environment": { - "dependencies": [ - "--editable /Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files" - ] - }, - "libraries": [ - { - "glob": { - "include": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/my_default_python_etl/transformations/**" - } - } - ], - "name": "[dev [USERNAME]] my_default_python_etl", - "root_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/my_default_python_etl", - "schema": "[USERNAME]", - "tags": { - "dev": "[USERNAME]" - } - } - } - } -} diff --git a/acceptance/bundle/migrate/default-python/out.state_original.json b/acceptance/bundle/migrate/default-python/out.state_original.json deleted file mode 100644 index 1363591874f..00000000000 --- a/acceptance/bundle/migrate/default-python/out.state_original.json +++ /dev/null @@ -1,498 +0,0 @@ -{ - "version": 4, - "terraform_version": "1.5.5", - "serial": 3, - "lineage": "[UUID]", - "outputs": {}, - "resources": [ - { - "mode": "managed", - "type": "databricks_job", - "name": "sample_job", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 2, - "attributes": { - "always_running": false, - "budget_policy_id": null, - "continuous": [], - "control_run_state": false, - "dbt_task": [], - "deployment": [ - { - "deployment_id": "", - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/state/metadata.json", - "version_id": "" - } - ], - "description": null, - "edit_mode": "UI_LOCKED", - "email_notifications": [ - { - "no_alert_for_skipped_runs": false, - "on_duration_warning_threshold_exceeded": [], - "on_failure": [], - "on_start": [], - "on_streaming_backlog_exceeded": [], - "on_success": [] - } - ], - "environment": [], - "existing_cluster_id": null, - "format": "MULTI_TASK", - "git_source": [], - "health": [], - "id": "[NUMID]", - "job_cluster": [ - { - "job_cluster_key": "job_cluster", - "new_cluster": [ - { - "__apply_policy_default_values_allow_list": null, - "apply_policy_default_values": false, - "autoscale": [ - { - "max_workers": 4, - "min_workers": 1 - } - ], - "aws_attributes": [], - "azure_attributes": [], - "cluster_id": "", - "cluster_log_conf": [], - "cluster_mount_info": [], - "cluster_name": "", - "custom_tags": null, - "data_security_mode": "DATA_SECURITY_MODE_AUTO", - "dependency_mode": "", - "docker_image": [], - "driver_instance_pool_id": "", - "driver_node_type_flexibility": [], - "driver_node_type_id": "", - "enable_elastic_disk": false, - "enable_local_disk_encryption": false, - "gcp_attributes": [], - "idempotency_token": "", - "init_scripts": [], - "instance_pool_id": "", - "is_single_node": false, - "kind": "", - "library": [], - "node_type_id": "[NODE_TYPE_ID]", - "num_workers": 0, - "policy_id": "", - "provider_config": [], - "remote_disk_throughput": 0, - "runtime_engine": "", - "single_user_name": "", - "spark_conf": null, - "spark_env_vars": null, - "spark_version": "16.4.x-scala2.12", - "ssh_public_keys": null, - "total_initial_remote_disk_size": 0, - "use_ml_runtime": false, - "worker_node_type_flexibility": [], - "workload_type": [] - } - ], - "serverless_compute_id": "" - } - ], - "library": [], - "max_concurrent_runs": 4, - "max_retries": 0, - "min_retry_interval_millis": 0, - "name": "[dev [USERNAME]] sample_job", - "new_cluster": [], - "notebook_task": [], - "notification_settings": [], - "parameter": [ - { - "default": "hive_metastore", - "name": "catalog" - }, - { - "default": "[USERNAME]", - "name": "schema" - } - ], - "parent_path": null, - "performance_target": null, - "pipeline_task": [], - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "python_wheel_task": [], - "queue": [ - { - "enabled": true - } - ], - "retry_on_timeout": false, - "run_as": [ - { - "group_name": "", - "service_principal_name": "", - "user_name": "[USERNAME]" - } - ], - "run_job_task": [], - "schedule": [], - "spark_jar_task": [], - "spark_python_task": [], - "spark_submit_task": [], - "tags": { - "dev": "[USERNAME]" - }, - "task": [ - { - "ai_runtime_task": [], - "alert_task": [], - "clean_rooms_notebook_task": [], - "compute": [], - "condition_task": [], - "dashboard_task": [], - "dbt_cloud_task": [], - "dbt_platform_task": [], - "dbt_task": [], - "depends_on": [], - "description": "", - "disable_auto_optimization": false, - "disabled": false, - "email_notifications": [ - { - "no_alert_for_skipped_runs": false, - "on_duration_warning_threshold_exceeded": [], - "on_failure": [], - "on_start": [], - "on_streaming_backlog_exceeded": [], - "on_success": [] - } - ], - "environment_key": "", - "existing_cluster_id": "", - "for_each_task": [], - "gen_ai_compute_task": [], - "health": [], - "job_cluster_key": "job_cluster", - "library": [ - { - "cran": [], - "egg": "", - "jar": "", - "maven": [], - "provider_config": [], - "pypi": [], - "requirements": "", - "whl": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl" - } - ], - "max_retries": 0, - "min_retry_interval_millis": 0, - "new_cluster": [], - "notebook_task": [ - { - "base_parameters": null, - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/sample_notebook", - "source": "WORKSPACE", - "warehouse_id": "" - } - ], - "notification_settings": [], - "pipeline_task": [], - "power_bi_task": [], - "python_operator_task": [], - "python_wheel_task": [], - "retry_on_timeout": false, - "run_if": "ALL_SUCCESS", - "run_job_task": [], - "spark_jar_task": [], - "spark_python_task": [], - "spark_submit_task": [], - "sql_task": [], - "task_key": "notebook_task", - "timeout_seconds": 0, - "webhook_notifications": [] - }, - { - "ai_runtime_task": [], - "alert_task": [], - "clean_rooms_notebook_task": [], - "compute": [], - "condition_task": [], - "dashboard_task": [], - "dbt_cloud_task": [], - "dbt_platform_task": [], - "dbt_task": [], - "depends_on": [ - { - "outcome": "", - "task_key": "notebook_task" - } - ], - "description": "", - "disable_auto_optimization": false, - "disabled": false, - "email_notifications": [ - { - "no_alert_for_skipped_runs": false, - "on_duration_warning_threshold_exceeded": [], - "on_failure": [], - "on_start": [], - "on_streaming_backlog_exceeded": [], - "on_success": [] - } - ], - "environment_key": "", - "existing_cluster_id": "", - "for_each_task": [], - "gen_ai_compute_task": [], - "health": [], - "job_cluster_key": "job_cluster", - "library": [ - { - "cran": [], - "egg": "", - "jar": "", - "maven": [], - "provider_config": [], - "pypi": [], - "requirements": "", - "whl": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl" - } - ], - "max_retries": 0, - "min_retry_interval_millis": 0, - "new_cluster": [], - "notebook_task": [], - "notification_settings": [], - "pipeline_task": [], - "power_bi_task": [], - "python_operator_task": [], - "python_wheel_task": [ - { - "entry_point": "main", - "named_parameters": null, - "package_name": "my_default_python", - "parameters": [ - "--catalog", - "hive_metastore", - "--schema", - "[USERNAME]" - ] - } - ], - "retry_on_timeout": false, - "run_if": "ALL_SUCCESS", - "run_job_task": [], - "spark_jar_task": [], - "spark_python_task": [], - "spark_submit_task": [], - "sql_task": [], - "task_key": "python_wheel_task", - "timeout_seconds": 0, - "webhook_notifications": [] - }, - { - "ai_runtime_task": [], - "alert_task": [], - "clean_rooms_notebook_task": [], - "compute": [], - "condition_task": [], - "dashboard_task": [], - "dbt_cloud_task": [], - "dbt_platform_task": [], - "dbt_task": [], - "depends_on": [ - { - "outcome": "", - "task_key": "notebook_task" - } - ], - "description": "", - "disable_auto_optimization": false, - "disabled": false, - "email_notifications": [ - { - "no_alert_for_skipped_runs": false, - "on_duration_warning_threshold_exceeded": [], - "on_failure": [], - "on_start": [], - "on_streaming_backlog_exceeded": [], - "on_success": [] - } - ], - "environment_key": "", - "existing_cluster_id": "", - "for_each_task": [], - "gen_ai_compute_task": [], - "health": [], - "job_cluster_key": "", - "library": [], - "max_retries": 0, - "min_retry_interval_millis": 0, - "new_cluster": [], - "notebook_task": [], - "notification_settings": [], - "pipeline_task": [ - { - "full_refresh": false, - "full_refresh_selection": null, - "parameters": null, - "pipeline_id": "[UUID]", - "refresh_flow_selection": null, - "refresh_selection": null, - "reset_checkpoint_selection": null - } - ], - "power_bi_task": [], - "python_operator_task": [], - "python_wheel_task": [], - "retry_on_timeout": false, - "run_if": "ALL_SUCCESS", - "run_job_task": [], - "spark_jar_task": [], - "spark_python_task": [], - "spark_submit_task": [], - "sql_task": [], - "task_key": "refresh_pipeline", - "timeout_seconds": 0, - "webhook_notifications": [] - } - ], - "timeout_seconds": 0, - "timeouts": null, - "trigger": [ - { - "file_arrival": [], - "model": [], - "pause_status": "PAUSED", - "periodic": [ - { - "interval": 1, - "unit": "DAYS" - } - ], - "sql_condition": [], - "table_update": [] - } - ], - "triggers": [], - "url": "[DATABRICKS_URL]/#job/[NUMID]", - "usage_policy_id": null, - "webhook_notifications": [ - { - "on_duration_warning_threshold_exceeded": [], - "on_failure": [], - "on_start": [], - "on_streaming_backlog_exceeded": [], - "on_success": [] - } - ] - }, - "sensitive_attributes": [], - "private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxODAwMDAwMDAwMDAwLCJ1cGRhdGUiOjE4MDAwMDAwMDAwMDB9LCJzY2hlbWFfdmVyc2lvbiI6IjIifQ==", - "dependencies": [ - "databricks_pipeline.my_default_python_etl" - ] - } - ] - }, - { - "mode": "managed", - "type": "databricks_pipeline", - "name": "my_default_python_etl", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 0, - "attributes": { - "allow_duplicate_names": false, - "budget_policy_id": null, - "catalog": null, - "cause": null, - "channel": "CURRENT", - "cluster": [], - "cluster_id": null, - "configuration": null, - "continuous": false, - "creator_user_name": "[USERNAME]", - "deployment": [ - { - "deployment_id": "", - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/state/metadata.json", - "version_id": "" - } - ], - "development": true, - "edition": "ADVANCED", - "environment": [ - { - "dependencies": [ - "--editable /Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files" - ], - "environment_version": "" - } - ], - "event_log": [], - "expected_last_modified": 0, - "filters": [], - "gateway_definition": [], - "health": null, - "id": "[UUID]", - "ingestion_definition": [], - "last_modified": [UNIX_TIME_MILLIS], - "latest_updates": null, - "library": [ - { - "file": [], - "glob": [ - { - "include": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/my_default_python_etl/transformations/**" - } - ], - "jar": "", - "maven": [], - "notebook": [], - "whl": "" - } - ], - "name": "[dev [USERNAME]] my_default_python_etl", - "notification": [], - "photon": false, - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "restart_window": [], - "root_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/my_default_python_etl", - "run_as": [], - "run_as_user_name": "[USERNAME]", - "schema": "[USERNAME]", - "serverless": false, - "serverless_compute_id": null, - "state": "IDLE", - "storage": "dbfs:/pipelines/[UUID]", - "tags": { - "dev": "[USERNAME]" - }, - "target": null, - "timeouts": null, - "trigger": [], - "url": "[DATABRICKS_URL]/#joblist/pipelines/[UUID]", - "usage_policy_id": null - }, - "sensitive_attributes": [], - "private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWZhdWx0IjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjEyMDAwMDAwMDAwMDAsInVwZGF0ZSI6MTIwMDAwMDAwMDAwMH19" - } - ] - } - ], - "check_results": null -} diff --git a/acceptance/bundle/migrate/default-python/out.test.toml b/acceptance/bundle/migrate/default-python/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/default-python/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/default-python/output.txt b/acceptance/bundle/migrate/default-python/output.txt deleted file mode 100644 index 46597c8462e..00000000000 --- a/acceptance/bundle/migrate/default-python/output.txt +++ /dev/null @@ -1,272 +0,0 @@ - ->>> [CLI] bundle init default-python --config-file ./input.json -Welcome to the default Python template for Declarative Automation Bundles! - -Answer the following questions to customize your project. -You can always change your configuration in the databricks.yml file later. - -Note that [DATABRICKS_URL] is used for initialization. -(For information on how to change your profile, see https://docs.databricks.com/dev-tools/cli/profiles.html.) - -✨ Your new project has been created in the 'my_default_python' directory! - -To get started, refer to the project README.md file and the documentation at https://docs.databricks.com/dev-tools/bundles/index.html. - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Building python_artifact... -Uploading .databricks/bundle/dev/patched_wheels/python_artifact_my_default_python/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl... -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files... -Created jobs.sample_job -Created pipelines.my_default_python_etl -Files: 21 uploaded, 0 deleted -Resources: 2 created, 0 changed, 0 deleted, 0 unchanged - ->>> print_state.py - ->>> [CLI] bundle deployment migrate -Building python_artifact... -Success! Migrated 2 resources to direct engine state file: [TEST_TMP_DIR]/my_default_python/.databricks/bundle/dev/resources.json - -Validate the migration by running "databricks bundle plan", there should be no actions planned. - -The state file is not synchronized to the workspace yet. To do that and finalize the migration, run "bundle deploy". - -To undo the migration, remove [TEST_TMP_DIR]/my_default_python/.databricks/bundle/dev/resources.json and rename [TEST_TMP_DIR]/my_default_python/.databricks/bundle/dev/terraform/terraform.tfstate.backup to [TEST_TMP_DIR]/my_default_python/.databricks/bundle/dev/terraform/terraform.tfstate - - ->>> print_state.py - ->>> jq .. | .libraries? | select(.) ../out.state_after_migration.json -[ - { - "whl": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][1]-py3-none-any.whl" - } -] -[ - { - "whl": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][1]-py3-none-any.whl" - } -] -[ - { - "glob": { - "include": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/my_default_python_etl/transformations/**" - } - } -] - ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle plan -Building python_artifact... -update jobs.sample_job - -Plan: 0 to add, 1 to change, 0 to delete, 1 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle plan -o json -Building python_artifact... - ->>> jq .plan[] | .changes ../out.plan_after_migration.json -{ - "email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "tasks[task_key='notebook_task'].email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "tasks[task_key='notebook_task'].libraries[0].whl": { - "action": "update", - "old": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][1]-py3-none-any.whl", - "new": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][2]-py3-none-any.whl", - "remote": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl" - }, - "tasks[task_key='notebook_task'].notebook_task.source": { - "action": "skip", - "reason": "backend_default", - "remote": "WORKSPACE" - }, - "tasks[task_key='notebook_task'].run_if": { - "action": "skip", - "reason": "backend_default", - "remote": "ALL_SUCCESS" - }, - "tasks[task_key='notebook_task'].timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "tasks[task_key='python_wheel_task'].email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "tasks[task_key='python_wheel_task'].libraries[0].whl": { - "action": "update", - "old": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][1]-py3-none-any.whl", - "new": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][2]-py3-none-any.whl", - "remote": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl" - }, - "tasks[task_key='python_wheel_task'].run_if": { - "action": "skip", - "reason": "backend_default", - "remote": "ALL_SUCCESS" - }, - "tasks[task_key='python_wheel_task'].timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "tasks[task_key='refresh_pipeline'].email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "tasks[task_key='refresh_pipeline'].run_if": { - "action": "skip", - "reason": "backend_default", - "remote": "ALL_SUCCESS" - }, - "tasks[task_key='refresh_pipeline'].timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "webhook_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - } -} -{ - "storage": { - "action": "skip", - "reason": "backend_default", - "remote": "dbfs:/pipelines/[UUID]" - } -} - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle deploy -Building python_artifact... -Uploading .databricks/bundle/dev/patched_wheels/python_artifact_my_default_python/my_default_python-0.0.1+[UNIX_TIME_NANOS][3]-py3-none-any.whl... -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files... -Updated jobs.sample_job -Files: 0 uploaded, 0 deleted -Resources: 0 created, 1 changed, 0 deleted, 1 unchanged - ->>> print_state.py - ->>> diff.py ../out.state_after_migration.json ../out.state_after_deploy.json ---- ../out.state_after_migration.json -+++ ../out.state_after_deploy.json -@@ -3,5 +3,5 @@ - "cli_version": "[CLI_VERSION]", - "lineage": "[UUID]", -- "serial": 5, -+ "serial": 6, - "state": { - "resources.jobs.sample_job": { - -=== Extra plan: should have no drift ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle plan -Building python_artifact... -update jobs.sample_job - -Plan: 0 to add, 1 to change, 0 to delete, 1 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle plan -o json -Building python_artifact... - ->>> jq .plan[] | .changes ../out.plan_after_migration.json -{ - "email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "tasks[task_key='notebook_task'].email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "tasks[task_key='notebook_task'].libraries[0].whl": { - "action": "update", - "old": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][1]-py3-none-any.whl", - "new": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][2]-py3-none-any.whl", - "remote": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl" - }, - "tasks[task_key='notebook_task'].notebook_task.source": { - "action": "skip", - "reason": "backend_default", - "remote": "WORKSPACE" - }, - "tasks[task_key='notebook_task'].run_if": { - "action": "skip", - "reason": "backend_default", - "remote": "ALL_SUCCESS" - }, - "tasks[task_key='notebook_task'].timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "tasks[task_key='python_wheel_task'].email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "tasks[task_key='python_wheel_task'].libraries[0].whl": { - "action": "update", - "old": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][1]-py3-none-any.whl", - "new": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][2]-py3-none-any.whl", - "remote": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl" - }, - "tasks[task_key='python_wheel_task'].run_if": { - "action": "skip", - "reason": "backend_default", - "remote": "ALL_SUCCESS" - }, - "tasks[task_key='python_wheel_task'].timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "tasks[task_key='refresh_pipeline'].email_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - }, - "tasks[task_key='refresh_pipeline'].run_if": { - "action": "skip", - "reason": "backend_default", - "remote": "ALL_SUCCESS" - }, - "tasks[task_key='refresh_pipeline'].timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "timeout_seconds": { - "action": "skip", - "reason": "empty", - "remote": 0 - }, - "webhook_notifications": { - "action": "skip", - "reason": "empty", - "remote": {} - } -} -{ - "storage": { - "action": "skip", - "reason": "backend_default", - "remote": "dbfs:/pipelines/[UUID]" - } -} diff --git a/acceptance/bundle/migrate/default-python/pipeline.py b/acceptance/bundle/migrate/default-python/pipeline.py deleted file mode 100644 index cd19031e962..00000000000 --- a/acceptance/bundle/migrate/default-python/pipeline.py +++ /dev/null @@ -1,2 +0,0 @@ -# Databricks notebook source -# This is a test pipeline notebook diff --git a/acceptance/bundle/migrate/default-python/script b/acceptance/bundle/migrate/default-python/script deleted file mode 100755 index f3a4ca0c37c..00000000000 --- a/acceptance/bundle/migrate/default-python/script +++ /dev/null @@ -1,25 +0,0 @@ -export DATABRICKS_BUNDLE_ENGINE= -trace $CLI bundle init default-python --config-file ./input.json -cd my_default_python - -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -trace print_state.py > ../out.state_original.json - -trace $CLI bundle deployment migrate - -trace print_state.py > ../out.state_after_migration.json -trace jq '.. | .libraries? | select(.)' ../out.state_after_migration.json - -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle plan -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle plan -o json | nostamp > ../out.plan_after_migration.json -trace jq '.plan[] | .changes' ../out.plan_after_migration.json # Badness: contains changes for whl and num_workers -trace DATABRICKS_BUNDLE_ENGINE="" $CLI bundle deploy - -trace print_state.py > ../out.state_after_deploy.json -trace diff.py ../out.state_after_migration.json ../out.state_after_deploy.json -rm ../out.state_after_deploy.json - -title "Extra plan: should have no drift" -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle plan -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle plan -o json | nostamp > ../out.plan_after_deploy.json -trace jq '.plan[] | .changes' ../out.plan_after_migration.json # Badness: contains changes for whl diff --git a/acceptance/bundle/migrate/default-python/test.toml b/acceptance/bundle/migrate/default-python/test.toml deleted file mode 100644 index 0fad1e53ffc..00000000000 --- a/acceptance/bundle/migrate/default-python/test.toml +++ /dev/null @@ -1,2 +0,0 @@ -RecordRequests = false -Ignore = ["my_default_python"] diff --git a/acceptance/bundle/migrate/engine-config-direct/databricks.yml b/acceptance/bundle/migrate/engine-config-direct/databricks.yml deleted file mode 100644 index 61400b279ad..00000000000 --- a/acceptance/bundle/migrate/engine-config-direct/databricks.yml +++ /dev/null @@ -1,3 +0,0 @@ -bundle: - name: test-migrate-engine - engine: direct diff --git a/acceptance/bundle/migrate/engine-config-direct/out.test.toml b/acceptance/bundle/migrate/engine-config-direct/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/engine-config-direct/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/engine-config-direct/output.txt b/acceptance/bundle/migrate/engine-config-direct/output.txt deleted file mode 100644 index 0a90ee8f9d5..00000000000 --- a/acceptance/bundle/migrate/engine-config-direct/output.txt +++ /dev/null @@ -1,5 +0,0 @@ - ->>> musterr [CLI] bundle deployment migrate -Error: This command migrates the existing Terraform state file (terraform.tfstate) to a direct deployment state file (resources.json). However, no existing local or remote state was found. - -To start using direct engine, set "engine: direct" under bundle in your databricks.yml or deploy with DATABRICKS_BUNDLE_ENGINE=direct env var set. diff --git a/acceptance/bundle/migrate/engine-config-direct/script b/acceptance/bundle/migrate/engine-config-direct/script deleted file mode 100644 index 3948f85a410..00000000000 --- a/acceptance/bundle/migrate/engine-config-direct/script +++ /dev/null @@ -1,2 +0,0 @@ -# engine: direct is allowed; fails at "no state" not at engine check -trace musterr $CLI bundle deployment migrate diff --git a/acceptance/bundle/migrate/engine-config-direct/test.toml b/acceptance/bundle/migrate/engine-config-direct/test.toml deleted file mode 100644 index a030353d571..00000000000 --- a/acceptance/bundle/migrate/engine-config-direct/test.toml +++ /dev/null @@ -1 +0,0 @@ -RecordRequests = false diff --git a/acceptance/bundle/migrate/engine-config-terraform/databricks.yml b/acceptance/bundle/migrate/engine-config-terraform/databricks.yml deleted file mode 100644 index 5d145586c37..00000000000 --- a/acceptance/bundle/migrate/engine-config-terraform/databricks.yml +++ /dev/null @@ -1,3 +0,0 @@ -bundle: - name: test-migrate-engine - engine: terraform diff --git a/acceptance/bundle/migrate/engine-config-terraform/out.test.toml b/acceptance/bundle/migrate/engine-config-terraform/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/engine-config-terraform/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/engine-config-terraform/output.txt b/acceptance/bundle/migrate/engine-config-terraform/output.txt deleted file mode 100644 index c971bf6e091..00000000000 --- a/acceptance/bundle/migrate/engine-config-terraform/output.txt +++ /dev/null @@ -1,8 +0,0 @@ - ->>> musterr [CLI] bundle deployment migrate -Warning: the terraform deployment engine is deprecated and will stop working in a future version of the CLI - in databricks.yml:3:11 - -See https://docs.databricks.com/aws/en/dev-tools/bundles/direct for how to migrate to the direct deployment engine - -Error: bundle.engine is set to "terraform". Migration requires "engine: direct" or no engine setting. Change the setting to "engine: direct" and retry diff --git a/acceptance/bundle/migrate/engine-config-terraform/script b/acceptance/bundle/migrate/engine-config-terraform/script deleted file mode 100644 index e0ff9411177..00000000000 --- a/acceptance/bundle/migrate/engine-config-terraform/script +++ /dev/null @@ -1,2 +0,0 @@ -# engine: terraform is rejected with an actionable error -trace musterr $CLI bundle deployment migrate diff --git a/acceptance/bundle/migrate/engine-config-terraform/test.toml b/acceptance/bundle/migrate/engine-config-terraform/test.toml deleted file mode 100644 index a030353d571..00000000000 --- a/acceptance/bundle/migrate/engine-config-terraform/test.toml +++ /dev/null @@ -1 +0,0 @@ -RecordRequests = false diff --git a/acceptance/bundle/migrate/grants/databricks.yml b/acceptance/bundle/migrate/grants/databricks.yml deleted file mode 100644 index 7412184076b..00000000000 --- a/acceptance/bundle/migrate/grants/databricks.yml +++ /dev/null @@ -1,34 +0,0 @@ -bundle: - name: test-bundle - -resources: - schemas: - my_schema: - catalog_name: main - name: schema_grants - grants: - - principal: deco-test-user@databricks.com - privileges: - - CREATE_TABLE - - USE_SCHEMA - - volumes: - my_volume: - catalog_name: main - schema_name: schema_grants - name: volume_name - grants: - - principal: deco-test-user@databricks.com - privileges: - - READ_VOLUME - - WRITE_VOLUME - - registered_models: - my_registered_model: - name: mymodel - comment: mycomment - catalog_name: main - schema_name: ${resources.schemas.my_schema.name} - grants: - - principal: deco-test-user@databricks.com - privileges: ["APPLY_TAG"] diff --git a/acceptance/bundle/migrate/grants/out.new_state.json b/acceptance/bundle/migrate/grants/out.new_state.json deleted file mode 100644 index 82b918f76d3..00000000000 --- a/acceptance/bundle/migrate/grants/out.new_state.json +++ /dev/null @@ -1,110 +0,0 @@ -{ - "state_version": 3, - "cli_version": "[CLI_VERSION]", - "lineage": "[UUID]", - "serial": 9, - "state": { - "resources.registered_models.my_registered_model": { - "__id__": "main.schema_grants.mymodel", - "state": { - "catalog_name": "main", - "comment": "mycomment", - "name": "mymodel", - "schema_name": "schema_grants" - }, - "depends_on": [ - { - "node": "resources.schemas.my_schema", - "label": "${resources.schemas.my_schema.name}" - } - ] - }, - "resources.registered_models.my_registered_model.grants": { - "__id__": "function/main.schema_grants.mymodel", - "state": { - "securable_type": "function", - "full_name": "main.schema_grants.mymodel", - "__embed__": [ - { - "principal": "deco-test-user@databricks.com", - "privileges": [ - "APPLY_TAG" - ] - } - ] - }, - "depends_on": [ - { - "node": "resources.registered_models.my_registered_model", - "label": "${resources.registered_models.my_registered_model.id}" - } - ] - }, - "resources.schemas.my_schema": { - "__id__": "main.schema_grants", - "state": { - "catalog_name": "main", - "name": "schema_grants" - } - }, - "resources.schemas.my_schema.grants": { - "__id__": "schema/main.schema_grants", - "state": { - "securable_type": "schema", - "full_name": "main.schema_grants", - "__embed__": [ - { - "principal": "deco-test-user@databricks.com", - "privileges": [ - "CREATE_TABLE", - "USE_SCHEMA" - ] - } - ] - }, - "depends_on": [ - { - "node": "resources.schemas.my_schema", - "label": "${resources.schemas.my_schema.id}" - } - ] - }, - "resources.volumes.my_volume": { - "__id__": "main.schema_grants.volume_name", - "state": { - "catalog_name": "main", - "name": "volume_name", - "schema_name": "schema_grants", - "volume_type": "MANAGED" - }, - "depends_on": [ - { - "node": "resources.schemas.my_schema", - "label": "${resources.schemas.my_schema.name}" - } - ] - }, - "resources.volumes.my_volume.grants": { - "__id__": "volume/main.schema_grants.volume_name", - "state": { - "securable_type": "volume", - "full_name": "main.schema_grants.volume_name", - "__embed__": [ - { - "principal": "deco-test-user@databricks.com", - "privileges": [ - "READ_VOLUME", - "WRITE_VOLUME" - ] - } - ] - }, - "depends_on": [ - { - "node": "resources.volumes.my_volume", - "label": "${resources.volumes.my_volume.id}" - } - ] - } - } -} diff --git a/acceptance/bundle/migrate/grants/out.original_state.json b/acceptance/bundle/migrate/grants/out.original_state.json deleted file mode 100644 index 8aee4f3e101..00000000000 --- a/acceptance/bundle/migrate/grants/out.original_state.json +++ /dev/null @@ -1,265 +0,0 @@ -{ - "version": 4, - "terraform_version": "1.5.5", - "serial": 7, - "lineage": "[UUID]", - "outputs": {}, - "resources": [ - { - "mode": "managed", - "type": "databricks_grants", - "name": "registered_model_my_registered_model", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 0, - "attributes": { - "catalog": null, - "credential": null, - "external_location": null, - "foreign_connection": null, - "function": "main.schema_grants.mymodel", - "grant": [ - { - "principal": "deco-test-user@databricks.com", - "privileges": [ - "APPLY_TAG" - ] - } - ], - "id": "function/main.schema_grants.mymodel", - "mcp_service": null, - "metastore": null, - "model": null, - "model_provider_service": null, - "model_service": null, - "pipeline": null, - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "recipient": null, - "schema": null, - "secret": null, - "share": null, - "storage_credential": null, - "table": null, - "volume": null - }, - "sensitive_attributes": [], - "private": "bnVsbA==", - "dependencies": [ - "databricks_registered_model.my_registered_model", - "databricks_schema.my_schema" - ] - } - ] - }, - { - "mode": "managed", - "type": "databricks_grants", - "name": "schema_my_schema", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 0, - "attributes": { - "catalog": null, - "credential": null, - "external_location": null, - "foreign_connection": null, - "function": null, - "grant": [ - { - "principal": "deco-test-user@databricks.com", - "privileges": [ - "CREATE_TABLE", - "USE_SCHEMA" - ] - } - ], - "id": "schema/main.schema_grants", - "mcp_service": null, - "metastore": null, - "model": null, - "model_provider_service": null, - "model_service": null, - "pipeline": null, - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "recipient": null, - "schema": "main.schema_grants", - "secret": null, - "share": null, - "storage_credential": null, - "table": null, - "volume": null - }, - "sensitive_attributes": [], - "private": "bnVsbA==", - "dependencies": [ - "databricks_schema.my_schema" - ] - } - ] - }, - { - "mode": "managed", - "type": "databricks_grants", - "name": "volume_my_volume", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 0, - "attributes": { - "catalog": null, - "credential": null, - "external_location": null, - "foreign_connection": null, - "function": null, - "grant": [ - { - "principal": "deco-test-user@databricks.com", - "privileges": [ - "READ_VOLUME", - "WRITE_VOLUME" - ] - } - ], - "id": "volume/main.schema_grants.volume_name", - "mcp_service": null, - "metastore": null, - "model": null, - "model_provider_service": null, - "model_service": null, - "pipeline": null, - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "recipient": null, - "schema": null, - "secret": null, - "share": null, - "storage_credential": null, - "table": null, - "volume": "main.schema_grants.volume_name" - }, - "sensitive_attributes": [], - "private": "bnVsbA==", - "dependencies": [ - "databricks_schema.my_schema", - "databricks_volume.my_volume" - ] - } - ] - }, - { - "mode": "managed", - "type": "databricks_registered_model", - "name": "my_registered_model", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 0, - "attributes": { - "aliases": [], - "browse_only": false, - "catalog_name": "main", - "comment": "mycomment", - "created_at": [UNIX_TIME_MILLIS][0], - "created_by": "[USERNAME]", - "full_name": "main.schema_grants.mymodel", - "id": "main.schema_grants.mymodel", - "metastore_id": "[UUID]", - "name": "mymodel", - "owner": "[USERNAME]", - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "schema_name": "schema_grants", - "storage_location": null, - "updated_at": [UNIX_TIME_MILLIS][0], - "updated_by": "[USERNAME]" - }, - "sensitive_attributes": [], - "private": "bnVsbA==", - "dependencies": [ - "databricks_schema.my_schema" - ] - } - ] - }, - { - "mode": "managed", - "type": "databricks_schema", - "name": "my_schema", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 0, - "attributes": { - "catalog_name": "main", - "comment": null, - "enable_predictive_optimization": "INHERIT", - "force_destroy": true, - "id": "main.schema_grants", - "metastore_id": "[UUID]", - "name": "schema_grants", - "owner": "[USERNAME]", - "properties": null, - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "schema_id": "[UUID]", - "storage_root": null - }, - "sensitive_attributes": [], - "private": "bnVsbA==" - } - ] - }, - { - "mode": "managed", - "type": "databricks_volume", - "name": "my_volume", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 0, - "attributes": { - "catalog_name": "main", - "comment": null, - "id": "main.schema_grants.volume_name", - "name": "volume_name", - "owner": "[USERNAME]", - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "schema_name": "schema_grants", - "storage_location": "s3://[METASTORE_NAME]/metastore/[UUID]/volumes/[UUID]", - "volume_path": "/Volumes/main/schema_grants/volume_name", - "volume_type": "MANAGED" - }, - "sensitive_attributes": [], - "private": "bnVsbA==", - "dependencies": [ - "databricks_schema.my_schema" - ] - } - ] - } - ], - "check_results": null -} diff --git a/acceptance/bundle/migrate/grants/out.test.toml b/acceptance/bundle/migrate/grants/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/grants/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/grants/output.txt b/acceptance/bundle/migrate/grants/output.txt deleted file mode 100644 index fd5dc4f046c..00000000000 --- a/acceptance/bundle/migrate/grants/output.txt +++ /dev/null @@ -1,56 +0,0 @@ - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created registered_models.my_registered_model -Created registered_models.my_registered_model.grants -Created schemas.my_schema -Created schemas.my_schema.grants -Created volumes.my_volume -Created volumes.my_volume.grants -Files: 2 uploaded, 0 deleted -Resources: 6 created, 0 changed, 0 deleted, 0 unchanged - ->>> [CLI] bundle deployment migrate -Success! Migrated 6 resources to direct engine state file: [TEST_TMP_DIR]/.databricks/bundle/default/resources.json - -Validate the migration by running "databricks bundle plan", there should be no actions planned. - -The state file is not synchronized to the workspace yet. To do that and finalize the migration, run "bundle deploy". - -To undo the migration, remove [TEST_TMP_DIR]/.databricks/bundle/default/resources.json and rename [TEST_TMP_DIR]/.databricks/bundle/default/terraform/terraform.tfstate.backup to [TEST_TMP_DIR]/.databricks/bundle/default/terraform/terraform.tfstate - - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 6 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 2 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 6 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 6 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 6 unchanged - ->>> print_requests.py --get //unity-catalog/permissions - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 0 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 6 unchanged - ->>> print_requests.py --get //unity-catalog/permissions - -=== Should show that it's already migrated ->>> musterr [CLI] bundle deployment migrate -Error: already using direct engine -Details: [TEST_TMP_DIR]/.databricks/bundle/default/resources.json: local direct state serial=9 lineage="[UUID]" - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle debug states -[TEST_TMP_DIR]/.databricks/bundle/default/resources.json: local direct state serial=9 lineage="[UUID]" - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle debug states --force-pull -resources.json: remote direct state serial=9 lineage="[UUID]" -[TEST_TMP_DIR]/.databricks/bundle/default/resources.json: local direct state serial=9 lineage="[UUID]" diff --git a/acceptance/bundle/migrate/grants/script b/acceptance/bundle/migrate/grants/script deleted file mode 100755 index f53b567d1e2..00000000000 --- a/acceptance/bundle/migrate/grants/script +++ /dev/null @@ -1,26 +0,0 @@ -export DATABRICKS_BUNDLE_ENGINE= -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -print_state.py > out.original_state.json - -trace $CLI bundle deployment migrate 2>&1 | contains.py 'Migrated 6 resources' -print_state.py > out.new_state.json - -# this is expected to warn because state does not match env var, but still succeed using state engine -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle plan -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy - -rm "$OUT_REQUESTS" -# Both DATABRICKS_BUNDLE_ENGINE=direct and DATABRICKS_BUNDLE_ENGINE= work -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle plan | contains.py "6 unchanged" -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle plan | contains.py "6 unchanged" -trace print_requests.py --get //unity-catalog/permissions | contains.py 'engine/direct' > /dev/null - -trace DATABRICKS_BUNDLE_ENGINE="" $CLI bundle deploy -trace print_requests.py --get //unity-catalog/permissions | jq '.headers["User-Agent"][0]' | contains.py 'engine/direct' > LOG.requests_deploy.txt - -title "Should show that it's already migrated" -trace musterr $CLI bundle deployment migrate -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle debug states -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle debug states --force-pull - -rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/migrate/permissions/databricks.yml b/acceptance/bundle/migrate/permissions/databricks.yml deleted file mode 100644 index 8b5f3692bea..00000000000 --- a/acceptance/bundle/migrate/permissions/databricks.yml +++ /dev/null @@ -1,24 +0,0 @@ -bundle: - name: migrate-basic-test - -resources: - jobs: - test_job: - name: "Test Migration Job" - tasks: - - task_key: "main" - notebook_task: - notebook_path: "./notebook.py" - permissions: - - level: CAN_VIEW - user_name: viewer@databricks.com - - pipelines: - test_pipeline: - name: "Test Migration Pipeline" - libraries: - - notebook: - path: "./pipeline.py" - permissions: - - level: CAN_MANAGE - user_name: manager@databricks.com diff --git a/acceptance/bundle/migrate/permissions/notebook.py b/acceptance/bundle/migrate/permissions/notebook.py deleted file mode 100644 index 250b3c9f766..00000000000 --- a/acceptance/bundle/migrate/permissions/notebook.py +++ /dev/null @@ -1,2 +0,0 @@ -# Databricks notebook source -print("Hello from test migration job") diff --git a/acceptance/bundle/migrate/permissions/out.new_state.json b/acceptance/bundle/migrate/permissions/out.new_state.json deleted file mode 100644 index 53d41f1fe45..00000000000 --- a/acceptance/bundle/migrate/permissions/out.new_state.json +++ /dev/null @@ -1,95 +0,0 @@ -{ - "state_version": 3, - "cli_version": "[CLI_VERSION]", - "lineage": "[UUID]", - "serial": 7, - "state": { - "resources.jobs.test_job": { - "__id__": "[NUMID]", - "state": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "Test Migration Job", - "queue": { - "enabled": true - }, - "tasks": [ - { - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/default/files/notebook" - }, - "task_key": "main" - } - ] - } - }, - "resources.jobs.test_job.permissions": { - "__id__": "/jobs/[NUMID]", - "state": { - "object_id": "/jobs/[NUMID]", - "__embed__": [ - { - "level": "CAN_VIEW", - "user_name": "viewer@databricks.com" - }, - { - "level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - }, - "depends_on": [ - { - "node": "resources.jobs.test_job", - "label": "${resources.jobs.test_job.id}" - } - ] - }, - "resources.pipelines.test_pipeline": { - "__id__": "[UUID]", - "state": { - "channel": "CURRENT", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/default/state/metadata.json" - }, - "edition": "ADVANCED", - "libraries": [ - { - "notebook": { - "path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/default/files/pipeline" - } - } - ], - "name": "Test Migration Pipeline" - } - }, - "resources.pipelines.test_pipeline.permissions": { - "__id__": "/pipelines/[UUID]", - "state": { - "object_id": "/pipelines/[UUID]", - "__embed__": [ - { - "level": "CAN_MANAGE", - "user_name": "manager@databricks.com" - }, - { - "level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - }, - "depends_on": [ - { - "node": "resources.pipelines.test_pipeline", - "label": "${resources.pipelines.test_pipeline.id}" - } - ] - } - } -} diff --git a/acceptance/bundle/migrate/permissions/out.original_state.json b/acceptance/bundle/migrate/permissions/out.original_state.json deleted file mode 100644 index c7341d0ea88..00000000000 --- a/acceptance/bundle/migrate/permissions/out.original_state.json +++ /dev/null @@ -1,387 +0,0 @@ -{ - "version": 4, - "terraform_version": "1.5.5", - "serial": 5, - "lineage": "[UUID]", - "outputs": {}, - "resources": [ - { - "mode": "managed", - "type": "databricks_job", - "name": "test_job", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 2, - "attributes": { - "always_running": false, - "budget_policy_id": null, - "continuous": [], - "control_run_state": false, - "dbt_task": [], - "deployment": [ - { - "deployment_id": "", - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/default/state/metadata.json", - "version_id": "" - } - ], - "description": null, - "edit_mode": "UI_LOCKED", - "email_notifications": [ - { - "no_alert_for_skipped_runs": false, - "on_duration_warning_threshold_exceeded": [], - "on_failure": [], - "on_start": [], - "on_streaming_backlog_exceeded": [], - "on_success": [] - } - ], - "environment": [], - "existing_cluster_id": null, - "format": "MULTI_TASK", - "git_source": [], - "health": [], - "id": "[NUMID]", - "job_cluster": [], - "library": [], - "max_concurrent_runs": 1, - "max_retries": 0, - "min_retry_interval_millis": 0, - "name": "Test Migration Job", - "new_cluster": [], - "notebook_task": [], - "notification_settings": [], - "parameter": [], - "parent_path": null, - "performance_target": null, - "pipeline_task": [], - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "python_wheel_task": [], - "queue": [ - { - "enabled": true - } - ], - "retry_on_timeout": false, - "run_as": [ - { - "group_name": "", - "service_principal_name": "", - "user_name": "[USERNAME]" - } - ], - "run_job_task": [], - "schedule": [], - "spark_jar_task": [], - "spark_python_task": [], - "spark_submit_task": [], - "tags": null, - "task": [ - { - "ai_runtime_task": [], - "alert_task": [], - "clean_rooms_notebook_task": [], - "compute": [], - "condition_task": [], - "dashboard_task": [], - "dbt_cloud_task": [], - "dbt_platform_task": [], - "dbt_task": [], - "depends_on": [], - "description": "", - "disable_auto_optimization": false, - "disabled": false, - "email_notifications": [ - { - "no_alert_for_skipped_runs": false, - "on_duration_warning_threshold_exceeded": [], - "on_failure": [], - "on_start": [], - "on_streaming_backlog_exceeded": [], - "on_success": [] - } - ], - "environment_key": "", - "existing_cluster_id": "", - "for_each_task": [], - "gen_ai_compute_task": [], - "health": [], - "job_cluster_key": "", - "library": [], - "max_retries": 0, - "min_retry_interval_millis": 0, - "new_cluster": [], - "notebook_task": [ - { - "base_parameters": null, - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/default/files/notebook", - "source": "WORKSPACE", - "warehouse_id": "" - } - ], - "notification_settings": [], - "pipeline_task": [], - "power_bi_task": [], - "python_operator_task": [], - "python_wheel_task": [], - "retry_on_timeout": false, - "run_if": "ALL_SUCCESS", - "run_job_task": [], - "spark_jar_task": [], - "spark_python_task": [], - "spark_submit_task": [], - "sql_task": [], - "task_key": "main", - "timeout_seconds": 0, - "webhook_notifications": [] - } - ], - "timeout_seconds": 0, - "timeouts": null, - "trigger": [], - "triggers": [], - "url": "[DATABRICKS_URL]/#job/[NUMID]", - "usage_policy_id": null, - "webhook_notifications": [ - { - "on_duration_warning_threshold_exceeded": [], - "on_failure": [], - "on_start": [], - "on_streaming_backlog_exceeded": [], - "on_success": [] - } - ] - }, - "sensitive_attributes": [], - "private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxODAwMDAwMDAwMDAwLCJ1cGRhdGUiOjE4MDAwMDAwMDAwMDB9LCJzY2hlbWFfdmVyc2lvbiI6IjIifQ==" - } - ] - }, - { - "mode": "managed", - "type": "databricks_permissions", - "name": "job_test_job", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 0, - "attributes": { - "access_control": [ - { - "group_name": "", - "permission_level": "CAN_VIEW", - "service_principal_name": "", - "user_name": "viewer@databricks.com" - }, - { - "group_name": "", - "permission_level": "IS_OWNER", - "service_principal_name": "", - "user_name": "[USERNAME]" - } - ], - "alert_v2_id": null, - "app_name": null, - "authorization": null, - "cluster_id": null, - "cluster_policy_id": null, - "dashboard_id": null, - "database_instance_name": null, - "database_project_name": null, - "directory_id": null, - "directory_path": null, - "experiment_id": null, - "id": "/jobs/[NUMID]", - "instance_pool_id": null, - "job_id": "[NUMID]", - "knowledge_assistant_id": null, - "notebook_id": null, - "notebook_path": null, - "object_type": "job", - "pipeline_id": null, - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "registered_model_id": null, - "repo_id": null, - "repo_path": null, - "serving_endpoint_id": null, - "sql_alert_id": null, - "sql_dashboard_id": null, - "sql_endpoint_id": null, - "sql_query_id": null, - "supervisor_agent_id": null, - "vector_search_endpoint_id": null, - "workspace_file_id": null, - "workspace_file_path": null - }, - "sensitive_attributes": [], - "private": "bnVsbA==", - "dependencies": [ - "databricks_job.test_job" - ] - } - ] - }, - { - "mode": "managed", - "type": "databricks_permissions", - "name": "pipeline_test_pipeline", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 0, - "attributes": { - "access_control": [ - { - "group_name": "", - "permission_level": "CAN_MANAGE", - "service_principal_name": "", - "user_name": "manager@databricks.com" - }, - { - "group_name": "", - "permission_level": "IS_OWNER", - "service_principal_name": "", - "user_name": "[USERNAME]" - } - ], - "alert_v2_id": null, - "app_name": null, - "authorization": null, - "cluster_id": null, - "cluster_policy_id": null, - "dashboard_id": null, - "database_instance_name": null, - "database_project_name": null, - "directory_id": null, - "directory_path": null, - "experiment_id": null, - "id": "/pipelines/[UUID]", - "instance_pool_id": null, - "job_id": null, - "knowledge_assistant_id": null, - "notebook_id": null, - "notebook_path": null, - "object_type": "pipelines", - "pipeline_id": "[UUID]", - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "registered_model_id": null, - "repo_id": null, - "repo_path": null, - "serving_endpoint_id": null, - "sql_alert_id": null, - "sql_dashboard_id": null, - "sql_endpoint_id": null, - "sql_query_id": null, - "supervisor_agent_id": null, - "vector_search_endpoint_id": null, - "workspace_file_id": null, - "workspace_file_path": null - }, - "sensitive_attributes": [], - "private": "bnVsbA==", - "dependencies": [ - "databricks_pipeline.test_pipeline" - ] - } - ] - }, - { - "mode": "managed", - "type": "databricks_pipeline", - "name": "test_pipeline", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 0, - "attributes": { - "allow_duplicate_names": false, - "budget_policy_id": null, - "catalog": null, - "cause": null, - "channel": "CURRENT", - "cluster": [], - "cluster_id": null, - "configuration": null, - "continuous": false, - "creator_user_name": "[USERNAME]", - "deployment": [ - { - "deployment_id": "", - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/default/state/metadata.json", - "version_id": "" - } - ], - "development": false, - "edition": "ADVANCED", - "environment": [], - "event_log": [], - "expected_last_modified": 0, - "filters": [], - "gateway_definition": [], - "health": null, - "id": "[UUID]", - "ingestion_definition": [], - "last_modified": [UNIX_TIME_MILLIS], - "latest_updates": null, - "library": [ - { - "file": [], - "glob": [], - "jar": "", - "maven": [], - "notebook": [ - { - "path": "/Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/default/files/pipeline" - } - ], - "whl": "" - } - ], - "name": "Test Migration Pipeline", - "notification": [], - "photon": false, - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "restart_window": [], - "root_path": null, - "run_as": [], - "run_as_user_name": "[USERNAME]", - "schema": null, - "serverless": false, - "serverless_compute_id": null, - "state": "IDLE", - "storage": "dbfs:/pipelines/[UUID]", - "tags": null, - "target": null, - "timeouts": null, - "trigger": [], - "url": "[DATABRICKS_URL]/#joblist/pipelines/[UUID]", - "usage_policy_id": null - }, - "sensitive_attributes": [], - "private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWZhdWx0IjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjEyMDAwMDAwMDAwMDAsInVwZGF0ZSI6MTIwMDAwMDAwMDAwMH19" - } - ] - } - ], - "check_results": null -} diff --git a/acceptance/bundle/migrate/permissions/out.test.toml b/acceptance/bundle/migrate/permissions/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/permissions/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/permissions/output.txt b/acceptance/bundle/migrate/permissions/output.txt deleted file mode 100644 index 913a4bf012e..00000000000 --- a/acceptance/bundle/migrate/permissions/output.txt +++ /dev/null @@ -1,72 +0,0 @@ - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/default/files... -Created jobs.test_job -Created jobs.test_job.permissions -Created pipelines.test_pipeline -Created pipelines.test_pipeline.permissions -Files: 5 uploaded, 0 deleted -Resources: 4 created, 0 changed, 0 deleted, 0 unchanged - ->>> [CLI] bundle deployment migrate -Success! Migrated 4 resources to direct engine state file: [TEST_TMP_DIR]/.databricks/bundle/default/resources.json - -Validate the migration by running "databricks bundle plan", there should be no actions planned. - -The state file is not synchronized to the workspace yet. To do that and finalize the migration, run "bundle deploy". - -To undo the migration, remove [TEST_TMP_DIR]/.databricks/bundle/default/resources.json and rename [TEST_TMP_DIR]/.databricks/bundle/default/terraform/terraform.tfstate.backup to [TEST_TMP_DIR]/.databricks/bundle/default/terraform/terraform.tfstate - - ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 4 unchanged - ->>> [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 4 unchanged - ->>> print_requests.py --get //jobs/get -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none engine/direct auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.2/jobs/get", - "q": { - "job_id": "[NUMID]" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none engine/direct auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.2/jobs/get", - "q": { - "job_id": "[NUMID]" - } -} - ->>> [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/default/files... -Files: 2 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 4 unchanged - ->>> print_requests.py --get //jobs/get -"cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/direct auth/pat" -"cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/direct auth/pat" - -=== Should show that it's already migrated ->>> musterr [CLI] bundle deployment migrate -Error: already using direct engine -Details: [TEST_TMP_DIR]/.databricks/bundle/default/resources.json: local direct state serial=7 lineage="[UUID]" - ->>> [CLI] bundle debug states -[TEST_TMP_DIR]/.databricks/bundle/default/resources.json: local direct state serial=7 lineage="[UUID]" - ->>> [CLI] bundle debug states --force-pull -resources.json: remote direct state serial=7 lineage="[UUID]" -[TEST_TMP_DIR]/.databricks/bundle/default/resources.json: local direct state serial=7 lineage="[UUID]" diff --git a/acceptance/bundle/migrate/permissions/pipeline.py b/acceptance/bundle/migrate/permissions/pipeline.py deleted file mode 100644 index cd19031e962..00000000000 --- a/acceptance/bundle/migrate/permissions/pipeline.py +++ /dev/null @@ -1,2 +0,0 @@ -# Databricks notebook source -# This is a test pipeline notebook diff --git a/acceptance/bundle/migrate/permissions/script b/acceptance/bundle/migrate/permissions/script deleted file mode 100755 index f2ef76cc34d..00000000000 --- a/acceptance/bundle/migrate/permissions/script +++ /dev/null @@ -1,23 +0,0 @@ -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -print_state.py > out.original_state.json - -trace $CLI bundle deployment migrate 2>&1 | contains.py 'Migrated 4 resources' -print_state.py > out.new_state.json - -export DATABRICKS_BUNDLE_ENGINE= - -rm "$OUT_REQUESTS" -# Both DATABRICKS_BUNDLE_ENGINE=direct and DATABRICKS_BUNDLE_ENGINE= work -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle plan | contains.py "4 unchanged" -trace $CLI bundle plan | contains.py "4 unchanged" -trace print_requests.py --get //jobs/get | contains.py 'engine/direct' - -trace $CLI bundle deploy -trace print_requests.py --get //jobs/get | jq '.headers["User-Agent"][0]' | contains.py 'engine/direct' - -title "Should show that it's already migrated" -trace musterr $CLI bundle deployment migrate -trace $CLI bundle debug states -trace $CLI bundle debug states --force-pull - -rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/migrate/permissions/test.toml b/acceptance/bundle/migrate/permissions/test.toml deleted file mode 100644 index e25c2749483..00000000000 --- a/acceptance/bundle/migrate/permissions/test.toml +++ /dev/null @@ -1,2 +0,0 @@ -RecordRequests = true -IncludeRequestHeaders = ["User-Agent"] diff --git a/acceptance/bundle/migrate/profile_arg/databricks.yml b/acceptance/bundle/migrate/profile_arg/databricks.yml deleted file mode 100644 index fac4e543d9e..00000000000 --- a/acceptance/bundle/migrate/profile_arg/databricks.yml +++ /dev/null @@ -1,21 +0,0 @@ -bundle: - name: migrate-basic-test - -resources: - jobs: - test_job: - name: "Test Migration Job" - tasks: - - task_key: "main" - notebook_task: - notebook_path: "./notebook.py" - -targets: - dev: - default: true - prod: - resources: - schemas: - test_schema: - catalog_name: mycat - name: myschema diff --git a/acceptance/bundle/migrate/profile_arg/notebook.py b/acceptance/bundle/migrate/profile_arg/notebook.py deleted file mode 100644 index 250b3c9f766..00000000000 --- a/acceptance/bundle/migrate/profile_arg/notebook.py +++ /dev/null @@ -1,2 +0,0 @@ -# Databricks notebook source -print("Hello from test migration job") diff --git a/acceptance/bundle/migrate/profile_arg/out.test.toml b/acceptance/bundle/migrate/profile_arg/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/profile_arg/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/profile_arg/output.txt b/acceptance/bundle/migrate/profile_arg/output.txt deleted file mode 100644 index 01f7e6deb45..00000000000 --- a/acceptance/bundle/migrate/profile_arg/output.txt +++ /dev/null @@ -1,33 +0,0 @@ - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/dev/files... -Created jobs.test_job -Files: 5 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged - ->>> [CLI] bundle deployment migrate -p non_existent321 -Success! Migrated 1 resources to direct engine state file: [TEST_TMP_DIR]/.databricks/bundle/dev/resources.json - -Validate the migration by running "databricks bundle plan -p non_existent321", there should be no actions planned. - -The state file is not synchronized to the workspace yet. To do that and finalize the migration, run "bundle deploy -p non_existent321". - -To undo the migration, remove [TEST_TMP_DIR]/.databricks/bundle/dev/resources.json and rename [TEST_TMP_DIR]/.databricks/bundle/dev/terraform/terraform.tfstate.backup to [TEST_TMP_DIR]/.databricks/bundle/dev/terraform/terraform.tfstate - - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -t prod -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/migrate-basic-test/prod/files... -Created jobs.test_job -Created schemas.test_schema -Files: 5 uploaded, 0 deleted -Resources: 2 created, 0 changed, 0 deleted, 0 unchanged - ->>> [CLI] bundle deployment migrate -p non_existent321 -t prod -Success! Migrated 2 resources to direct engine state file: [TEST_TMP_DIR]/.databricks/bundle/prod/resources.json - -Validate the migration by running "databricks bundle plan -t prod -p non_existent321", there should be no actions planned. - -The state file is not synchronized to the workspace yet. To do that and finalize the migration, run "bundle deploy -t prod -p non_existent321". - -To undo the migration, remove [TEST_TMP_DIR]/.databricks/bundle/prod/resources.json and rename [TEST_TMP_DIR]/.databricks/bundle/prod/terraform/terraform.tfstate.backup to [TEST_TMP_DIR]/.databricks/bundle/prod/terraform/terraform.tfstate - diff --git a/acceptance/bundle/migrate/profile_arg/pipeline.py b/acceptance/bundle/migrate/profile_arg/pipeline.py deleted file mode 100644 index cd19031e962..00000000000 --- a/acceptance/bundle/migrate/profile_arg/pipeline.py +++ /dev/null @@ -1,2 +0,0 @@ -# Databricks notebook source -# This is a test pipeline notebook diff --git a/acceptance/bundle/migrate/profile_arg/script b/acceptance/bundle/migrate/profile_arg/script deleted file mode 100755 index 9e3c242cf1e..00000000000 --- a/acceptance/bundle/migrate/profile_arg/script +++ /dev/null @@ -1,7 +0,0 @@ -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy - -# only interested in output here; for some reason in test env -p is not validated -trace $CLI bundle deployment migrate -p non_existent321 - -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -t prod -trace $CLI bundle deployment migrate -p non_existent321 -t prod diff --git a/acceptance/bundle/migrate/profile_arg/test.toml b/acceptance/bundle/migrate/profile_arg/test.toml deleted file mode 100644 index a030353d571..00000000000 --- a/acceptance/bundle/migrate/profile_arg/test.toml +++ /dev/null @@ -1 +0,0 @@ -RecordRequests = false diff --git a/acceptance/bundle/migrate/removed/databricks.yml b/acceptance/bundle/migrate/removed/databricks.yml deleted file mode 100644 index 3495c042502..00000000000 --- a/acceptance/bundle/migrate/removed/databricks.yml +++ /dev/null @@ -1,7 +0,0 @@ -bundle: - name: migrate-removed-test - -resources: - jobs: - job_a: {name: "Job A"} - job_b: {name: "Job B"} diff --git a/acceptance/bundle/migrate/removed/out.test.toml b/acceptance/bundle/migrate/removed/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/removed/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/removed/output.txt b/acceptance/bundle/migrate/removed/output.txt deleted file mode 100644 index c9289b973f3..00000000000 --- a/acceptance/bundle/migrate/removed/output.txt +++ /dev/null @@ -1,45 +0,0 @@ - ->>> [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/migrate-removed-test/default/files... -Created jobs.job_a -Created jobs.job_b -Files: 2 uploaded, 0 deleted -Resources: 2 created, 0 changed, 0 deleted, 0 unchanged - ->>> [CLI] bundle deployment migrate -Success! Migrated 2 resources to direct engine state file: [TEST_TMP_DIR]/.databricks/bundle/default/resources.json - -Validate the migration by running "databricks bundle plan", there should be no actions planned. - -The state file is not synchronized to the workspace yet. To do that and finalize the migration, run "bundle deploy". - -To undo the migration, remove [TEST_TMP_DIR]/.databricks/bundle/default/resources.json and rename [TEST_TMP_DIR]/.databricks/bundle/default/terraform/terraform.tfstate.backup to [TEST_TMP_DIR]/.databricks/bundle/default/terraform/terraform.tfstate - - ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle plan -delete jobs.job_b - -Plan: 0 to add, 0 to change, 1 to delete, 1 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/migrate-removed-test/default/files... -Deleted jobs.job_b -Files: 1 uploaded, 0 deleted -Resources: 0 created, 0 changed, 1 deleted, 1 unchanged - ->>> print_requests.py //jobs/delete -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/direct auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.2/jobs/delete", - "body": { - "job_id": [NUMID] - } -} - ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 1 unchanged diff --git a/acceptance/bundle/migrate/removed/script b/acceptance/bundle/migrate/removed/script deleted file mode 100644 index 9e53c7991b6..00000000000 --- a/acceptance/bundle/migrate/removed/script +++ /dev/null @@ -1,23 +0,0 @@ -export DATABRICKS_BUNDLE_ENGINE=terraform - -# Deploy with terraform (both job_a and job_b) -trace $CLI bundle deploy - -# Remove job_b from config without deploying the deletion -grep -v job_b databricks.yml > databricks_tmp.yml && mv databricks_tmp.yml databricks.yml - -# job_b's ID preserved in direct state for deletion on next deploy -trace $CLI bundle deployment migrate - -# After migration: plan shows job_b as "to delete" -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle plan | contains.py "1 to delete" - -# Deploy deletes job_b; verify via recorded requests -rm "$OUT_REQUESTS" -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle deploy -trace print_requests.py //jobs/delete - -# No further actions planned -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle plan | contains.py "1 unchanged" - -rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/migrate/runas/databricks.yml.tmpl b/acceptance/bundle/migrate/runas/databricks.yml.tmpl deleted file mode 100644 index f3d7f72f756..00000000000 --- a/acceptance/bundle/migrate/runas/databricks.yml.tmpl +++ /dev/null @@ -1,29 +0,0 @@ -bundle: - name: dabs_revenue-$UNIQUE_NAME - -permissions: - - level: CAN_VIEW - group_name: users - -resources: - pipelines: - foo: - name: DABs Revenue Pipeline - - libraries: - - notebook: - path: sql.sql - - serverless: true - -targets: - production: - run_as: - service_principal_name: $TEST_SP_APPLICATION_ID - - resources: - pipelines: - # Make the pipeline write to the team's schema in logfood. - foo: - catalog: main - target: team_eng_deco diff --git a/acceptance/bundle/migrate/runas/out.create_requests.json b/acceptance/bundle/migrate/runas/out.create_requests.json deleted file mode 100644 index 2a195b271c4..00000000000 --- a/acceptance/bundle/migrate/runas/out.create_requests.json +++ /dev/null @@ -1,52 +0,0 @@ -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5 sdk/sdkv2 resource/pipeline auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.0/pipelines", - "body": { - "catalog": "main", - "channel": "CURRENT", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/dabs_revenue-[UNIQUE_NAME]/production/state/metadata.json" - }, - "edition": "ADVANCED", - "libraries": [ - { - "notebook": { - "path": "/Workspace/Users/[USERNAME]/.bundle/dabs_revenue-[UNIQUE_NAME]/production/files/sql" - } - } - ], - "name": "DABs Revenue Pipeline", - "run_as": { - "service_principal_name": "[UUID]" - }, - "serverless": true, - "target": "team_eng_deco" - } -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5 sdk/sdkv2 resource/permissions auth/pat" - ] - }, - "method": "PUT", - "path": "/api/2.0/permissions/pipelines/[UUID]", - "body": { - "access_control_list": [ - { - "group_name": "users", - "permission_level": "CAN_VIEW" - }, - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/migrate/runas/out.new_state.json b/acceptance/bundle/migrate/runas/out.new_state.json deleted file mode 100644 index 134f7aff689..00000000000 --- a/acceptance/bundle/migrate/runas/out.new_state.json +++ /dev/null @@ -1,55 +0,0 @@ -{ - "state_version": 3, - "cli_version": "[CLI_VERSION]", - "lineage": "[UUID]", - "serial": 5, - "state": { - "resources.pipelines.foo": { - "__id__": "[UUID]", - "state": { - "catalog": "main", - "channel": "CURRENT", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/dabs_revenue-[UNIQUE_NAME]/production/state/metadata.json" - }, - "edition": "ADVANCED", - "libraries": [ - { - "notebook": { - "path": "/Workspace/Users/[USERNAME]/.bundle/dabs_revenue-[UNIQUE_NAME]/production/files/sql" - } - } - ], - "name": "DABs Revenue Pipeline", - "run_as": { - "service_principal_name": "[UUID]" - }, - "serverless": true, - "target": "team_eng_deco" - } - }, - "resources.pipelines.foo.permissions": { - "__id__": "/pipelines/[UUID]", - "state": { - "object_id": "/pipelines/[UUID]", - "__embed__": [ - { - "level": "CAN_VIEW", - "group_name": "users" - }, - { - "level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - }, - "depends_on": [ - { - "node": "resources.pipelines.foo", - "label": "${resources.pipelines.foo.id}" - } - ] - } - } -} diff --git a/acceptance/bundle/migrate/runas/out.old_state.json b/acceptance/bundle/migrate/runas/out.old_state.json deleted file mode 100644 index b4e73651400..00000000000 --- a/acceptance/bundle/migrate/runas/out.old_state.json +++ /dev/null @@ -1,165 +0,0 @@ -{ - "version": 4, - "terraform_version": "1.5.5", - "serial": 3, - "lineage": "[UUID]", - "outputs": {}, - "resources": [ - { - "mode": "managed", - "type": "databricks_permissions", - "name": "pipeline_foo", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 0, - "attributes": { - "access_control": [ - { - "group_name": "", - "permission_level": "IS_OWNER", - "service_principal_name": "", - "user_name": "[USERNAME]" - }, - { - "group_name": "users", - "permission_level": "CAN_VIEW", - "service_principal_name": "", - "user_name": "" - } - ], - "alert_v2_id": null, - "app_name": null, - "authorization": null, - "cluster_id": null, - "cluster_policy_id": null, - "dashboard_id": null, - "database_instance_name": null, - "database_project_name": null, - "directory_id": null, - "directory_path": null, - "experiment_id": null, - "id": "/pipelines/[UUID]", - "instance_pool_id": null, - "job_id": null, - "knowledge_assistant_id": null, - "notebook_id": null, - "notebook_path": null, - "object_type": "pipelines", - "pipeline_id": "[UUID]", - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "registered_model_id": null, - "repo_id": null, - "repo_path": null, - "serving_endpoint_id": null, - "sql_alert_id": null, - "sql_dashboard_id": null, - "sql_endpoint_id": null, - "sql_query_id": null, - "supervisor_agent_id": null, - "vector_search_endpoint_id": null, - "workspace_file_id": null, - "workspace_file_path": null - }, - "sensitive_attributes": [], - "private": "bnVsbA==", - "dependencies": [ - "databricks_pipeline.foo" - ] - } - ] - }, - { - "mode": "managed", - "type": "databricks_pipeline", - "name": "foo", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 0, - "attributes": { - "allow_duplicate_names": false, - "budget_policy_id": null, - "catalog": "main", - "cause": null, - "channel": "CURRENT", - "cluster": [], - "cluster_id": null, - "configuration": null, - "continuous": false, - "creator_user_name": "[USERNAME]", - "deployment": [ - { - "deployment_id": "", - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/dabs_revenue-[UNIQUE_NAME]/production/state/metadata.json", - "version_id": "" - } - ], - "development": false, - "edition": "ADVANCED", - "environment": [], - "event_log": [], - "expected_last_modified": 0, - "filters": [], - "gateway_definition": [], - "health": null, - "id": "[UUID]", - "ingestion_definition": [], - "last_modified": [UNIX_TIME_MILLIS], - "latest_updates": null, - "library": [ - { - "file": [], - "glob": [], - "jar": "", - "maven": [], - "notebook": [ - { - "path": "/Workspace/Users/[USERNAME]/.bundle/dabs_revenue-[UNIQUE_NAME]/production/files/sql" - } - ], - "whl": "" - } - ], - "name": "DABs Revenue Pipeline", - "notification": [], - "photon": false, - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "restart_window": [], - "root_path": null, - "run_as": [ - { - "service_principal_name": "[UUID]", - "user_name": "" - } - ], - "run_as_user_name": "[USERNAME]", - "schema": null, - "serverless": true, - "serverless_compute_id": null, - "state": "IDLE", - "storage": null, - "tags": null, - "target": "team_eng_deco", - "timeouts": null, - "trigger": [], - "url": "[DATABRICKS_URL]/#joblist/pipelines/[UUID]", - "usage_policy_id": null - }, - "sensitive_attributes": [], - "private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWZhdWx0IjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjEyMDAwMDAwMDAwMDAsInVwZGF0ZSI6MTIwMDAwMDAwMDAwMH19" - } - ] - } - ], - "check_results": null -} diff --git a/acceptance/bundle/migrate/runas/out.pipelines_get.json b/acceptance/bundle/migrate/runas/out.pipelines_get.json deleted file mode 100644 index fb06fd6bdb6..00000000000 --- a/acceptance/bundle/migrate/runas/out.pipelines_get.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "creator_user_name": "[USERNAME]", - "effective_publishing_mode": "DEFAULT_PUBLISHING_MODE", - "last_modified": [UNIX_TIME_MILLIS], - "name": "DABs Revenue Pipeline", - "pipeline_id": "[UUID]", - "run_as": { - "service_principal_name": "[UUID]" - }, - "run_as_user_name": "[USERNAME]", - "spec": { - "catalog": "main", - "channel": "CURRENT", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/dabs_revenue-[UNIQUE_NAME]/production/state/metadata.json" - }, - "edition": "ADVANCED", - "id": "[UUID]", - "libraries": [ - { - "notebook": { - "path": "/Workspace/Users/[USERNAME]/.bundle/dabs_revenue-[UNIQUE_NAME]/production/files/sql" - } - } - ], - "name": "DABs Revenue Pipeline", - "serverless": true, - "target": "team_eng_deco" - }, - "state": "IDLE" -} diff --git a/acceptance/bundle/migrate/runas/out.plan.json b/acceptance/bundle/migrate/runas/out.plan.json deleted file mode 100644 index 3c6a3717007..00000000000 --- a/acceptance/bundle/migrate/runas/out.plan.json +++ /dev/null @@ -1,62 +0,0 @@ -{ - "plan_version": [PLAN_VERSION], - "cli_version": "[CLI_VERSION]", - "lineage": "[UUID]", - "serial": 5, - "plan": { - "resources.pipelines.foo": { - "action": "skip", - "remote_state": { - "catalog": "main", - "channel": "CURRENT", - "creator_user_name": "[USERNAME]", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/dabs_revenue-[UNIQUE_NAME]/production/state/metadata.json" - }, - "edition": "ADVANCED", - "effective_publishing_mode": "DEFAULT_PUBLISHING_MODE", - "id": "[UUID]", - "last_modified": [UNIX_TIME_MILLIS], - "libraries": [ - { - "notebook": { - "path": "/Workspace/Users/[USERNAME]/.bundle/dabs_revenue-[UNIQUE_NAME]/production/files/sql" - } - } - ], - "name": "DABs Revenue Pipeline", - "pipeline_id": "[UUID]", - "run_as": { - "service_principal_name": "[UUID]" - }, - "run_as_user_name": "[USERNAME]", - "serverless": true, - "state": "IDLE", - "target": "team_eng_deco" - } - }, - "resources.pipelines.foo.permissions": { - "depends_on": [ - { - "node": "resources.pipelines.foo", - "label": "${resources.pipelines.foo.id}" - } - ], - "action": "skip", - "remote_state": { - "object_id": "/pipelines/[UUID]", - "__embed__": [ - { - "level": "CAN_VIEW", - "group_name": "users" - }, - { - "level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } - } - } -} diff --git a/acceptance/bundle/migrate/runas/out.test.toml b/acceptance/bundle/migrate/runas/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/runas/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/runas/output.txt b/acceptance/bundle/migrate/runas/output.txt deleted file mode 100644 index 71faf2c5903..00000000000 --- a/acceptance/bundle/migrate/runas/output.txt +++ /dev/null @@ -1,147 +0,0 @@ - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle plan -Recommendation: permissions section should explicitly include the current deployment identity '[USERNAME]' or one of its groups -If it is not included, CAN_MANAGE permissions are only applied if the present identity is used to deploy. - -Consider using a adding a top-level permissions section such as the following: - - permissions: - - user_name: [USERNAME] - level: CAN_MANAGE - -See https://docs.databricks.com/dev-tools/bundles/permissions.html to learn more about permission configuration. - in databricks.yml:5:3 - -create pipelines.foo -create pipelines.foo.permissions - -Plan: 2 to add, 0 to change, 0 to delete, 0 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Recommendation: permissions section should explicitly include the current deployment identity '[USERNAME]' or one of its groups -If it is not included, CAN_MANAGE permissions are only applied if the present identity is used to deploy. - -Consider using a adding a top-level permissions section such as the following: - - permissions: - - user_name: [USERNAME] - level: CAN_MANAGE - -See https://docs.databricks.com/dev-tools/bundles/permissions.html to learn more about permission configuration. - in databricks.yml:5:3 - -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/dabs_revenue-[UNIQUE_NAME]/production/files... -Created pipelines.foo -Created pipelines.foo.permissions -Files: 5 uploaded, 0 deleted -Resources: 2 created, 0 changed, 0 deleted, 0 unchanged - ->>> print_requests.py //pipelines - ->>> print_state.py -Recommendation: permissions section should explicitly include the current deployment identity '[USERNAME]' or one of its groups -If it is not included, CAN_MANAGE permissions are only applied if the present identity is used to deploy. - -Consider using a adding a top-level permissions section such as the following: - - permissions: - - user_name: [USERNAME] - level: CAN_MANAGE - -See https://docs.databricks.com/dev-tools/bundles/permissions.html to learn more about permission configuration. - in databricks.yml:5:3 - - ->>> [CLI] pipelines get [UUID] - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle plan -Recommendation: permissions section should explicitly include the current deployment identity '[USERNAME]' or one of its groups -If it is not included, CAN_MANAGE permissions are only applied if the present identity is used to deploy. - -Consider using a adding a top-level permissions section such as the following: - - permissions: - - user_name: [USERNAME] - level: CAN_MANAGE - -See https://docs.databricks.com/dev-tools/bundles/permissions.html to learn more about permission configuration. - in databricks.yml:5:3 - -Plan: 0 to add, 0 to change, 0 to delete, 2 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle deployment migrate -Recommendation: permissions section should explicitly include the current deployment identity '[USERNAME]' or one of its groups -If it is not included, CAN_MANAGE permissions are only applied if the present identity is used to deploy. - -Consider using a adding a top-level permissions section such as the following: - - permissions: - - user_name: [USERNAME] - level: CAN_MANAGE - -See https://docs.databricks.com/dev-tools/bundles/permissions.html to learn more about permission configuration. - in databricks.yml:5:3 - -Success! Migrated 2 resources to direct engine state file: [TEST_TMP_DIR]/.databricks/bundle/production/resources.json - -Validate the migration by running "databricks bundle plan", there should be no actions planned. - -The state file is not synchronized to the workspace yet. To do that and finalize the migration, run "bundle deploy". - -To undo the migration, remove [TEST_TMP_DIR]/.databricks/bundle/production/resources.json and rename [TEST_TMP_DIR]/.databricks/bundle/production/terraform/terraform.tfstate.backup to [TEST_TMP_DIR]/.databricks/bundle/production/terraform/terraform.tfstate - - ->>> print_state.py - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle plan -Recommendation: permissions section should explicitly include the current deployment identity '[USERNAME]' or one of its groups -If it is not included, CAN_MANAGE permissions are only applied if the present identity is used to deploy. - -Consider using a adding a top-level permissions section such as the following: - - permissions: - - user_name: [USERNAME] - level: CAN_MANAGE - -See https://docs.databricks.com/dev-tools/bundles/permissions.html to learn more about permission configuration. - in databricks.yml:5:3 - -Plan: 0 to add, 0 to change, 0 to delete, 2 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle plan -o json -Recommendation: permissions section should explicitly include the current deployment identity '[USERNAME]' or one of its groups -If it is not included, CAN_MANAGE permissions are only applied if the present identity is used to deploy. - -Consider using a adding a top-level permissions section such as the following: - - permissions: - - user_name: [USERNAME] - level: CAN_MANAGE - -See https://docs.databricks.com/dev-tools/bundles/permissions.html to learn more about permission configuration. - in databricks.yml:5:3 - - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle destroy --auto-approve -Recommendation: permissions section should explicitly include the current deployment identity '[USERNAME]' or one of its groups -If it is not included, CAN_MANAGE permissions are only applied if the present identity is used to deploy. - -Consider using a adding a top-level permissions section such as the following: - - permissions: - - user_name: [USERNAME] - level: CAN_MANAGE - -See https://docs.databricks.com/dev-tools/bundles/permissions.html to learn more about permission configuration. - in databricks.yml:5:3 - -The following resources will be deleted: - delete resources.pipelines.foo - -This action will result in the deletion of the following Lakeflow Spark Declarative Pipelines along with the -Streaming Tables (STs) and Materialized Views (MVs) managed by them. Set 'cascade_on_destroy: false' on a pipeline to retain datasets on pipeline deletion: - delete resources.pipelines.foo - -All files and directories at the following location will be deleted: /Workspace/Users/[USERNAME]/.bundle/dabs_revenue-[UNIQUE_NAME]/production - -Destroy: 1 deleted diff --git a/acceptance/bundle/migrate/runas/script b/acceptance/bundle/migrate/runas/script deleted file mode 100644 index c852cbfb865..00000000000 --- a/acceptance/bundle/migrate/runas/script +++ /dev/null @@ -1,26 +0,0 @@ -if [ -z "${TEST_SP_APPLICATION_ID+x}" ]; then - export TEST_SP_APPLICATION_ID="123b0db3-ba48-4e12-be3b-3b7898cdf000" -fi - -envsubst < databricks.yml.tmpl > databricks.yml -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle plan - -cleanup() { - trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle destroy --auto-approve - rm -f "$OUT_REQUESTS" -} - -trap cleanup EXIT - -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -trace print_requests.py //pipelines > out.create_requests.json -trace print_state.py > out.old_state.json - -pipeline_id=$(DATABRICKS_BUNDLE_ENGINE= $CLI bundle summary --output json | jq -r '.resources.pipelines.foo.id') -trace $CLI pipelines get $pipeline_id > out.pipelines_get.json - -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle plan -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle deployment migrate -trace print_state.py > out.new_state.json -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle plan -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle plan -o json | nostamp > out.plan.json diff --git a/acceptance/bundle/migrate/runas/sql.sql b/acceptance/bundle/migrate/runas/sql.sql deleted file mode 100644 index ae23affadae..00000000000 --- a/acceptance/bundle/migrate/runas/sql.sql +++ /dev/null @@ -1 +0,0 @@ --- Databricks notebook source diff --git a/acceptance/bundle/migrate/runas/test.toml b/acceptance/bundle/migrate/runas/test.toml deleted file mode 100644 index c2c37f10ee1..00000000000 --- a/acceptance/bundle/migrate/runas/test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -RecordRequests = true -Ignore = [".databricks"] diff --git a/acceptance/bundle/migrate/script.prepare b/acceptance/bundle/migrate/script.prepare deleted file mode 100644 index e99f29a8307..00000000000 --- a/acceptance/bundle/migrate/script.prepare +++ /dev/null @@ -1,7 +0,0 @@ -# Filter print_telemetry_bool_values output to auto-migration keys -# (direct_drymigrate_*, direct_migrate_*, direct_migrated_via_*). Callers -# clear "$OUT_REQUESTS" themselves; some tests want to keep it for a -# subsequent print_requests.py assertion. -print_migration_telemetry() { - print_telemetry_bool_values | grep '^direct_' || true -} diff --git a/acceptance/bundle/migrate/test.toml b/acceptance/bundle/migrate/test.toml deleted file mode 100644 index 517f5524ecb..00000000000 --- a/acceptance/bundle/migrate/test.toml +++ /dev/null @@ -1,14 +0,0 @@ -Cloud = false -RecordRequests = true -IncludeRequestHeaders = ["User-Agent"] -Ignore = [".databricks"] - -# Each test's script sets DATABRICKS_BUNDLE_ENGINE inline; pin the outer -# matrix to ["direct"] so CI's engine filter includes these tests without -# also running the same script twice per engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] - -# These tests deploy on terraform and then migrate to direct. Recording is direct-only, so -# the terraform half is recorded nowhere and the migration reads state the service lacks. -# Migrating an existing deployment onto the service is its own story. -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/var_arg/databricks.yml b/acceptance/bundle/migrate/var_arg/databricks.yml deleted file mode 100644 index ebe1af133c6..00000000000 --- a/acceptance/bundle/migrate/var_arg/databricks.yml +++ /dev/null @@ -1,19 +0,0 @@ -bundle: - name: migrate-var-test - -variables: - job_name: - default: "Default Job Name" - -resources: - jobs: - test_job: - name: "${var.job_name}" - tasks: - - task_key: "main" - notebook_task: - notebook_path: "./notebook.py" - -targets: - dev: - default: true diff --git a/acceptance/bundle/migrate/var_arg/notebook.py b/acceptance/bundle/migrate/var_arg/notebook.py deleted file mode 100644 index 898eaf1c57d..00000000000 --- a/acceptance/bundle/migrate/var_arg/notebook.py +++ /dev/null @@ -1,2 +0,0 @@ -# Databricks notebook source -print("Hello from notebook") diff --git a/acceptance/bundle/migrate/var_arg/out.test.toml b/acceptance/bundle/migrate/var_arg/out.test.toml deleted file mode 100644 index 27ec2a7fcd6..00000000000 --- a/acceptance/bundle/migrate/var_arg/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/migrate/var_arg/output.txt b/acceptance/bundle/migrate/var_arg/output.txt deleted file mode 100644 index 2c883691705..00000000000 --- a/acceptance/bundle/migrate/var_arg/output.txt +++ /dev/null @@ -1,60 +0,0 @@ - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy --var=job_name=Custom Job Name -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/migrate-var-test/dev/files... -Created jobs.test_job -Files: 4 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged - ->>> [CLI] bundle deployment migrate --var=job_name=Custom Job Name -Success! Migrated 1 resources to direct engine state file: [TEST_TMP_DIR]/.databricks/bundle/dev/resources.json - -Validate the migration by running "databricks bundle plan --var 'job_name=Custom Job Name'", there should be no actions planned. - -The state file is not synchronized to the workspace yet. To do that and finalize the migration, run "bundle deploy --var 'job_name=Custom Job Name'". - -To undo the migration, remove [TEST_TMP_DIR]/.databricks/bundle/dev/resources.json and rename [TEST_TMP_DIR]/.databricks/bundle/dev/terraform/terraform.tfstate.backup to [TEST_TMP_DIR]/.databricks/bundle/dev/terraform/terraform.tfstate - - ->>> print_state.py -"Custom Job Name" - ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle plan --var=job_name=Custom Job Name -Plan: 0 to add, 0 to change, 0 to delete, 1 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle destroy --var=job_name=Custom Job Name --auto-approve -The following resources will be deleted: - delete resources.jobs.test_job - -All files and directories at the following location will be deleted: /Workspace/Users/[USERNAME]/.bundle/migrate-var-test/dev - -Destroy: 1 deleted - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy --var job_name=Custom Job Name -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/migrate-var-test/dev/files... -Created jobs.test_job -Files: 4 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged - ->>> [CLI] bundle deployment migrate --var job_name=Custom Job Name -Success! Migrated 1 resources to direct engine state file: [TEST_TMP_DIR]/.databricks/bundle/dev/resources.json - -Validate the migration by running "databricks bundle plan --var 'job_name=Custom Job Name'", there should be no actions planned. - -The state file is not synchronized to the workspace yet. To do that and finalize the migration, run "bundle deploy --var 'job_name=Custom Job Name'". - -To undo the migration, remove [TEST_TMP_DIR]/.databricks/bundle/dev/resources.json and rename [TEST_TMP_DIR]/.databricks/bundle/dev/terraform/terraform.tfstate.backup to [TEST_TMP_DIR]/.databricks/bundle/dev/terraform/terraform.tfstate - - ->>> print_state.py -"Custom Job Name" - ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle plan --var job_name=Custom Job Name -Plan: 0 to add, 0 to change, 0 to delete, 1 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle destroy --var=job_name=Custom Job Name --auto-approve -The following resources will be deleted: - delete resources.jobs.test_job - -All files and directories at the following location will be deleted: /Workspace/Users/[USERNAME]/.bundle/migrate-var-test/dev - -Destroy: 1 deleted diff --git a/acceptance/bundle/migrate/var_arg/script b/acceptance/bundle/migrate/var_arg/script deleted file mode 100644 index 722b0527f86..00000000000 --- a/acceptance/bundle/migrate/var_arg/script +++ /dev/null @@ -1,15 +0,0 @@ -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy --var="job_name=Custom Job Name" -trace $CLI bundle deployment migrate --var="job_name=Custom Job Name" 2>&1 | contains.py 'Migrated 1 resources' -trace print_state.py | jq '.state."resources.jobs.test_job".state.name' -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle plan --var="job_name=Custom Job Name" | contains.py "1 unchanged" -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle destroy --var="job_name=Custom Job Name" --auto-approve - -# Try different syntax, '--var X', instead of '--var=X' -rm -fr .databricks - -# Deploy with Terraform using a variable -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy --var "job_name=Custom Job Name" -trace $CLI bundle deployment migrate --var "job_name=Custom Job Name" 2>&1 | contains.py 'Migrated 1 resources' -trace print_state.py | jq '.state."resources.jobs.test_job".state.name' -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle plan --var "job_name=Custom Job Name" | contains.py "1 unchanged" -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle destroy --var="job_name=Custom Job Name" --auto-approve diff --git a/acceptance/bundle/migrate/var_arg/test.toml b/acceptance/bundle/migrate/var_arg/test.toml deleted file mode 100644 index a030353d571..00000000000 --- a/acceptance/bundle/migrate/var_arg/test.toml +++ /dev/null @@ -1 +0,0 @@ -RecordRequests = false diff --git a/acceptance/bundle/multi_profile/auto_select/out.test.toml b/acceptance/bundle/multi_profile/auto_select/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/multi_profile/auto_select/out.test.toml +++ b/acceptance/bundle/multi_profile/auto_select/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/multi_profile/env_auth_skip/out.test.toml b/acceptance/bundle/multi_profile/env_auth_skip/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/multi_profile/env_auth_skip/out.test.toml +++ b/acceptance/bundle/multi_profile/env_auth_skip/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/multi_profile/no_workspace_profiles/out.test.toml b/acceptance/bundle/multi_profile/no_workspace_profiles/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/multi_profile/no_workspace_profiles/out.test.toml +++ b/acceptance/bundle/multi_profile/no_workspace_profiles/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/multi_profile/non_interactive_error/out.test.toml b/acceptance/bundle/multi_profile/non_interactive_error/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/multi_profile/non_interactive_error/out.test.toml +++ b/acceptance/bundle/multi_profile/non_interactive_error/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/open/out.test.toml b/acceptance/bundle/open/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/open/out.test.toml +++ b/acceptance/bundle/open/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/override/clusters/out.test.toml b/acceptance/bundle/override/clusters/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/override/clusters/out.test.toml +++ b/acceptance/bundle/override/clusters/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/override/job_cluster/out.test.toml b/acceptance/bundle/override/job_cluster/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/override/job_cluster/out.test.toml +++ b/acceptance/bundle/override/job_cluster/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/override/job_cluster_var/out.test.toml b/acceptance/bundle/override/job_cluster_var/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/override/job_cluster_var/out.test.toml +++ b/acceptance/bundle/override/job_cluster_var/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/override/job_tasks/out.test.toml b/acceptance/bundle/override/job_tasks/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/override/job_tasks/out.test.toml +++ b/acceptance/bundle/override/job_tasks/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/override/merge-string-map/out.test.toml b/acceptance/bundle/override/merge-string-map/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/override/merge-string-map/out.test.toml +++ b/acceptance/bundle/override/merge-string-map/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/override/pipeline_cluster/out.test.toml b/acceptance/bundle/override/pipeline_cluster/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/override/pipeline_cluster/out.test.toml +++ b/acceptance/bundle/override/pipeline_cluster/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/paths/designer_notebook/out.test.toml b/acceptance/bundle/paths/designer_notebook/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/paths/designer_notebook/out.test.toml +++ b/acceptance/bundle/paths/designer_notebook/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/paths/fallback/out.test.toml b/acceptance/bundle/paths/fallback/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/paths/fallback/out.test.toml +++ b/acceptance/bundle/paths/fallback/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/paths/git_source_jobs/out.test.toml b/acceptance/bundle/paths/git_source_jobs/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/paths/git_source_jobs/out.test.toml +++ b/acceptance/bundle/paths/git_source_jobs/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/paths/invalid_pipeline_globs/out.test.toml b/acceptance/bundle/paths/invalid_pipeline_globs/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/paths/invalid_pipeline_globs/out.test.toml +++ b/acceptance/bundle/paths/invalid_pipeline_globs/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/paths/nominal/out.test.toml b/acceptance/bundle/paths/nominal/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/paths/nominal/out.test.toml +++ b/acceptance/bundle/paths/nominal/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/paths/outside_root_no_sync/out.test.toml b/acceptance/bundle/paths/outside_root_no_sync/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/paths/outside_root_no_sync/out.test.toml +++ b/acceptance/bundle/paths/outside_root_no_sync/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/paths/pipeline_expected_file_got_notebook/out.test.toml b/acceptance/bundle/paths/pipeline_expected_file_got_notebook/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/paths/pipeline_expected_file_got_notebook/out.test.toml +++ b/acceptance/bundle/paths/pipeline_expected_file_got_notebook/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/paths/pipeline_globs/out.test.toml b/acceptance/bundle/paths/pipeline_globs/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/paths/pipeline_globs/out.test.toml +++ b/acceptance/bundle/paths/pipeline_globs/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/paths/pipeline_root_path_doesnotexist/out.test.toml b/acceptance/bundle/paths/pipeline_root_path_doesnotexist/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/paths/pipeline_root_path_doesnotexist/out.test.toml +++ b/acceptance/bundle/paths/pipeline_root_path_doesnotexist/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/paths/pipelines_glob_include_and_root_path/out.test.toml b/acceptance/bundle/paths/pipelines_glob_include_and_root_path/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/paths/pipelines_glob_include_and_root_path/out.test.toml +++ b/acceptance/bundle/paths/pipelines_glob_include_and_root_path/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/paths/pipelines_root_path_outside_sync_root/out.test.toml b/acceptance/bundle/paths/pipelines_root_path_outside_sync_root/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/paths/pipelines_root_path_outside_sync_root/out.test.toml +++ b/acceptance/bundle/paths/pipelines_root_path_outside_sync_root/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/paths/relative_path_outside_root/out.test.toml b/acceptance/bundle/paths/relative_path_outside_root/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/paths/relative_path_outside_root/out.test.toml +++ b/acceptance/bundle/paths/relative_path_outside_root/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/paths/relative_path_translation/out.test.toml b/acceptance/bundle/paths/relative_path_translation/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/paths/relative_path_translation/out.test.toml +++ b/acceptance/bundle/paths/relative_path_translation/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/plan/no_upload/out.test.toml b/acceptance/bundle/plan/no_upload/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/plan/no_upload/out.test.toml +++ b/acceptance/bundle/plan/no_upload/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/presets/preset_vs_dev_mode/out.test.toml b/acceptance/bundle/presets/preset_vs_dev_mode/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/presets/preset_vs_dev_mode/out.test.toml +++ b/acceptance/bundle/presets/preset_vs_dev_mode/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/python/alerts-support/out.test.toml b/acceptance/bundle/python/alerts-support/out.test.toml index 02da5baab89..aeddf3e619e 100644 --- a/acceptance/bundle/python/alerts-support/out.test.toml +++ b/acceptance/bundle/python/alerts-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/apps-support/out.test.toml b/acceptance/bundle/python/apps-support/out.test.toml index 02da5baab89..aeddf3e619e 100644 --- a/acceptance/bundle/python/apps-support/out.test.toml +++ b/acceptance/bundle/python/apps-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/catalogs-support/out.test.toml b/acceptance/bundle/python/catalogs-support/out.test.toml index 8feac676720..aeddf3e619e 100644 --- a/acceptance/bundle/python/catalogs-support/out.test.toml +++ b/acceptance/bundle/python/catalogs-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/catalogs-support/test.toml b/acceptance/bundle/python/catalogs-support/test.toml index be087892be4..476e72e7def 100644 --- a/acceptance/bundle/python/catalogs-support/test.toml +++ b/acceptance/bundle/python/catalogs-support/test.toml @@ -4,4 +4,3 @@ Cloud = false # tests don't interact with APIs EnvMatrix.PYDAB_VERSION = ["current"] # catalogs are only supported on the direct deployment engine -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/python/cluster_policies-support/out.test.toml b/acceptance/bundle/python/cluster_policies-support/out.test.toml index 8feac676720..aeddf3e619e 100644 --- a/acceptance/bundle/python/cluster_policies-support/out.test.toml +++ b/acceptance/bundle/python/cluster_policies-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/cluster_policies-support/test.toml b/acceptance/bundle/python/cluster_policies-support/test.toml index 89ce26e899b..94f72755775 100644 --- a/acceptance/bundle/python/cluster_policies-support/test.toml +++ b/acceptance/bundle/python/cluster_policies-support/test.toml @@ -4,4 +4,3 @@ Cloud = false # tests don't interact with APIs EnvMatrix.PYDAB_VERSION = ["current"] # cluster_policies are only supported on the direct deployment engine -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/python/clusters-support/out.test.toml b/acceptance/bundle/python/clusters-support/out.test.toml index 02da5baab89..aeddf3e619e 100644 --- a/acceptance/bundle/python/clusters-support/out.test.toml +++ b/acceptance/bundle/python/clusters-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/dashboards-support/out.test.toml b/acceptance/bundle/python/dashboards-support/out.test.toml index 02da5baab89..aeddf3e619e 100644 --- a/acceptance/bundle/python/dashboards-support/out.test.toml +++ b/acceptance/bundle/python/dashboards-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/database_catalogs-support/out.test.toml b/acceptance/bundle/python/database_catalogs-support/out.test.toml index 02da5baab89..aeddf3e619e 100644 --- a/acceptance/bundle/python/database_catalogs-support/out.test.toml +++ b/acceptance/bundle/python/database_catalogs-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/database_instances-support/out.test.toml b/acceptance/bundle/python/database_instances-support/out.test.toml index 02da5baab89..aeddf3e619e 100644 --- a/acceptance/bundle/python/database_instances-support/out.test.toml +++ b/acceptance/bundle/python/database_instances-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/experimental-compatibility-both-equal/out.test.toml b/acceptance/bundle/python/experimental-compatibility-both-equal/out.test.toml index 164ce535b87..dce9192f28d 100644 --- a/acceptance/bundle/python/experimental-compatibility-both-equal/out.test.toml +++ b/acceptance/bundle/python/experimental-compatibility-both-equal/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["0.266.0", "current"] diff --git a/acceptance/bundle/python/experimental-compatibility-both-error/out.test.toml b/acceptance/bundle/python/experimental-compatibility-both-error/out.test.toml index 164ce535b87..dce9192f28d 100644 --- a/acceptance/bundle/python/experimental-compatibility-both-error/out.test.toml +++ b/acceptance/bundle/python/experimental-compatibility-both-error/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["0.266.0", "current"] diff --git a/acceptance/bundle/python/experimental-compatibility/out.test.toml b/acceptance/bundle/python/experimental-compatibility/out.test.toml index 164ce535b87..dce9192f28d 100644 --- a/acceptance/bundle/python/experimental-compatibility/out.test.toml +++ b/acceptance/bundle/python/experimental-compatibility/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["0.266.0", "current"] diff --git a/acceptance/bundle/python/experiments-support/out.test.toml b/acceptance/bundle/python/experiments-support/out.test.toml index 02da5baab89..aeddf3e619e 100644 --- a/acceptance/bundle/python/experiments-support/out.test.toml +++ b/acceptance/bundle/python/experiments-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/external_locations-support/out.test.toml b/acceptance/bundle/python/external_locations-support/out.test.toml index 8feac676720..aeddf3e619e 100644 --- a/acceptance/bundle/python/external_locations-support/out.test.toml +++ b/acceptance/bundle/python/external_locations-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/external_locations-support/test.toml b/acceptance/bundle/python/external_locations-support/test.toml index bc1dcb19111..7c94b3ee22c 100644 --- a/acceptance/bundle/python/external_locations-support/test.toml +++ b/acceptance/bundle/python/external_locations-support/test.toml @@ -4,4 +4,3 @@ Cloud = false # tests don't interact with APIs EnvMatrix.PYDAB_VERSION = ["current"] # external_locations are only supported on the direct deployment engine -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/python/genie_spaces-support/out.test.toml b/acceptance/bundle/python/genie_spaces-support/out.test.toml index 8feac676720..aeddf3e619e 100644 --- a/acceptance/bundle/python/genie_spaces-support/out.test.toml +++ b/acceptance/bundle/python/genie_spaces-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/genie_spaces-support/test.toml b/acceptance/bundle/python/genie_spaces-support/test.toml index 6e55f0ad980..25745f973ca 100644 --- a/acceptance/bundle/python/genie_spaces-support/test.toml +++ b/acceptance/bundle/python/genie_spaces-support/test.toml @@ -4,4 +4,3 @@ Cloud = false # tests don't interact with APIs EnvMatrix.PYDAB_VERSION = ["current"] # genie_spaces are only supported on the direct deployment engine -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/python/grants-aliases/out.test.toml b/acceptance/bundle/python/grants-aliases/out.test.toml index 02da5baab89..aeddf3e619e 100644 --- a/acceptance/bundle/python/grants-aliases/out.test.toml +++ b/acceptance/bundle/python/grants-aliases/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/instance_pools-support/out.test.toml b/acceptance/bundle/python/instance_pools-support/out.test.toml index 8feac676720..aeddf3e619e 100644 --- a/acceptance/bundle/python/instance_pools-support/out.test.toml +++ b/acceptance/bundle/python/instance_pools-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/instance_pools-support/test.toml b/acceptance/bundle/python/instance_pools-support/test.toml index 4f7794ae00c..f7000d5d0db 100644 --- a/acceptance/bundle/python/instance_pools-support/test.toml +++ b/acceptance/bundle/python/instance_pools-support/test.toml @@ -4,4 +4,3 @@ Cloud = false # tests don't interact with APIs EnvMatrix.PYDAB_VERSION = ["current"] # instance_pools are only supported on the direct deployment engine -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/python/job_runs-support/out.test.toml b/acceptance/bundle/python/job_runs-support/out.test.toml index 8feac676720..aeddf3e619e 100644 --- a/acceptance/bundle/python/job_runs-support/out.test.toml +++ b/acceptance/bundle/python/job_runs-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/job_runs-support/test.toml b/acceptance/bundle/python/job_runs-support/test.toml index 56c3e19efc8..58528cf7c40 100644 --- a/acceptance/bundle/python/job_runs-support/test.toml +++ b/acceptance/bundle/python/job_runs-support/test.toml @@ -4,4 +4,3 @@ Cloud = false # tests don't interact with APIs EnvMatrix.PYDAB_VERSION = ["current"] # job_runs are only supported on the direct deployment engine -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/python/jobs-support/out.test.toml b/acceptance/bundle/python/jobs-support/out.test.toml index 164ce535b87..dce9192f28d 100644 --- a/acceptance/bundle/python/jobs-support/out.test.toml +++ b/acceptance/bundle/python/jobs-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["0.266.0", "current"] diff --git a/acceptance/bundle/python/mcp_services-support/out.test.toml b/acceptance/bundle/python/mcp_services-support/out.test.toml index 02da5baab89..aeddf3e619e 100644 --- a/acceptance/bundle/python/mcp_services-support/out.test.toml +++ b/acceptance/bundle/python/mcp_services-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/model_provider_services-support/out.test.toml b/acceptance/bundle/python/model_provider_services-support/out.test.toml index 02da5baab89..aeddf3e619e 100644 --- a/acceptance/bundle/python/model_provider_services-support/out.test.toml +++ b/acceptance/bundle/python/model_provider_services-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/model_services-support/out.test.toml b/acceptance/bundle/python/model_services-support/out.test.toml index 02da5baab89..aeddf3e619e 100644 --- a/acceptance/bundle/python/model_services-support/out.test.toml +++ b/acceptance/bundle/python/model_services-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/model_serving_endpoints-support/out.test.toml b/acceptance/bundle/python/model_serving_endpoints-support/out.test.toml index 02da5baab89..aeddf3e619e 100644 --- a/acceptance/bundle/python/model_serving_endpoints-support/out.test.toml +++ b/acceptance/bundle/python/model_serving_endpoints-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/models-support/out.test.toml b/acceptance/bundle/python/models-support/out.test.toml index 02da5baab89..aeddf3e619e 100644 --- a/acceptance/bundle/python/models-support/out.test.toml +++ b/acceptance/bundle/python/models-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/mutator-ordering/out.test.toml b/acceptance/bundle/python/mutator-ordering/out.test.toml index 164ce535b87..dce9192f28d 100644 --- a/acceptance/bundle/python/mutator-ordering/out.test.toml +++ b/acceptance/bundle/python/mutator-ordering/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["0.266.0", "current"] diff --git a/acceptance/bundle/python/mutator-permissions-owner-5682/out.test.toml b/acceptance/bundle/python/mutator-permissions-owner-5682/out.test.toml index 1c4948db335..9cff9965350 100644 --- a/acceptance/bundle/python/mutator-permissions-owner-5682/out.test.toml +++ b/acceptance/bundle/python/mutator-permissions-owner-5682/out.test.toml @@ -1,4 +1,3 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["0.266.0", "current"] diff --git a/acceptance/bundle/python/pipelines-support/out.test.toml b/acceptance/bundle/python/pipelines-support/out.test.toml index 164ce535b87..dce9192f28d 100644 --- a/acceptance/bundle/python/pipelines-support/out.test.toml +++ b/acceptance/bundle/python/pipelines-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["0.266.0", "current"] diff --git a/acceptance/bundle/python/postgres_snapshot_schedules-support/out.test.toml b/acceptance/bundle/python/postgres_snapshot_schedules-support/out.test.toml index 8feac676720..aeddf3e619e 100644 --- a/acceptance/bundle/python/postgres_snapshot_schedules-support/out.test.toml +++ b/acceptance/bundle/python/postgres_snapshot_schedules-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/postgres_snapshot_schedules-support/test.toml b/acceptance/bundle/python/postgres_snapshot_schedules-support/test.toml index d2430be4bd4..83cec09e863 100644 --- a/acceptance/bundle/python/postgres_snapshot_schedules-support/test.toml +++ b/acceptance/bundle/python/postgres_snapshot_schedules-support/test.toml @@ -4,4 +4,3 @@ Cloud = false # tests do not interact with APIs EnvMatrix.PYDAB_VERSION = ["current"] # postgres_snapshot_schedules are only supported on the direct deployment engine -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/python/propagates-auth-env/out.test.toml b/acceptance/bundle/python/propagates-auth-env/out.test.toml index 164ce535b87..dce9192f28d 100644 --- a/acceptance/bundle/python/propagates-auth-env/out.test.toml +++ b/acceptance/bundle/python/propagates-auth-env/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["0.266.0", "current"] diff --git a/acceptance/bundle/python/quality_monitors-support/out.test.toml b/acceptance/bundle/python/quality_monitors-support/out.test.toml index 8feac676720..aeddf3e619e 100644 --- a/acceptance/bundle/python/quality_monitors-support/out.test.toml +++ b/acceptance/bundle/python/quality_monitors-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/quality_monitors-support/test.toml b/acceptance/bundle/python/quality_monitors-support/test.toml index 3e8bfd9efd3..afd4f163d83 100644 --- a/acceptance/bundle/python/quality_monitors-support/test.toml +++ b/acceptance/bundle/python/quality_monitors-support/test.toml @@ -4,4 +4,3 @@ Cloud = false # tests don't interact with APIs EnvMatrix.PYDAB_VERSION = ["current"] # quality_monitors are only supported on the direct deployment engine -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/python/registered_models-support/out.test.toml b/acceptance/bundle/python/registered_models-support/out.test.toml index 02da5baab89..aeddf3e619e 100644 --- a/acceptance/bundle/python/registered_models-support/out.test.toml +++ b/acceptance/bundle/python/registered_models-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/resolve-variable/out.test.toml b/acceptance/bundle/python/resolve-variable/out.test.toml index 164ce535b87..dce9192f28d 100644 --- a/acceptance/bundle/python/resolve-variable/out.test.toml +++ b/acceptance/bundle/python/resolve-variable/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["0.266.0", "current"] diff --git a/acceptance/bundle/python/resource-loading/out.test.toml b/acceptance/bundle/python/resource-loading/out.test.toml index 164ce535b87..dce9192f28d 100644 --- a/acceptance/bundle/python/resource-loading/out.test.toml +++ b/acceptance/bundle/python/resource-loading/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["0.266.0", "current"] diff --git a/acceptance/bundle/python/restricted-execution/out.test.toml b/acceptance/bundle/python/restricted-execution/out.test.toml index 164ce535b87..dce9192f28d 100644 --- a/acceptance/bundle/python/restricted-execution/out.test.toml +++ b/acceptance/bundle/python/restricted-execution/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["0.266.0", "current"] diff --git a/acceptance/bundle/python/schemas-support/out.test.toml b/acceptance/bundle/python/schemas-support/out.test.toml index 02da5baab89..aeddf3e619e 100644 --- a/acceptance/bundle/python/schemas-support/out.test.toml +++ b/acceptance/bundle/python/schemas-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/secret_scopes-support/out.test.toml b/acceptance/bundle/python/secret_scopes-support/out.test.toml index 02da5baab89..aeddf3e619e 100644 --- a/acceptance/bundle/python/secret_scopes-support/out.test.toml +++ b/acceptance/bundle/python/secret_scopes-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/secrets-support/out.test.toml b/acceptance/bundle/python/secrets-support/out.test.toml index 8feac676720..aeddf3e619e 100644 --- a/acceptance/bundle/python/secrets-support/out.test.toml +++ b/acceptance/bundle/python/secrets-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/secrets-support/test.toml b/acceptance/bundle/python/secrets-support/test.toml index 7ce2cef8f40..3950598f0b2 100644 --- a/acceptance/bundle/python/secrets-support/test.toml +++ b/acceptance/bundle/python/secrets-support/test.toml @@ -4,4 +4,3 @@ Cloud = false # tests don't interact with APIs EnvMatrix.PYDAB_VERSION = ["current"] # secrets are only supported on the direct deployment engine -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/python/sql_warehouses-support/out.test.toml b/acceptance/bundle/python/sql_warehouses-support/out.test.toml index 02da5baab89..aeddf3e619e 100644 --- a/acceptance/bundle/python/sql_warehouses-support/out.test.toml +++ b/acceptance/bundle/python/sql_warehouses-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/synced_database_tables-support/out.test.toml b/acceptance/bundle/python/synced_database_tables-support/out.test.toml index 02da5baab89..aeddf3e619e 100644 --- a/acceptance/bundle/python/synced_database_tables-support/out.test.toml +++ b/acceptance/bundle/python/synced_database_tables-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/unicode-support/out.test.toml b/acceptance/bundle/python/unicode-support/out.test.toml index 164ce535b87..dce9192f28d 100644 --- a/acceptance/bundle/python/unicode-support/out.test.toml +++ b/acceptance/bundle/python/unicode-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["0.266.0", "current"] diff --git a/acceptance/bundle/python/vector_search_endpoints-support/out.test.toml b/acceptance/bundle/python/vector_search_endpoints-support/out.test.toml index 8feac676720..aeddf3e619e 100644 --- a/acceptance/bundle/python/vector_search_endpoints-support/out.test.toml +++ b/acceptance/bundle/python/vector_search_endpoints-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/vector_search_endpoints-support/test.toml b/acceptance/bundle/python/vector_search_endpoints-support/test.toml index b8e53177777..76a6852f977 100644 --- a/acceptance/bundle/python/vector_search_endpoints-support/test.toml +++ b/acceptance/bundle/python/vector_search_endpoints-support/test.toml @@ -4,4 +4,3 @@ Cloud = false # tests don't interact with APIs EnvMatrix.PYDAB_VERSION = ["current"] # vector_search_endpoints are only supported on the direct deployment engine -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/python/vector_search_indexes-support/out.test.toml b/acceptance/bundle/python/vector_search_indexes-support/out.test.toml index 8feac676720..aeddf3e619e 100644 --- a/acceptance/bundle/python/vector_search_indexes-support/out.test.toml +++ b/acceptance/bundle/python/vector_search_indexes-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["current"] diff --git a/acceptance/bundle/python/vector_search_indexes-support/test.toml b/acceptance/bundle/python/vector_search_indexes-support/test.toml index 856a2743169..8f9f1317cf2 100644 --- a/acceptance/bundle/python/vector_search_indexes-support/test.toml +++ b/acceptance/bundle/python/vector_search_indexes-support/test.toml @@ -4,4 +4,3 @@ Cloud = false # tests don't interact with APIs EnvMatrix.PYDAB_VERSION = ["current"] # vector_search_indexes are only supported on the direct deployment engine -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/python/volumes-support/out.test.toml b/acceptance/bundle/python/volumes-support/out.test.toml index 164ce535b87..dce9192f28d 100644 --- a/acceptance/bundle/python/volumes-support/out.test.toml +++ b/acceptance/bundle/python/volumes-support/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.PYDAB_VERSION = ["0.266.0", "current"] diff --git a/acceptance/bundle/quality_monitor/out.test.toml b/acceptance/bundle/quality_monitor/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/quality_monitor/out.test.toml +++ b/acceptance/bundle/quality_monitor/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/quiet-levels/out.test.toml b/acceptance/bundle/quiet-levels/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/quiet-levels/out.test.toml +++ b/acceptance/bundle/quiet-levels/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/refschema/out.test.toml b/acceptance/bundle/refschema/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/refschema/out.test.toml +++ b/acceptance/bundle/refschema/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/bad_ref_string_to_int/out.plan.terraform.txt b/acceptance/bundle/resource_deps/bad_ref_string_to_int/out.plan.terraform.txt deleted file mode 100644 index 07e73cf4a84..00000000000 --- a/acceptance/bundle/resource_deps/bad_ref_string_to_int/out.plan.terraform.txt +++ /dev/null @@ -1,14 +0,0 @@ - ->>> musterr [CLI] bundle plan -Error: exit status 1 - -Error: Incorrect attribute value type - - on bundle.tf.json line 43, in resource.databricks_job.foo.task[0].run_job_task: - 43: "job_id": "${databricks_job.bar.name}" - ├──────────────── - │ databricks_job.bar.name is "job bar" - -Inappropriate value for attribute "job_id": a number is required. - - diff --git a/acceptance/bundle/resource_deps/bad_ref_string_to_int/out.plan.direct.txt b/acceptance/bundle/resource_deps/bad_ref_string_to_int/out.plan.txt similarity index 100% rename from acceptance/bundle/resource_deps/bad_ref_string_to_int/out.plan.direct.txt rename to acceptance/bundle/resource_deps/bad_ref_string_to_int/out.plan.txt diff --git a/acceptance/bundle/resource_deps/bad_ref_string_to_int/out.test.toml b/acceptance/bundle/resource_deps/bad_ref_string_to_int/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/bad_ref_string_to_int/out.test.toml +++ b/acceptance/bundle/resource_deps/bad_ref_string_to_int/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/bad_ref_string_to_int/script b/acceptance/bundle/resource_deps/bad_ref_string_to_int/script index 3471c56628c..f486f04ba0b 100644 --- a/acceptance/bundle/resource_deps/bad_ref_string_to_int/script +++ b/acceptance/bundle/resource_deps/bad_ref_string_to_int/script @@ -1 +1 @@ -trace musterr $CLI bundle plan &> out.plan.$DATABRICKS_BUNDLE_ENGINE.txt +trace musterr $CLI bundle plan &> out.plan.txt diff --git a/acceptance/bundle/resource_deps/bad_syntax/out.deploy.direct.txt b/acceptance/bundle/resource_deps/bad_syntax/out.deploy.txt similarity index 100% rename from acceptance/bundle/resource_deps/bad_syntax/out.deploy.direct.txt rename to acceptance/bundle/resource_deps/bad_syntax/out.deploy.txt diff --git a/acceptance/bundle/resource_deps/bad_syntax/out.plan.terraform.txt b/acceptance/bundle/resource_deps/bad_syntax/out.plan.terraform.txt deleted file mode 100644 index b8f8078abac..00000000000 --- a/acceptance/bundle/resource_deps/bad_syntax/out.plan.terraform.txt +++ /dev/null @@ -1,10 +0,0 @@ -Error: exit status 1 - -Error: Invalid attribute name - - on bundle.tf.json line 22, in resource.databricks_volume.foo: - 22: "catalog_name": "${resources.volumes.bar.bad..syntax}", - -An attribute name is required after a dot. - - diff --git a/acceptance/bundle/resource_deps/bad_syntax/out.plan.direct.txt b/acceptance/bundle/resource_deps/bad_syntax/out.plan.txt similarity index 100% rename from acceptance/bundle/resource_deps/bad_syntax/out.plan.direct.txt rename to acceptance/bundle/resource_deps/bad_syntax/out.plan.txt diff --git a/acceptance/bundle/resource_deps/bad_syntax/out.test.toml b/acceptance/bundle/resource_deps/bad_syntax/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/bad_syntax/out.test.toml +++ b/acceptance/bundle/resource_deps/bad_syntax/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/bad_syntax/script b/acceptance/bundle/resource_deps/bad_syntax/script index fe9628a126d..032d2a25441 100644 --- a/acceptance/bundle/resource_deps/bad_syntax/script +++ b/acceptance/bundle/resource_deps/bad_syntax/script @@ -1,3 +1,3 @@ trace $CLI bundle validate -o json | jq .resources -$CLI bundle plan &> out.plan.$DATABRICKS_BUNDLE_ENGINE.txt -musterr $CLI bundle deploy &> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt +$CLI bundle plan &> out.plan.txt +musterr $CLI bundle deploy &> out.deploy.txt diff --git a/acceptance/bundle/resource_deps/computed_volume_path/out.test.toml b/acceptance/bundle/resource_deps/computed_volume_path/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/computed_volume_path/out.test.toml +++ b/acceptance/bundle/resource_deps/computed_volume_path/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/create_error/out.deploy.terraform.txt b/acceptance/bundle/resource_deps/create_error/out.deploy.terraform.txt deleted file mode 100644 index bc0c317222c..00000000000 --- a/acceptance/bundle/resource_deps/create_error/out.deploy.terraform.txt +++ /dev/null @@ -1,12 +0,0 @@ -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Error: terraform apply: exit status 1 - -Error: cannot create job: INJECTED - - with databricks_job.foo, - on bundle.tf.json line 56, in resource.databricks_job.foo: - 56: }, - - - -Files: 0 uploaded, 0 deleted diff --git a/acceptance/bundle/resource_deps/create_error/out.deploy.direct.txt b/acceptance/bundle/resource_deps/create_error/out.deploy.txt similarity index 100% rename from acceptance/bundle/resource_deps/create_error/out.deploy.direct.txt rename to acceptance/bundle/resource_deps/create_error/out.deploy.txt diff --git a/acceptance/bundle/resource_deps/create_error/out.test.toml b/acceptance/bundle/resource_deps/create_error/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/create_error/out.test.toml +++ b/acceptance/bundle/resource_deps/create_error/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/create_error/script b/acceptance/bundle/resource_deps/create_error/script index bdc897e0d98..99db55f4494 100644 --- a/acceptance/bundle/resource_deps/create_error/script +++ b/acceptance/bundle/resource_deps/create_error/script @@ -1,6 +1,6 @@ echo "*" > .gitignore trace $CLI bundle plan 2>&1 -musterr $CLI bundle deploy -q &> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt # -q: independent job races the failure +musterr $CLI bundle deploy -q &> out.deploy.txt # -q: independent job races the failure trace print_requests.py --nostamp --sort //jobs trace $CLI bundle summary @@ -12,10 +12,10 @@ title "Plan should still contain foo and bar" trace $CLI bundle plan rm "$OUT_REQUESTS" -musterr $CLI bundle deploy -q &> out.deploy2.$DATABRICKS_BUNDLE_ENGINE.txt +musterr $CLI bundle deploy -q &> out.deploy2.txt title "Expecting no difference in the output between first and second deploy" -diff.py out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt out.deploy2.$DATABRICKS_BUNDLE_ENGINE.txt -rm out.deploy2.$DATABRICKS_BUNDLE_ENGINE.txt +diff.py out.deploy.txt out.deploy2.txt +rm out.deploy2.txt trace print_requests.py --nostamp //jobs trace $CLI bundle destroy --auto-approve diff --git a/acceptance/bundle/resource_deps/duplicate_ref/out.test.toml b/acceptance/bundle/resource_deps/duplicate_ref/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/duplicate_ref/out.test.toml +++ b/acceptance/bundle/resource_deps/duplicate_ref/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/escaped_ref/out.test.toml b/acceptance/bundle/resource_deps/escaped_ref/out.test.toml index dd03baaabb6..f7fafbcc731 100644 --- a/acceptance/bundle/resource_deps/escaped_ref/out.test.toml +++ b/acceptance/bundle/resource_deps/escaped_ref/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resource_deps/escaped_ref/test.toml b/acceptance/bundle/resource_deps/escaped_ref/test.toml index 360d84347ac..93b8b0cd76d 100644 --- a/acceptance/bundle/resource_deps/escaped_ref/test.toml +++ b/acceptance/bundle/resource_deps/escaped_ref/test.toml @@ -1,5 +1,4 @@ # depends_on is only present in the direct engine's plan JSON. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # Also deploy from the saved plan, so the payload is asserted whether it is built # in-process or read back from a plan file. diff --git a/acceptance/bundle/resource_deps/grant_ref/out.plan_create.direct.json b/acceptance/bundle/resource_deps/grant_ref/out.plan_create.json similarity index 100% rename from acceptance/bundle/resource_deps/grant_ref/out.plan_create.direct.json rename to acceptance/bundle/resource_deps/grant_ref/out.plan_create.json diff --git a/acceptance/bundle/resource_deps/grant_ref/out.test.toml b/acceptance/bundle/resource_deps/grant_ref/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/grant_ref/out.test.toml +++ b/acceptance/bundle/resource_deps/grant_ref/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/grant_ref/script b/acceptance/bundle/resource_deps/grant_ref/script index 458ea3c4932..edaa505906d 100644 --- a/acceptance/bundle/resource_deps/grant_ref/script +++ b/acceptance/bundle/resource_deps/grant_ref/script @@ -1,4 +1,4 @@ trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_create.json trace $CLI bundle deploy diff --git a/acceptance/bundle/resource_deps/grant_ref/test.toml b/acceptance/bundle/resource_deps/grant_ref/test.toml index 0901e354b33..a030353d571 100644 --- a/acceptance/bundle/resource_deps/grant_ref/test.toml +++ b/acceptance/bundle/resource_deps/grant_ref/test.toml @@ -1,3 +1 @@ RecordRequests = false - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resource_deps/id_chain/out.plan_create.direct.json b/acceptance/bundle/resource_deps/id_chain/out.plan_create.json similarity index 100% rename from acceptance/bundle/resource_deps/id_chain/out.plan_create.direct.json rename to acceptance/bundle/resource_deps/id_chain/out.plan_create.json diff --git a/acceptance/bundle/resource_deps/id_chain/out.plan_create.terraform.json b/acceptance/bundle/resource_deps/id_chain/out.plan_create.terraform.json deleted file mode 100644 index 50df97e8903..00000000000 --- a/acceptance/bundle/resource_deps/id_chain/out.plan_create.terraform.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.a": { - "action": "create" - }, - "resources.jobs.b": { - "action": "create" - }, - "resources.jobs.c": { - "action": "create" - }, - "resources.jobs.d": { - "action": "create" - }, - "resources.jobs.e": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resource_deps/id_chain/out.plan_skip.direct.json b/acceptance/bundle/resource_deps/id_chain/out.plan_skip.json similarity index 100% rename from acceptance/bundle/resource_deps/id_chain/out.plan_skip.direct.json rename to acceptance/bundle/resource_deps/id_chain/out.plan_skip.json diff --git a/acceptance/bundle/resource_deps/id_chain/out.plan_skip.terraform.json b/acceptance/bundle/resource_deps/id_chain/out.plan_skip.terraform.json deleted file mode 100644 index 11c35d7b27e..00000000000 --- a/acceptance/bundle/resource_deps/id_chain/out.plan_skip.terraform.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.a": { - "action": "skip" - }, - "resources.jobs.b": { - "action": "skip" - }, - "resources.jobs.c": { - "action": "skip" - }, - "resources.jobs.d": { - "action": "skip" - }, - "resources.jobs.e": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/resource_deps/id_chain/out.plan_update.direct.json b/acceptance/bundle/resource_deps/id_chain/out.plan_update.json similarity index 100% rename from acceptance/bundle/resource_deps/id_chain/out.plan_update.direct.json rename to acceptance/bundle/resource_deps/id_chain/out.plan_update.json diff --git a/acceptance/bundle/resource_deps/id_chain/out.plan_update.terraform.json b/acceptance/bundle/resource_deps/id_chain/out.plan_update.terraform.json deleted file mode 100644 index 343f9105b56..00000000000 --- a/acceptance/bundle/resource_deps/id_chain/out.plan_update.terraform.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.a": { - "action": "update" - }, - "resources.jobs.b": { - "action": "update" - }, - "resources.jobs.c": { - "action": "update" - }, - "resources.jobs.d": { - "action": "update" - }, - "resources.jobs.e": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resource_deps/id_chain/out.test.toml b/acceptance/bundle/resource_deps/id_chain/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/id_chain/out.test.toml +++ b/acceptance/bundle/resource_deps/id_chain/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/id_chain/script b/acceptance/bundle/resource_deps/id_chain/script index 56889f0bc66..2a0c8fe3f4c 100644 --- a/acceptance/bundle/resource_deps/id_chain/script +++ b/acceptance/bundle/resource_deps/id_chain/script @@ -16,7 +16,7 @@ print_requests_short() { trace $CLI bundle plan trace print_requests -$CLI bundle plan -o json | nostamp > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan_create.json trace print_requests trace $CLI bundle deploy @@ -25,7 +25,7 @@ trace print_requests_short trace update_file.py databricks.yml aa_desc aa_new_desc trace update_file.py databricks.yml prefix new_prefix -$CLI bundle plan -o json | nostamp > out.plan_update.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan_update.json trace print_requests trace $CLI bundle plan @@ -34,5 +34,5 @@ trace print_requests trace $CLI bundle deploy trace print_requests_short -$CLI bundle plan -o json | nostamp > out.plan_skip.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan_skip.json trace print_requests diff --git a/acceptance/bundle/resource_deps/id_star/out.plan_create.direct.json b/acceptance/bundle/resource_deps/id_star/out.plan_create.json similarity index 100% rename from acceptance/bundle/resource_deps/id_star/out.plan_create.direct.json rename to acceptance/bundle/resource_deps/id_star/out.plan_create.json diff --git a/acceptance/bundle/resource_deps/id_star/out.plan_create.terraform.json b/acceptance/bundle/resource_deps/id_star/out.plan_create.terraform.json deleted file mode 100644 index 50df97e8903..00000000000 --- a/acceptance/bundle/resource_deps/id_star/out.plan_create.terraform.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.a": { - "action": "create" - }, - "resources.jobs.b": { - "action": "create" - }, - "resources.jobs.c": { - "action": "create" - }, - "resources.jobs.d": { - "action": "create" - }, - "resources.jobs.e": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resource_deps/id_star/out.test.toml b/acceptance/bundle/resource_deps/id_star/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/id_star/out.test.toml +++ b/acceptance/bundle/resource_deps/id_star/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/id_star/script b/acceptance/bundle/resource_deps/id_star/script index bd85cfc8ae6..a88adbd12f0 100644 --- a/acceptance/bundle/resource_deps/id_star/script +++ b/acceptance/bundle/resource_deps/id_star/script @@ -1 +1 @@ -$CLI bundle plan -o json | nostamp > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan_create.json diff --git a/acceptance/bundle/resource_deps/immutable_field_ref/out.test.toml b/acceptance/bundle/resource_deps/immutable_field_ref/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/immutable_field_ref/out.test.toml +++ b/acceptance/bundle/resource_deps/immutable_field_ref/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/immutable_field_ref/test.toml b/acceptance/bundle/resource_deps/immutable_field_ref/test.toml index c235be5d8ee..a030353d571 100644 --- a/acceptance/bundle/resource_deps/immutable_field_ref/test.toml +++ b/acceptance/bundle/resource_deps/immutable_field_ref/test.toml @@ -1,2 +1 @@ RecordRequests = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resource_deps/implicit_deps_model_serving_endpoint/out.test.toml b/acceptance/bundle/resource_deps/implicit_deps_model_serving_endpoint/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/implicit_deps_model_serving_endpoint/out.test.toml +++ b/acceptance/bundle/resource_deps/implicit_deps_model_serving_endpoint/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/implicit_deps_quality_monitor/out.test.toml b/acceptance/bundle/resource_deps/implicit_deps_quality_monitor/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/implicit_deps_quality_monitor/out.test.toml +++ b/acceptance/bundle/resource_deps/implicit_deps_quality_monitor/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/implicit_deps_registered_model/out.test.toml b/acceptance/bundle/resource_deps/implicit_deps_registered_model/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/implicit_deps_registered_model/out.test.toml +++ b/acceptance/bundle/resource_deps/implicit_deps_registered_model/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/implicit_deps_vector_search_index/out.test.toml b/acceptance/bundle/resource_deps/implicit_deps_vector_search_index/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/implicit_deps_vector_search_index/out.test.toml +++ b/acceptance/bundle/resource_deps/implicit_deps_vector_search_index/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/implicit_deps_volume/out.test.toml b/acceptance/bundle/resource_deps/implicit_deps_volume/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/implicit_deps_volume/out.test.toml +++ b/acceptance/bundle/resource_deps/implicit_deps_volume/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/job_id/out.plan_create.direct.json b/acceptance/bundle/resource_deps/job_id/out.plan_create.json similarity index 100% rename from acceptance/bundle/resource_deps/job_id/out.plan_create.direct.json rename to acceptance/bundle/resource_deps/job_id/out.plan_create.json diff --git a/acceptance/bundle/resource_deps/job_id/out.plan_create.terraform.json b/acceptance/bundle/resource_deps/job_id/out.plan_create.terraform.json deleted file mode 100644 index 6c46e8ffa95..00000000000 --- a/acceptance/bundle/resource_deps/job_id/out.plan_create.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.bar": { - "action": "create" - }, - "resources.jobs.foo": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resource_deps/job_id/out.plan_delete.direct.json b/acceptance/bundle/resource_deps/job_id/out.plan_delete.json similarity index 100% rename from acceptance/bundle/resource_deps/job_id/out.plan_delete.direct.json rename to acceptance/bundle/resource_deps/job_id/out.plan_delete.json diff --git a/acceptance/bundle/resource_deps/job_id/out.plan_delete.terraform.json b/acceptance/bundle/resource_deps/job_id/out.plan_delete.terraform.json deleted file mode 100644 index 72c66745412..00000000000 --- a/acceptance/bundle/resource_deps/job_id/out.plan_delete.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.bar": { - "action": "delete" - }, - "resources.jobs.foo": { - "action": "delete" - } - } -} diff --git a/acceptance/bundle/resource_deps/job_id/out.test.toml b/acceptance/bundle/resource_deps/job_id/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/job_id/out.test.toml +++ b/acceptance/bundle/resource_deps/job_id/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/job_id/script b/acceptance/bundle/resource_deps/job_id/script index f8d30917d1c..8bff752d8b3 100644 --- a/acceptance/bundle/resource_deps/job_id/script +++ b/acceptance/bundle/resource_deps/job_id/script @@ -1,6 +1,6 @@ trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_create.json trace $CLI bundle deploy trace print_requests.py --nostamp //jobs @@ -8,7 +8,7 @@ foo_id=`read_id.py foo` bar_id=`read_id.py bar` cp empty.yml databricks.yml -trace $CLI bundle plan -o json | nostamp > out.plan_delete.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_delete.json trace $CLI bundle deploy trace print_requests.py --nostamp //jobs diff --git a/acceptance/bundle/resource_deps/job_id_big_graph/delete_all/out.test.toml b/acceptance/bundle/resource_deps/job_id_big_graph/delete_all/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/job_id_big_graph/delete_all/out.test.toml +++ b/acceptance/bundle/resource_deps/job_id_big_graph/delete_all/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/job_id_big_graph/destroy/out.test.toml b/acceptance/bundle/resource_deps/job_id_big_graph/destroy/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/job_id_big_graph/destroy/out.test.toml +++ b/acceptance/bundle/resource_deps/job_id_big_graph/destroy/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/job_id_delete_bar/out.deploy2.requests.direct.json b/acceptance/bundle/resource_deps/job_id_delete_bar/out.deploy2.requests.json similarity index 100% rename from acceptance/bundle/resource_deps/job_id_delete_bar/out.deploy2.requests.direct.json rename to acceptance/bundle/resource_deps/job_id_delete_bar/out.deploy2.requests.json diff --git a/acceptance/bundle/resource_deps/job_id_delete_bar/out.deploy2.requests.terraform.json b/acceptance/bundle/resource_deps/job_id_delete_bar/out.deploy2.requests.terraform.json deleted file mode 100644 index 7b9df153286..00000000000 --- a/acceptance/bundle/resource_deps/job_id_delete_bar/out.deploy2.requests.terraform.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.2/jobs/delete", - "body": { - "job_id": [BAR_ID] - } -} -{ - "method": "POST", - "path": "/api/2.2/jobs/reset", - "body": { - "job_id": [FOO_ID], - "new_settings": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "email_notifications": {}, - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "job foo", - "queue": { - "enabled": true - }, - "run_as": { - "user_name": "[USERNAME]" - }, - "webhook_notifications": {} - } - } -} diff --git a/acceptance/bundle/resource_deps/job_id_delete_bar/out.plan_delete.direct.json b/acceptance/bundle/resource_deps/job_id_delete_bar/out.plan_delete.json similarity index 100% rename from acceptance/bundle/resource_deps/job_id_delete_bar/out.plan_delete.direct.json rename to acceptance/bundle/resource_deps/job_id_delete_bar/out.plan_delete.json diff --git a/acceptance/bundle/resource_deps/job_id_delete_bar/out.plan_delete.terraform.json b/acceptance/bundle/resource_deps/job_id_delete_bar/out.plan_delete.terraform.json deleted file mode 100644 index 62b631ea7ef..00000000000 --- a/acceptance/bundle/resource_deps/job_id_delete_bar/out.plan_delete.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.bar": { - "action": "delete" - }, - "resources.jobs.foo": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resource_deps/job_id_delete_bar/out.test.toml b/acceptance/bundle/resource_deps/job_id_delete_bar/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/job_id_delete_bar/out.test.toml +++ b/acceptance/bundle/resource_deps/job_id_delete_bar/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/job_id_delete_bar/script b/acceptance/bundle/resource_deps/job_id_delete_bar/script index 61b0a074d9a..ddccf53c38a 100644 --- a/acceptance/bundle/resource_deps/job_id_delete_bar/script +++ b/acceptance/bundle/resource_deps/job_id_delete_bar/script @@ -7,11 +7,11 @@ bar_id=`read_id.py bar` title "Delete bar, keep foo (foo config updated to not depend on bar)" cp only_foo.yml databricks.yml -trace $CLI bundle plan -o json | nostamp > out.plan_delete.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_delete.json trace $CLI bundle deploy # Sort requests because foo's update and bar's delete have no dependency edge # (foo's dependency on bar was removed in only_foo.yml), so execution order is non-deterministic. -trace print_requests.py --nostamp --sort //jobs > out.deploy2.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --nostamp --sort //jobs > out.deploy2.requests.json trace $CLI bundle destroy --auto-approve trace print_requests.py --nostamp //jobs diff --git a/acceptance/bundle/resource_deps/job_id_delete_foo/out.plan_delete.direct.json b/acceptance/bundle/resource_deps/job_id_delete_foo/out.plan_delete.json similarity index 100% rename from acceptance/bundle/resource_deps/job_id_delete_foo/out.plan_delete.direct.json rename to acceptance/bundle/resource_deps/job_id_delete_foo/out.plan_delete.json diff --git a/acceptance/bundle/resource_deps/job_id_delete_foo/out.plan_delete.terraform.json b/acceptance/bundle/resource_deps/job_id_delete_foo/out.plan_delete.terraform.json deleted file mode 100644 index 0ce9fd2754d..00000000000 --- a/acceptance/bundle/resource_deps/job_id_delete_foo/out.plan_delete.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.bar": { - "action": "skip" - }, - "resources.jobs.foo": { - "action": "delete" - } - } -} diff --git a/acceptance/bundle/resource_deps/job_id_delete_foo/out.test.toml b/acceptance/bundle/resource_deps/job_id_delete_foo/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/job_id_delete_foo/out.test.toml +++ b/acceptance/bundle/resource_deps/job_id_delete_foo/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/job_id_delete_foo/script b/acceptance/bundle/resource_deps/job_id_delete_foo/script index 392afced7b4..eb7ff645436 100644 --- a/acceptance/bundle/resource_deps/job_id_delete_foo/script +++ b/acceptance/bundle/resource_deps/job_id_delete_foo/script @@ -7,7 +7,7 @@ bar_id=`read_id.py bar` title "Delete foo, keep bar" cp only_bar.yml databricks.yml -trace $CLI bundle plan -o json | nostamp > out.plan_delete.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_delete.json trace $CLI bundle deploy trace print_requests.py --nostamp //jobs diff --git a/acceptance/bundle/resource_deps/job_tasks/out.drymigrate.terraform.txt b/acceptance/bundle/resource_deps/job_tasks/out.drymigrate.terraform.txt deleted file mode 100644 index d7fac6e7778..00000000000 --- a/acceptance/bundle/resource_deps/job_tasks/out.drymigrate.terraform.txt +++ /dev/null @@ -1,2 +0,0 @@ -direct_drymigrate_success true -direct_drymigrate_warnings false diff --git a/acceptance/bundle/empty_string_dropped/out.empty_sent_by_direct_only.txt b/acceptance/bundle/resource_deps/job_tasks/out.drymigrate.txt similarity index 100% rename from acceptance/bundle/empty_string_dropped/out.empty_sent_by_direct_only.txt rename to acceptance/bundle/resource_deps/job_tasks/out.drymigrate.txt diff --git a/acceptance/bundle/resource_deps/job_tasks/out.test.toml b/acceptance/bundle/resource_deps/job_tasks/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/job_tasks/out.test.toml +++ b/acceptance/bundle/resource_deps/job_tasks/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/job_tasks/script b/acceptance/bundle/resource_deps/job_tasks/script index 033e3914f07..fefea98a700 100644 --- a/acceptance/bundle/resource_deps/job_tasks/script +++ b/acceptance/bundle/resource_deps/job_tasks/script @@ -1,5 +1,5 @@ touch hello.whl trace $CLI bundle deploy trace print_telemetry_bool_values | grep -v direct_drymigrate -print_telemetry_bool_values | grep direct_drymigrate > out.drymigrate.$DATABRICKS_BUNDLE_ENGINE.txt || true +print_telemetry_bool_values | grep direct_drymigrate > out.drymigrate.txt || true rm "$OUT_REQUESTS" hello.whl diff --git a/acceptance/bundle/resource_deps/jobs_update/out.deploy2.requests.direct.json b/acceptance/bundle/resource_deps/jobs_update/out.deploy2.requests.json similarity index 100% rename from acceptance/bundle/resource_deps/jobs_update/out.deploy2.requests.direct.json rename to acceptance/bundle/resource_deps/jobs_update/out.deploy2.requests.json diff --git a/acceptance/bundle/resource_deps/jobs_update/out.deploy2.requests.terraform.json b/acceptance/bundle/resource_deps/jobs_update/out.deploy2.requests.terraform.json deleted file mode 100644 index 3b099ed5f68..00000000000 --- a/acceptance/bundle/resource_deps/jobs_update/out.deploy2.requests.terraform.json +++ /dev/null @@ -1,41 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.2/jobs/reset", - "body": { - "job_id": [FOO_ID], - "new_settings": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "email_notifications": {}, - "format": "MULTI_TASK", - "job_clusters": [ - { - "job_cluster_key": "key", - "new_cluster": { - "num_workers": 0, - "spark_version": "13.3.x-scala2.12" - } - } - ], - "max_concurrent_runs": 1, - "name": "foo", - "queue": { - "enabled": true - }, - "run_as": { - "user_name": "[USERNAME]" - }, - "trigger": { - "pause_status": "UNPAUSED", - "periodic": { - "interval": 1, - "unit": "HOURS" - } - }, - "webhook_notifications": {} - } - } -} diff --git a/acceptance/bundle/resource_deps/jobs_update/out.get_foo.direct.json b/acceptance/bundle/resource_deps/jobs_update/out.get_foo.json similarity index 100% rename from acceptance/bundle/resource_deps/jobs_update/out.get_foo.direct.json rename to acceptance/bundle/resource_deps/jobs_update/out.get_foo.json diff --git a/acceptance/bundle/resource_deps/jobs_update/out.get_foo.terraform.json b/acceptance/bundle/resource_deps/jobs_update/out.get_foo.terraform.json deleted file mode 100644 index e20aea135c4..00000000000 --- a/acceptance/bundle/resource_deps/jobs_update/out.get_foo.terraform.json +++ /dev/null @@ -1,41 +0,0 @@ -{ - "created_time": [UNIX_TIME_MILLIS], - "creator_user_name": "[USERNAME]", - "job_id": [FOO_ID], - "run_as_user_name": "[USERNAME]", - "settings": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "email_notifications": {}, - "format": "MULTI_TASK", - "job_clusters": [ - { - "job_cluster_key": "key", - "new_cluster": { - "num_workers": 0, - "spark_version": "13.3.x-scala2.12" - } - } - ], - "max_concurrent_runs": 1, - "name": "foo", - "queue": { - "enabled": true - }, - "run_as": { - "user_name": "[USERNAME]" - }, - "timeout_seconds": 0, - "trigger": { - "pause_status": "UNPAUSED", - "periodic": { - "interval": 1, - "unit": "HOURS" - } - }, - "webhook_notifications": {} - } -} diff --git a/acceptance/bundle/resource_deps/jobs_update/out.test.toml b/acceptance/bundle/resource_deps/jobs_update/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/jobs_update/out.test.toml +++ b/acceptance/bundle/resource_deps/jobs_update/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/jobs_update/script b/acceptance/bundle/resource_deps/jobs_update/script index 015c62d07b5..5e4c4bd95a0 100644 --- a/acceptance/bundle/resource_deps/jobs_update/script +++ b/acceptance/bundle/resource_deps/jobs_update/script @@ -14,13 +14,13 @@ trace update_file.py databricks.yml DAYS HOURS trace $CLI bundle plan trace $CLI bundle deploy # per-engine output file because terraform adds output-only and server-side defaults fields into request and direct does not -trace print_requests.py --nostamp //jobs > out.deploy2.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --nostamp //jobs > out.deploy2.requests.json trace $CLI bundle plan title "Fetch job ID and verify remote state" # Badness: output should not be different per engine; investigate if it's the same on cloud -trace $CLI jobs get $foo_id | nostamp > out.get_foo.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI jobs get $foo_id | nostamp > out.get_foo.json trace $CLI jobs get $bar_id | nostamp rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/resource_deps/jobs_update_remote/out.plan_create.direct.json b/acceptance/bundle/resource_deps/jobs_update_remote/out.plan_create.json similarity index 100% rename from acceptance/bundle/resource_deps/jobs_update_remote/out.plan_create.direct.json rename to acceptance/bundle/resource_deps/jobs_update_remote/out.plan_create.json diff --git a/acceptance/bundle/resource_deps/jobs_update_remote/out.plan_create.terraform.json b/acceptance/bundle/resource_deps/jobs_update_remote/out.plan_create.terraform.json deleted file mode 100644 index 6c46e8ffa95..00000000000 --- a/acceptance/bundle/resource_deps/jobs_update_remote/out.plan_create.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.bar": { - "action": "create" - }, - "resources.jobs.foo": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resource_deps/jobs_update_remote/out.plan_update.direct.json b/acceptance/bundle/resource_deps/jobs_update_remote/out.plan_update.json similarity index 100% rename from acceptance/bundle/resource_deps/jobs_update_remote/out.plan_update.direct.json rename to acceptance/bundle/resource_deps/jobs_update_remote/out.plan_update.json diff --git a/acceptance/bundle/resource_deps/jobs_update_remote/out.plan_update.terraform.json b/acceptance/bundle/resource_deps/jobs_update_remote/out.plan_update.terraform.json deleted file mode 100644 index e316ed7692d..00000000000 --- a/acceptance/bundle/resource_deps/jobs_update_remote/out.plan_update.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.bar": { - "action": "skip" - }, - "resources.jobs.foo": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resource_deps/jobs_update_remote/out.test.toml b/acceptance/bundle/resource_deps/jobs_update_remote/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/jobs_update_remote/out.test.toml +++ b/acceptance/bundle/resource_deps/jobs_update_remote/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/jobs_update_remote/script b/acceptance/bundle/resource_deps/jobs_update_remote/script index 5b4c38fe2ba..8b827e07f03 100644 --- a/acceptance/bundle/resource_deps/jobs_update_remote/script +++ b/acceptance/bundle/resource_deps/jobs_update_remote/script @@ -1,4 +1,4 @@ -$CLI bundle plan -o json | nostamp > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan_create.json trace $CLI bundle deploy trace print_requests.py --nostamp //jobs @@ -12,7 +12,7 @@ bar_id=`read_id.py bar` title "Update trigger.periodic.unit remotely and re-deploy; jobs.bar is unchanged" trace envsubst < job_update.json > tmp.json && mv tmp.json job_update.json trace $CLI jobs reset --json @job_update.json -$CLI bundle plan -o json | nostamp > out.plan_update.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan_update.json trace $CLI bundle destroy --auto-approve trace print_requests.py --nostamp //jobs diff --git a/acceptance/bundle/resource_deps/loop_jobs/out.deploy.terraform.txt b/acceptance/bundle/resource_deps/loop_jobs/out.deploy.terraform.txt deleted file mode 100644 index 365063d84df..00000000000 --- a/acceptance/bundle/resource_deps/loop_jobs/out.deploy.terraform.txt +++ /dev/null @@ -1,8 +0,0 @@ -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Error: exit status 1 - -Error: Cycle: databricks_job.foo, databricks_job.bar - - - -Files: 5 uploaded, 0 deleted diff --git a/acceptance/bundle/resource_deps/loop_jobs/out.deploy.direct.txt b/acceptance/bundle/resource_deps/loop_jobs/out.deploy.txt similarity index 100% rename from acceptance/bundle/resource_deps/loop_jobs/out.deploy.direct.txt rename to acceptance/bundle/resource_deps/loop_jobs/out.deploy.txt diff --git a/acceptance/bundle/resource_deps/loop_jobs/out.plan.terraform.txt b/acceptance/bundle/resource_deps/loop_jobs/out.plan.terraform.txt deleted file mode 100644 index 083ada1adb3..00000000000 --- a/acceptance/bundle/resource_deps/loop_jobs/out.plan.terraform.txt +++ /dev/null @@ -1,6 +0,0 @@ -Error: exit status 1 - -Error: Cycle: databricks_job.foo, databricks_job.bar - - - diff --git a/acceptance/bundle/resource_deps/loop_jobs/out.plan.direct.txt b/acceptance/bundle/resource_deps/loop_jobs/out.plan.txt similarity index 100% rename from acceptance/bundle/resource_deps/loop_jobs/out.plan.direct.txt rename to acceptance/bundle/resource_deps/loop_jobs/out.plan.txt diff --git a/acceptance/bundle/resource_deps/loop_jobs/out.test.toml b/acceptance/bundle/resource_deps/loop_jobs/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/loop_jobs/out.test.toml +++ b/acceptance/bundle/resource_deps/loop_jobs/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/loop_jobs/script b/acceptance/bundle/resource_deps/loop_jobs/script index 6a4d602175a..2051d4e9606 100644 --- a/acceptance/bundle/resource_deps/loop_jobs/script +++ b/acceptance/bundle/resource_deps/loop_jobs/script @@ -1,4 +1,4 @@ title "Badness: validate could detect this and fail as well" trace $CLI bundle validate -musterr $CLI bundle plan &> out.plan.$DATABRICKS_BUNDLE_ENGINE.txt -musterr $CLI bundle deploy &> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt +musterr $CLI bundle plan &> out.plan.txt +musterr $CLI bundle deploy &> out.deploy.txt diff --git a/acceptance/bundle/resource_deps/loop_self/out.deploy.terraform.txt b/acceptance/bundle/resource_deps/loop_self/out.deploy.terraform.txt deleted file mode 100644 index 67b028a54a9..00000000000 --- a/acceptance/bundle/resource_deps/loop_self/out.deploy.terraform.txt +++ /dev/null @@ -1,19 +0,0 @@ -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Error: exit status 1 - -Error: Self-referential block - - on bundle.tf.json line 23, in resource.databricks_job.foo: - 23: "name": "${databricks_job.foo.id}", - -Configuration for databricks_job.foo may not refer to itself. - -Error: Self-referential block - - on bundle.tf.json line 23, in resource.databricks_job.foo: - 23: "name": "${databricks_job.foo.id}", - -Configuration for databricks_job.foo may not refer to itself. - - -Files: 5 uploaded, 0 deleted diff --git a/acceptance/bundle/resource_deps/loop_self/out.deploy.direct.txt b/acceptance/bundle/resource_deps/loop_self/out.deploy.txt similarity index 100% rename from acceptance/bundle/resource_deps/loop_self/out.deploy.direct.txt rename to acceptance/bundle/resource_deps/loop_self/out.deploy.txt diff --git a/acceptance/bundle/resource_deps/loop_self/out.plan.terraform.txt b/acceptance/bundle/resource_deps/loop_self/out.plan.terraform.txt deleted file mode 100644 index 8434d76ae8a..00000000000 --- a/acceptance/bundle/resource_deps/loop_self/out.plan.terraform.txt +++ /dev/null @@ -1,17 +0,0 @@ -Error: exit status 1 - -Error: Self-referential block - - on bundle.tf.json line 23, in resource.databricks_job.foo: - 23: "name": "${databricks_job.foo.id}", - -Configuration for databricks_job.foo may not refer to itself. - -Error: Self-referential block - - on bundle.tf.json line 23, in resource.databricks_job.foo: - 23: "name": "${databricks_job.foo.id}", - -Configuration for databricks_job.foo may not refer to itself. - - diff --git a/acceptance/bundle/resource_deps/loop_self/out.plan.direct.txt b/acceptance/bundle/resource_deps/loop_self/out.plan.txt similarity index 100% rename from acceptance/bundle/resource_deps/loop_self/out.plan.direct.txt rename to acceptance/bundle/resource_deps/loop_self/out.plan.txt diff --git a/acceptance/bundle/resource_deps/loop_self/out.test.toml b/acceptance/bundle/resource_deps/loop_self/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/loop_self/out.test.toml +++ b/acceptance/bundle/resource_deps/loop_self/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/loop_self/script b/acceptance/bundle/resource_deps/loop_self/script index d0d8b8e67a0..5475d19f368 100644 --- a/acceptance/bundle/resource_deps/loop_self/script +++ b/acceptance/bundle/resource_deps/loop_self/script @@ -1,4 +1,4 @@ title "Badness: validate could detect this and fail as well" $CLI bundle validate -musterr $CLI bundle plan &> out.plan.$DATABRICKS_BUNDLE_ENGINE.txt -musterr $CLI bundle deploy &> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt +musterr $CLI bundle plan &> out.plan.txt +musterr $CLI bundle deploy &> out.deploy.txt diff --git a/acceptance/bundle/resource_deps/missing_ingestion_definition/out.deploy.terraform.txt b/acceptance/bundle/resource_deps/missing_ingestion_definition/out.deploy.terraform.txt deleted file mode 100644 index 44cae02948c..00000000000 --- a/acceptance/bundle/resource_deps/missing_ingestion_definition/out.deploy.terraform.txt +++ /dev/null @@ -1,17 +0,0 @@ -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Error: exit status 1 - -Error: Invalid index - - on bundle.tf.json line 22, in resource.databricks_pipeline.bar: - 22: "name": "pbar ${databricks_pipeline.foo.ingestion_definition[0].connection_name}" - ├──────────────── - │ databricks_pipeline.foo.ingestion_definition is empty list of object - -The given key does not identify an element in this collection value: the -collection has no elements. - - -Files: 6 uploaded, 0 deleted - -Exit code: 1 diff --git a/acceptance/bundle/resource_deps/missing_ingestion_definition/out.deploy.direct.txt b/acceptance/bundle/resource_deps/missing_ingestion_definition/out.deploy.txt similarity index 100% rename from acceptance/bundle/resource_deps/missing_ingestion_definition/out.deploy.direct.txt rename to acceptance/bundle/resource_deps/missing_ingestion_definition/out.deploy.txt diff --git a/acceptance/bundle/resource_deps/missing_ingestion_definition/out.plan.terraform.txt b/acceptance/bundle/resource_deps/missing_ingestion_definition/out.plan.terraform.txt deleted file mode 100644 index e603a9eb9ec..00000000000 --- a/acceptance/bundle/resource_deps/missing_ingestion_definition/out.plan.terraform.txt +++ /dev/null @@ -1,15 +0,0 @@ -Error: exit status 1 - -Error: Invalid index - - on bundle.tf.json line 22, in resource.databricks_pipeline.bar: - 22: "name": "pbar ${databricks_pipeline.foo.ingestion_definition[0].connection_name}" - ├──────────────── - │ databricks_pipeline.foo.ingestion_definition is empty list of object - -The given key does not identify an element in this collection value: the -collection has no elements. - - - -Exit code: 1 diff --git a/acceptance/bundle/resource_deps/missing_ingestion_definition/out.plan.direct.txt b/acceptance/bundle/resource_deps/missing_ingestion_definition/out.plan.txt similarity index 100% rename from acceptance/bundle/resource_deps/missing_ingestion_definition/out.plan.direct.txt rename to acceptance/bundle/resource_deps/missing_ingestion_definition/out.plan.txt diff --git a/acceptance/bundle/resource_deps/missing_ingestion_definition/out.test.toml b/acceptance/bundle/resource_deps/missing_ingestion_definition/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/missing_ingestion_definition/out.test.toml +++ b/acceptance/bundle/resource_deps/missing_ingestion_definition/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/missing_ingestion_definition/out.validate.direct.json b/acceptance/bundle/resource_deps/missing_ingestion_definition/out.validate.json similarity index 100% rename from acceptance/bundle/resource_deps/missing_ingestion_definition/out.validate.direct.json rename to acceptance/bundle/resource_deps/missing_ingestion_definition/out.validate.json diff --git a/acceptance/bundle/resource_deps/missing_ingestion_definition/out.validate.terraform.json b/acceptance/bundle/resource_deps/missing_ingestion_definition/out.validate.terraform.json deleted file mode 100644 index 353cb4eb0d5..00000000000 --- a/acceptance/bundle/resource_deps/missing_ingestion_definition/out.validate.terraform.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "bar": { - "channel": "CURRENT", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json" - }, - "edition": "ADVANCED", - "name": "pbar ${resources.pipelines.foo.ingestion_definition[0].connection_name}" - }, - "foo": { - "channel": "CURRENT", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json" - }, - "edition": "ADVANCED", - "name": "pfoo" - } -} diff --git a/acceptance/bundle/resource_deps/missing_ingestion_definition/script b/acceptance/bundle/resource_deps/missing_ingestion_definition/script index e6dff48b9ba..419d1552a20 100644 --- a/acceptance/bundle/resource_deps/missing_ingestion_definition/script +++ b/acceptance/bundle/resource_deps/missing_ingestion_definition/script @@ -1,9 +1,3 @@ -if [ "$DATABRICKS_BUNDLE_ENGINE" = "terraform" ]; then - grep -v "# direct engine syntax" databricks.yml > databricks.yml.tmp - update_file.py databricks.yml.tmp "#terraform syntax: " "" - mv databricks.yml.tmp databricks.yml -fi - -$CLI bundle validate -o json | jq .resources.pipelines > out.validate.$DATABRICKS_BUNDLE_ENGINE.json -errcode $CLI bundle plan &> out.plan.$DATABRICKS_BUNDLE_ENGINE.txt -errcode $CLI bundle deploy &> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt +$CLI bundle validate -o json | jq .resources.pipelines > out.validate.json +errcode $CLI bundle plan &> out.plan.txt +errcode $CLI bundle deploy &> out.deploy.txt diff --git a/acceptance/bundle/resource_deps/missing_map_key/out.deploy.terraform.txt b/acceptance/bundle/resource_deps/missing_map_key/out.deploy.terraform.txt deleted file mode 100644 index 098c70891f0..00000000000 --- a/acceptance/bundle/resource_deps/missing_map_key/out.deploy.terraform.txt +++ /dev/null @@ -1,14 +0,0 @@ -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/state/default/files... -Error: exit status 1 - -Error: Missing map element - - on bundle.tf.json line 23, in resource.databricks_job.bar: - 23: "name": "test ${databricks_job.test.task[0].new_cluster[0].custom_tags.missing_tag}", - ├──────────────── - │ databricks_job.test.task[0].new_cluster[0].custom_tags is map of string with 1 element - -This map does not have an element with the key "missing_tag". - - -Files: 6 uploaded, 0 deleted diff --git a/acceptance/bundle/resource_deps/missing_map_key/out.deploy.direct.txt b/acceptance/bundle/resource_deps/missing_map_key/out.deploy.txt similarity index 100% rename from acceptance/bundle/resource_deps/missing_map_key/out.deploy.direct.txt rename to acceptance/bundle/resource_deps/missing_map_key/out.deploy.txt diff --git a/acceptance/bundle/resource_deps/missing_map_key/out.plan.terraform.txt b/acceptance/bundle/resource_deps/missing_map_key/out.plan.terraform.txt deleted file mode 100644 index 7f63edb902f..00000000000 --- a/acceptance/bundle/resource_deps/missing_map_key/out.plan.terraform.txt +++ /dev/null @@ -1,14 +0,0 @@ -Error: exit status 1 - -Error: Missing map element - - on bundle.tf.json line 23, in resource.databricks_job.bar: - 23: "name": "test ${databricks_job.test.task[0].new_cluster[0].custom_tags.missing_tag}", - ├──────────────── - │ databricks_job.test.task[0].new_cluster[0].custom_tags is map of string with 1 element - -This map does not have an element with the key "missing_tag". - - - -Exit code: 1 diff --git a/acceptance/bundle/resource_deps/missing_map_key/out.plan.direct.txt b/acceptance/bundle/resource_deps/missing_map_key/out.plan.txt similarity index 100% rename from acceptance/bundle/resource_deps/missing_map_key/out.plan.direct.txt rename to acceptance/bundle/resource_deps/missing_map_key/out.plan.txt diff --git a/acceptance/bundle/resource_deps/missing_map_key/out.test.toml b/acceptance/bundle/resource_deps/missing_map_key/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/missing_map_key/out.test.toml +++ b/acceptance/bundle/resource_deps/missing_map_key/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/missing_map_key/out.validate.direct.json b/acceptance/bundle/resource_deps/missing_map_key/out.validate.json similarity index 100% rename from acceptance/bundle/resource_deps/missing_map_key/out.validate.direct.json rename to acceptance/bundle/resource_deps/missing_map_key/out.validate.json diff --git a/acceptance/bundle/resource_deps/missing_map_key/out.validate.terraform.json b/acceptance/bundle/resource_deps/missing_map_key/out.validate.terraform.json deleted file mode 100644 index 3cdf58f84ea..00000000000 --- a/acceptance/bundle/resource_deps/missing_map_key/out.validate.terraform.json +++ /dev/null @@ -1,40 +0,0 @@ -{ - "jobs": { - "bar": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/state/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "test ${resources.jobs.test.task[0].new_cluster[0].custom_tags.missing_tag}", - "queue": { - "enabled": true - } - }, - "test": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/state/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "test", - "queue": { - "enabled": true - }, - "tasks": [ - { - "new_cluster": { - "custom_tags": { - "ResourceClass": "SingleNode" - } - }, - "task_key": "test-task" - } - ] - } - } -} diff --git a/acceptance/bundle/resource_deps/missing_map_key/script b/acceptance/bundle/resource_deps/missing_map_key/script index 408972edc3e..63cc9f67f4a 100644 --- a/acceptance/bundle/resource_deps/missing_map_key/script +++ b/acceptance/bundle/resource_deps/missing_map_key/script @@ -1,9 +1,3 @@ -if [ "$DATABRICKS_BUNDLE_ENGINE" = "terraform" ]; then - grep -v "# direct engine syntax" databricks.yml > databricks.yml.tmp - update_file.py databricks.yml.tmp "#terraform syntax: " "" - mv databricks.yml.tmp databricks.yml -fi - -trace $CLI bundle validate -o json | jq .resources > out.validate.$DATABRICKS_BUNDLE_ENGINE.json -errcode $CLI bundle plan &> out.plan.$DATABRICKS_BUNDLE_ENGINE.txt -musterr $CLI bundle deploy &> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt +trace $CLI bundle validate -o json | jq .resources > out.validate.json +errcode $CLI bundle plan &> out.plan.txt +musterr $CLI bundle deploy &> out.deploy.txt diff --git a/acceptance/bundle/resource_deps/missing_string_field/out.test.toml b/acceptance/bundle/resource_deps/missing_string_field/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/missing_string_field/out.test.toml +++ b/acceptance/bundle/resource_deps/missing_string_field/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/model_id_ref/out.test.toml b/acceptance/bundle/resource_deps/model_id_ref/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/model_id_ref/out.test.toml +++ b/acceptance/bundle/resource_deps/model_id_ref/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/non_existent_field/out.deploy.terraform.txt b/acceptance/bundle/resource_deps/non_existent_field/out.deploy.terraform.txt deleted file mode 100644 index ddea4b4a236..00000000000 --- a/acceptance/bundle/resource_deps/non_existent_field/out.deploy.terraform.txt +++ /dev/null @@ -1,13 +0,0 @@ -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Error: exit status 1 - -Error: Unsupported attribute - - on bundle.tf.json line 22, in resource.databricks_volume.foo: - 22: "catalog_name": "${databricks_volume.bar.non_existent}", - -This object has no argument, nested block, or exported attribute named -"non_existent". - - -Files: 5 uploaded, 0 deleted diff --git a/acceptance/bundle/resource_deps/non_existent_field/out.deploy.direct.txt b/acceptance/bundle/resource_deps/non_existent_field/out.deploy.txt similarity index 100% rename from acceptance/bundle/resource_deps/non_existent_field/out.deploy.direct.txt rename to acceptance/bundle/resource_deps/non_existent_field/out.deploy.txt diff --git a/acceptance/bundle/resource_deps/non_existent_field/out.plan.terraform.txt b/acceptance/bundle/resource_deps/non_existent_field/out.plan.terraform.txt deleted file mode 100644 index 4df0c4bcd61..00000000000 --- a/acceptance/bundle/resource_deps/non_existent_field/out.plan.terraform.txt +++ /dev/null @@ -1,11 +0,0 @@ -Error: exit status 1 - -Error: Unsupported attribute - - on bundle.tf.json line 22, in resource.databricks_volume.foo: - 22: "catalog_name": "${databricks_volume.bar.non_existent}", - -This object has no argument, nested block, or exported attribute named -"non_existent". - - diff --git a/acceptance/bundle/resource_deps/non_existent_field/out.plan.direct.txt b/acceptance/bundle/resource_deps/non_existent_field/out.plan.txt similarity index 100% rename from acceptance/bundle/resource_deps/non_existent_field/out.plan.direct.txt rename to acceptance/bundle/resource_deps/non_existent_field/out.plan.txt diff --git a/acceptance/bundle/resource_deps/non_existent_field/out.test.toml b/acceptance/bundle/resource_deps/non_existent_field/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/non_existent_field/out.test.toml +++ b/acceptance/bundle/resource_deps/non_existent_field/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/non_existent_field/script b/acceptance/bundle/resource_deps/non_existent_field/script index 8ea06b0c199..1826f00396a 100644 --- a/acceptance/bundle/resource_deps/non_existent_field/script +++ b/acceptance/bundle/resource_deps/non_existent_field/script @@ -1,3 +1,3 @@ trace $CLI bundle validate -o json | jq .resources -musterr $CLI bundle plan &> out.plan.$DATABRICKS_BUNDLE_ENGINE.txt -musterr $CLI bundle deploy &> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt +musterr $CLI bundle plan &> out.plan.txt +musterr $CLI bundle deploy &> out.deploy.txt diff --git a/acceptance/bundle/resource_deps/permission_ref/out.plan_create.direct.json b/acceptance/bundle/resource_deps/permission_ref/out.plan_create.json similarity index 100% rename from acceptance/bundle/resource_deps/permission_ref/out.plan_create.direct.json rename to acceptance/bundle/resource_deps/permission_ref/out.plan_create.json diff --git a/acceptance/bundle/resource_deps/permission_ref/out.test.toml b/acceptance/bundle/resource_deps/permission_ref/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/permission_ref/out.test.toml +++ b/acceptance/bundle/resource_deps/permission_ref/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/permission_ref/script b/acceptance/bundle/resource_deps/permission_ref/script index 458ea3c4932..edaa505906d 100644 --- a/acceptance/bundle/resource_deps/permission_ref/script +++ b/acceptance/bundle/resource_deps/permission_ref/script @@ -1,4 +1,4 @@ trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_create.json trace $CLI bundle deploy diff --git a/acceptance/bundle/resource_deps/permission_ref/test.toml b/acceptance/bundle/resource_deps/permission_ref/test.toml index 0901e354b33..a030353d571 100644 --- a/acceptance/bundle/resource_deps/permission_ref/test.toml +++ b/acceptance/bundle/resource_deps/permission_ref/test.toml @@ -1,3 +1 @@ RecordRequests = false - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resource_deps/pipelines_recreate/out.plan_create.direct.json b/acceptance/bundle/resource_deps/pipelines_recreate/out.plan_create.json similarity index 100% rename from acceptance/bundle/resource_deps/pipelines_recreate/out.plan_create.direct.json rename to acceptance/bundle/resource_deps/pipelines_recreate/out.plan_create.json diff --git a/acceptance/bundle/resource_deps/pipelines_recreate/out.plan_create.terraform.json b/acceptance/bundle/resource_deps/pipelines_recreate/out.plan_create.terraform.json deleted file mode 100644 index ef7d63b0c21..00000000000 --- a/acceptance/bundle/resource_deps/pipelines_recreate/out.plan_create.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.bar": { - "action": "create" - }, - "resources.pipelines.foo": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resource_deps/pipelines_recreate/out.plan_noop.direct.json b/acceptance/bundle/resource_deps/pipelines_recreate/out.plan_noop.json similarity index 100% rename from acceptance/bundle/resource_deps/pipelines_recreate/out.plan_noop.direct.json rename to acceptance/bundle/resource_deps/pipelines_recreate/out.plan_noop.json diff --git a/acceptance/bundle/resource_deps/pipelines_recreate/out.plan_noop.terraform.json b/acceptance/bundle/resource_deps/pipelines_recreate/out.plan_noop.terraform.json deleted file mode 100644 index ea25aa7e8e7..00000000000 --- a/acceptance/bundle/resource_deps/pipelines_recreate/out.plan_noop.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.bar": { - "action": "skip" - }, - "resources.pipelines.foo": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/resource_deps/pipelines_recreate/out.plan_update.direct.json b/acceptance/bundle/resource_deps/pipelines_recreate/out.plan_update.json similarity index 100% rename from acceptance/bundle/resource_deps/pipelines_recreate/out.plan_update.direct.json rename to acceptance/bundle/resource_deps/pipelines_recreate/out.plan_update.json diff --git a/acceptance/bundle/resource_deps/pipelines_recreate/out.plan_update.terraform.json b/acceptance/bundle/resource_deps/pipelines_recreate/out.plan_update.terraform.json deleted file mode 100644 index 48350abb9ec..00000000000 --- a/acceptance/bundle/resource_deps/pipelines_recreate/out.plan_update.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.bar": { - "action": "update" - }, - "resources.pipelines.foo": { - "action": "recreate" - } - } -} diff --git a/acceptance/bundle/resource_deps/pipelines_recreate/out.test.toml b/acceptance/bundle/resource_deps/pipelines_recreate/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/pipelines_recreate/out.test.toml +++ b/acceptance/bundle/resource_deps/pipelines_recreate/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/pipelines_recreate/out.update.requests.direct.json b/acceptance/bundle/resource_deps/pipelines_recreate/out.update.requests.json similarity index 100% rename from acceptance/bundle/resource_deps/pipelines_recreate/out.update.requests.direct.json rename to acceptance/bundle/resource_deps/pipelines_recreate/out.update.requests.json diff --git a/acceptance/bundle/resource_deps/pipelines_recreate/out.update.requests.terraform.json b/acceptance/bundle/resource_deps/pipelines_recreate/out.update.requests.terraform.json deleted file mode 100644 index 972862518f2..00000000000 --- a/acceptance/bundle/resource_deps/pipelines_recreate/out.update.requests.terraform.json +++ /dev/null @@ -1,44 +0,0 @@ -{ - "method": "DELETE", - "path": "/api/2.0/pipelines/[FOO_ID]" -} -{ - "method": "POST", - "path": "/api/2.0/pipelines", - "body": { - "channel": "CURRENT", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json" - }, - "edition": "ADVANCED", - "name": "pipeline foo", - "storage": "dbfs:/my-new-storage" - } -} -{ - "method": "POST", - "path": "/api/2.2/jobs/reset", - "body": { - "job_id": [BAR_ID], - "new_settings": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json" - }, - "description": "depends on foo id [FOO_ID_2]", - "edit_mode": "UI_LOCKED", - "email_notifications": {}, - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "job bar", - "queue": { - "enabled": true - }, - "run_as": { - "user_name": "[USERNAME]" - }, - "webhook_notifications": {} - } - } -} diff --git a/acceptance/bundle/resource_deps/pipelines_recreate/script b/acceptance/bundle/resource_deps/pipelines_recreate/script index d78b1581293..acfb13cddec 100644 --- a/acceptance/bundle/resource_deps/pipelines_recreate/script +++ b/acceptance/bundle/resource_deps/pipelines_recreate/script @@ -1,6 +1,6 @@ trace $CLI bundle plan -$CLI bundle plan -o json | nostamp > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan_create.json trace $CLI bundle deploy trace print_requests.py --nostamp //jobs //pipelines '^//api/2.0/bundle' > out.create.requests.json @@ -13,9 +13,9 @@ trace $CLI bundle plan # empty title "Update storage, triggering recreate for pipeline; this means updating downstream deps" trace update_file.py databricks.yml "storage: dbfs:/my-storage" "storage: dbfs:/my-new-storage" trace $CLI bundle plan -$CLI bundle plan -o json | nostamp > out.plan_update.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan_update.json trace $CLI bundle deploy --auto-approve -trace print_requests.py --nostamp //jobs //pipelines '^//api/2.0/bundle' > out.update.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --nostamp //jobs //pipelines '^//api/2.0/bundle' > out.update.requests.json foo_id_2=`read_id.py foo` @@ -28,7 +28,7 @@ rm "$OUT_REQUESTS" title "Follow up plan & deploy do nothing" trace $CLI bundle plan -$CLI bundle plan -o json | nostamp > out.plan_noop.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan_noop.json trace $CLI bundle deploy trace print_requests.py --nostamp //jobs //pipelines '^//api/2.0/bundle' diff --git a/acceptance/bundle/resource_deps/present_ingestion_definition/out.plan.terraform.txt b/acceptance/bundle/resource_deps/present_ingestion_definition/out.plan.terraform.txt deleted file mode 100644 index d084d3dd3a0..00000000000 --- a/acceptance/bundle/resource_deps/present_ingestion_definition/out.plan.terraform.txt +++ /dev/null @@ -1,13 +0,0 @@ -Error: exit status 1 - -Error: Invalid operation - - on bundle.tf.json line 22, in resource.databricks_pipeline.bar: - 22: "name": "pbar ${databricks_pipeline.foo.ingestion_definition.connection_name}" - -Block type "ingestion_definition" is represented by a list of objects, so it -must be indexed using a numeric key, like .ingestion_definition[0]. - - - -Exit code: 1 diff --git a/acceptance/bundle/resource_deps/present_ingestion_definition/out.plan.direct.txt b/acceptance/bundle/resource_deps/present_ingestion_definition/out.plan.txt similarity index 100% rename from acceptance/bundle/resource_deps/present_ingestion_definition/out.plan.direct.txt rename to acceptance/bundle/resource_deps/present_ingestion_definition/out.plan.txt diff --git a/acceptance/bundle/resource_deps/present_ingestion_definition/out.test.toml b/acceptance/bundle/resource_deps/present_ingestion_definition/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/present_ingestion_definition/out.test.toml +++ b/acceptance/bundle/resource_deps/present_ingestion_definition/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/present_ingestion_definition/script b/acceptance/bundle/resource_deps/present_ingestion_definition/script index d12526234d0..22c47632357 100644 --- a/acceptance/bundle/resource_deps/present_ingestion_definition/script +++ b/acceptance/bundle/resource_deps/present_ingestion_definition/script @@ -1,2 +1,2 @@ $CLI bundle validate -o json | jq .resources.pipelines.bar.name -errcode $CLI bundle plan &> out.plan.$DATABRICKS_BUNDLE_ENGINE.txt +errcode $CLI bundle plan &> out.plan.txt diff --git a/acceptance/bundle/resource_deps/remote_app_url/out.test.toml b/acceptance/bundle/resource_deps/remote_app_url/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/remote_app_url/out.test.toml +++ b/acceptance/bundle/resource_deps/remote_app_url/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/remote_field_storage_location/out.deploy.requests.direct.json b/acceptance/bundle/resource_deps/remote_field_storage_location/out.deploy.requests.json similarity index 100% rename from acceptance/bundle/resource_deps/remote_field_storage_location/out.deploy.requests.direct.json rename to acceptance/bundle/resource_deps/remote_field_storage_location/out.deploy.requests.json diff --git a/acceptance/bundle/resource_deps/remote_field_storage_location/out.deploy.requests.terraform.json b/acceptance/bundle/resource_deps/remote_field_storage_location/out.deploy.requests.terraform.json deleted file mode 100644 index d048e68d7be..00000000000 --- a/acceptance/bundle/resource_deps/remote_field_storage_location/out.deploy.requests.terraform.json +++ /dev/null @@ -1,26 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.1/unity-catalog/schemas", - "body": { - "catalog_name": "main", - "name": "myschema-[UNIQUE_NAME]" - } -} -{ - "method": "GET", - "path": "/api/2.1/unity-catalog/schemas/main.myschema-[UNIQUE_NAME]" -} -{ - "method": "POST", - "path": "/api/2.1/unity-catalog/volumes", - "body": { - "catalog_name": "main", - "name": "volumebar-[UNIQUE_NAME]", - "schema_name": "myschema-[UNIQUE_NAME]", - "volume_type": "MANAGED" - } -} -{ - "method": "GET", - "path": "/api/2.1/unity-catalog/volumes/main.myschema-[UNIQUE_NAME].volumebar-[UNIQUE_NAME]" -} diff --git a/acceptance/bundle/resource_deps/remote_field_storage_location/out.deploy.terraform.txt b/acceptance/bundle/resource_deps/remote_field_storage_location/out.deploy.terraform.txt deleted file mode 100644 index 4f9221996d1..00000000000 --- a/acceptance/bundle/resource_deps/remote_field_storage_location/out.deploy.terraform.txt +++ /dev/null @@ -1,20 +0,0 @@ - ->>> errcode [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/testbundle-[UNIQUE_NAME]/default/files... -Error: terraform apply: exit status 1 - -Error: Provider produced inconsistent final plan - -When expanding the plan for databricks_volume.foo to include new values -learned so far during apply, provider -"registry.terraform.io/databricks/databricks" produced an invalid new value -for .comment: was null, but now -cty.StringVal("s3://[METASTORE_NAME]/metastore/[UUID]/volumes/[UUID]"). - -This is a bug in the provider, which should be reported in the provider's own -issue tracker. - - -Files: 5 uploaded, 0 deleted - -Exit code: 1 diff --git a/acceptance/bundle/resource_deps/remote_field_storage_location/out.deploy.direct.txt b/acceptance/bundle/resource_deps/remote_field_storage_location/out.deploy.txt similarity index 100% rename from acceptance/bundle/resource_deps/remote_field_storage_location/out.deploy.direct.txt rename to acceptance/bundle/resource_deps/remote_field_storage_location/out.deploy.txt diff --git a/acceptance/bundle/resource_deps/remote_field_storage_location/out.destroy.terraform.txt b/acceptance/bundle/resource_deps/remote_field_storage_location/out.destroy.terraform.txt deleted file mode 100644 index d3bc5027d4e..00000000000 --- a/acceptance/bundle/resource_deps/remote_field_storage_location/out.destroy.terraform.txt +++ /dev/null @@ -1,16 +0,0 @@ -The following resources will be deleted: - delete resources.schemas.my - delete resources.volumes.bar - -This action will result in the deletion of the following UC schemas. Any underlying data may be lost: - delete resources.schemas.my - -This action will result in the deletion of the following volumes. -For managed volumes, the files stored in the volume are also deleted from your -cloud tenant within 30 days. For external volumes, the metadata about the volume -is removed from the catalog, but the underlying files are not deleted: - delete resources.volumes.bar - -All files and directories at the following location will be deleted: /Workspace/Users/[USERNAME]/.bundle/testbundle-[UNIQUE_NAME]/default - -Destroy: 2 deleted diff --git a/acceptance/bundle/resource_deps/remote_field_storage_location/out.destroy.direct.txt b/acceptance/bundle/resource_deps/remote_field_storage_location/out.destroy.txt similarity index 100% rename from acceptance/bundle/resource_deps/remote_field_storage_location/out.destroy.direct.txt rename to acceptance/bundle/resource_deps/remote_field_storage_location/out.destroy.txt diff --git a/acceptance/bundle/resource_deps/remote_field_storage_location/out.destroy_requests.direct.json b/acceptance/bundle/resource_deps/remote_field_storage_location/out.destroy_requests.json similarity index 100% rename from acceptance/bundle/resource_deps/remote_field_storage_location/out.destroy_requests.direct.json rename to acceptance/bundle/resource_deps/remote_field_storage_location/out.destroy_requests.json diff --git a/acceptance/bundle/resource_deps/remote_field_storage_location/out.destroy_requests.terraform.json b/acceptance/bundle/resource_deps/remote_field_storage_location/out.destroy_requests.terraform.json deleted file mode 100644 index b544cfb4611..00000000000 --- a/acceptance/bundle/resource_deps/remote_field_storage_location/out.destroy_requests.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "method": "DELETE", - "path": "/api/2.1/unity-catalog/schemas/main.myschema-[UNIQUE_NAME]", - "q": { - "force": "true" - } -} -{ - "method": "DELETE", - "path": "/api/2.1/unity-catalog/volumes/main.myschema-[UNIQUE_NAME].volumebar-[UNIQUE_NAME]" -} diff --git a/acceptance/bundle/resource_deps/remote_field_storage_location/out.plan_after_deploy.terraform.txt b/acceptance/bundle/resource_deps/remote_field_storage_location/out.plan_after_deploy.terraform.txt deleted file mode 100644 index 35041be6c3e..00000000000 --- a/acceptance/bundle/resource_deps/remote_field_storage_location/out.plan_after_deploy.terraform.txt +++ /dev/null @@ -1,3 +0,0 @@ -create volumes.foo - -Plan: 1 to add, 0 to change, 0 to delete, 2 unchanged diff --git a/acceptance/bundle/resource_deps/remote_field_storage_location/out.plan_after_deploy.direct.txt b/acceptance/bundle/resource_deps/remote_field_storage_location/out.plan_after_deploy.txt similarity index 100% rename from acceptance/bundle/resource_deps/remote_field_storage_location/out.plan_after_deploy.direct.txt rename to acceptance/bundle/resource_deps/remote_field_storage_location/out.plan_after_deploy.txt diff --git a/acceptance/bundle/resource_deps/remote_field_storage_location/out.test.toml b/acceptance/bundle/resource_deps/remote_field_storage_location/out.test.toml index b09d680c0e1..ee153e82621 100644 --- a/acceptance/bundle/resource_deps/remote_field_storage_location/out.test.toml +++ b/acceptance/bundle/resource_deps/remote_field_storage_location/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/remote_field_storage_location/script b/acceptance/bundle/resource_deps/remote_field_storage_location/script index 30ed44956f0..f9b82b333e1 100644 --- a/acceptance/bundle/resource_deps/remote_field_storage_location/script +++ b/acceptance/bundle/resource_deps/remote_field_storage_location/script @@ -1,6 +1,6 @@ cleanup() { - $CLI bundle destroy --auto-approve &> out.destroy.$DATABRICKS_BUNDLE_ENGINE.txt - print_requests.py --sort //unity &> out.destroy_requests.$DATABRICKS_BUNDLE_ENGINE.json + $CLI bundle destroy --auto-approve &> out.destroy.txt + print_requests.py --sort //unity &> out.destroy_requests.json } envsubst < databricks.yml.tmpl > databricks.yml @@ -8,8 +8,8 @@ trace $CLI bundle validate -o json | jq .resources trace $CLI bundle plan trace print_requests.py --get //unity trap cleanup EXIT -trace errcode $CLI bundle deploy &> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt -print_requests.py --get //unity &> out.deploy.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace errcode $CLI bundle deploy &> out.deploy.txt +print_requests.py --get //unity &> out.deploy.requests.json # Terraform could not deploy, so it still shows up here; direct shows no drift: -$CLI bundle plan &> out.plan_after_deploy.$DATABRICKS_BUNDLE_ENGINE.txt +$CLI bundle plan &> out.plan_after_deploy.txt diff --git a/acceptance/bundle/resource_deps/remote_pipeline/out.plan_create.direct.json b/acceptance/bundle/resource_deps/remote_pipeline/out.plan_create.json similarity index 100% rename from acceptance/bundle/resource_deps/remote_pipeline/out.plan_create.direct.json rename to acceptance/bundle/resource_deps/remote_pipeline/out.plan_create.json diff --git a/acceptance/bundle/resource_deps/remote_pipeline/out.plan_create.terraform.json b/acceptance/bundle/resource_deps/remote_pipeline/out.plan_create.terraform.json deleted file mode 100644 index 61b043ac9ae..00000000000 --- a/acceptance/bundle/resource_deps/remote_pipeline/out.plan_create.terraform.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.foo1": { - "action": "create" - }, - "resources.pipelines.foo2": { - "action": "create" - }, - "resources.pipelines.foo3": { - "action": "create" - }, - "resources.pipelines.foo4": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resource_deps/remote_pipeline/out.plan_skip.direct.json b/acceptance/bundle/resource_deps/remote_pipeline/out.plan_skip.json similarity index 100% rename from acceptance/bundle/resource_deps/remote_pipeline/out.plan_skip.direct.json rename to acceptance/bundle/resource_deps/remote_pipeline/out.plan_skip.json diff --git a/acceptance/bundle/resource_deps/remote_pipeline/out.plan_skip.terraform.json b/acceptance/bundle/resource_deps/remote_pipeline/out.plan_skip.terraform.json deleted file mode 100644 index 288c69679a5..00000000000 --- a/acceptance/bundle/resource_deps/remote_pipeline/out.plan_skip.terraform.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.foo1": { - "action": "skip" - }, - "resources.pipelines.foo2": { - "action": "skip" - }, - "resources.pipelines.foo3": { - "action": "skip" - }, - "resources.pipelines.foo4": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/resource_deps/remote_pipeline/out.test.toml b/acceptance/bundle/resource_deps/remote_pipeline/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/remote_pipeline/out.test.toml +++ b/acceptance/bundle/resource_deps/remote_pipeline/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/remote_pipeline/script b/acceptance/bundle/resource_deps/remote_pipeline/script index 55ce2d8d37f..55f8ea67ebd 100644 --- a/acceptance/bundle/resource_deps/remote_pipeline/script +++ b/acceptance/bundle/resource_deps/remote_pipeline/script @@ -3,8 +3,8 @@ print_requests() { rm "$OUT_REQUESTS" } -$CLI bundle plan -o json | nostamp > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan_create.json trace $CLI bundle deploy trace print_requests -$CLI bundle plan -o json | nostamp > out.plan_skip.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan_skip.json trace print_requests diff --git a/acceptance/bundle/resource_deps/resources_var/out.drymigrate.terraform.txt b/acceptance/bundle/resource_deps/resources_var/out.drymigrate.terraform.txt deleted file mode 100644 index d7fac6e7778..00000000000 --- a/acceptance/bundle/resource_deps/resources_var/out.drymigrate.terraform.txt +++ /dev/null @@ -1,2 +0,0 @@ -direct_drymigrate_success true -direct_drymigrate_warnings false diff --git a/acceptance/bundle/empty_string_dropped/out.empty_sent_by_terraform_only.txt b/acceptance/bundle/resource_deps/resources_var/out.drymigrate.txt similarity index 100% rename from acceptance/bundle/empty_string_dropped/out.empty_sent_by_terraform_only.txt rename to acceptance/bundle/resource_deps/resources_var/out.drymigrate.txt diff --git a/acceptance/bundle/resource_deps/resources_var/out.plan.direct.json b/acceptance/bundle/resource_deps/resources_var/out.plan.json similarity index 100% rename from acceptance/bundle/resource_deps/resources_var/out.plan.direct.json rename to acceptance/bundle/resource_deps/resources_var/out.plan.json diff --git a/acceptance/bundle/resource_deps/resources_var/out.plan.terraform.json b/acceptance/bundle/resource_deps/resources_var/out.plan.terraform.json deleted file mode 100644 index 17c65100eb6..00000000000 --- a/acceptance/bundle/resource_deps/resources_var/out.plan.terraform.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.mypipeline": { - "action": "create" - }, - "resources.volumes.bar": { - "action": "create" - }, - "resources.volumes.foo": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resource_deps/resources_var/out.test.toml b/acceptance/bundle/resource_deps/resources_var/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/resources_var/out.test.toml +++ b/acceptance/bundle/resource_deps/resources_var/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/resources_var/script b/acceptance/bundle/resource_deps/resources_var/script index 365984de59d..b1e7955cfb1 100644 --- a/acceptance/bundle/resource_deps/resources_var/script +++ b/acceptance/bundle/resource_deps/resources_var/script @@ -1,7 +1,7 @@ trace $CLI bundle validate -t dev -o json | jq .resources -$CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan.json trace errcode $CLI bundle deploy -t dev &> out.deploy.txt trace jq -s '.[] | select(.path=="/api/2.0/pipelines") | .body.name' "$OUT_REQUESTS" trace print_telemetry_bool_values | grep -v direct_drymigrate -print_telemetry_bool_values | grep direct_drymigrate > out.drymigrate.$DATABRICKS_BUNDLE_ENGINE.txt || true +print_telemetry_bool_values | grep direct_drymigrate > out.drymigrate.txt || true rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/resource_deps/resources_var_presets/out.test.toml b/acceptance/bundle/resource_deps/resources_var_presets/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/resources_var_presets/out.test.toml +++ b/acceptance/bundle/resource_deps/resources_var_presets/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/resources_var_presets_implicit_deps/out.plan.direct.json b/acceptance/bundle/resource_deps/resources_var_presets_implicit_deps/out.plan.json similarity index 100% rename from acceptance/bundle/resource_deps/resources_var_presets_implicit_deps/out.plan.direct.json rename to acceptance/bundle/resource_deps/resources_var_presets_implicit_deps/out.plan.json diff --git a/acceptance/bundle/resource_deps/resources_var_presets_implicit_deps/out.plan.terraform.json b/acceptance/bundle/resource_deps/resources_var_presets_implicit_deps/out.plan.terraform.json deleted file mode 100644 index b49e5bd70d2..00000000000 --- a/acceptance/bundle/resource_deps/resources_var_presets_implicit_deps/out.plan.terraform.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.mypipeline": { - "action": "create" - }, - "resources.schemas.bar": { - "action": "create" - }, - "resources.volumes.foo": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resource_deps/resources_var_presets_implicit_deps/out.test.toml b/acceptance/bundle/resource_deps/resources_var_presets_implicit_deps/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/resources_var_presets_implicit_deps/out.test.toml +++ b/acceptance/bundle/resource_deps/resources_var_presets_implicit_deps/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/resources_var_presets_implicit_deps/script b/acceptance/bundle/resource_deps/resources_var_presets_implicit_deps/script index 49b2e660eac..13892f9325e 100644 --- a/acceptance/bundle/resource_deps/resources_var_presets_implicit_deps/script +++ b/acceptance/bundle/resource_deps/resources_var_presets_implicit_deps/script @@ -1,5 +1,5 @@ trace $CLI bundle validate -t dev -o json | jq .resources -$CLI bundle plan -o json -t dev | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json -t dev | nostamp > out.plan.json trace $CLI bundle deploy -t dev trace jq -s '.[] | select(.path=="/api/2.0/pipelines") | .body.name' "$OUT_REQUESTS" rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/resource_deps/run_state_resolution/apps/out.test.toml b/acceptance/bundle/resource_deps/run_state_resolution/apps/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/run_state_resolution/apps/out.test.toml +++ b/acceptance/bundle/resource_deps/run_state_resolution/apps/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/run_state_resolution/jobs/out.test.toml b/acceptance/bundle/resource_deps/run_state_resolution/jobs/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/run_state_resolution/jobs/out.test.toml +++ b/acceptance/bundle/resource_deps/run_state_resolution/jobs/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/run_state_resolution/pipelines/out.test.toml b/acceptance/bundle/resource_deps/run_state_resolution/pipelines/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/run_state_resolution/pipelines/out.test.toml +++ b/acceptance/bundle/resource_deps/run_state_resolution/pipelines/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/run_state_resolution/test.toml b/acceptance/bundle/resource_deps/run_state_resolution/test.toml index f3fcf048eee..201b14705db 100644 --- a/acceptance/bundle/resource_deps/run_state_resolution/test.toml +++ b/acceptance/bundle/resource_deps/run_state_resolution/test.toml @@ -1,4 +1,3 @@ # These tests exercise `bundle run`, which (unlike validate/deploy) resolves # ${resources.*} references against deployment state. --select is direct-engine only. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] RecordRequests = false diff --git a/acceptance/bundle/resource_deps/tf_path_only_error/out.deploy.terraform.txt b/acceptance/bundle/resource_deps/tf_path_only_error/out.deploy.terraform.txt deleted file mode 100644 index 9b50d3859c2..00000000000 --- a/acceptance/bundle/resource_deps/tf_path_only_error/out.deploy.terraform.txt +++ /dev/null @@ -1,8 +0,0 @@ -Warning: "resources.jobs.src.always_running": Terraform-only field; this reference will not work with the direct engine - in databricks.yml:10:13 - -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created jobs.dst -Created jobs.src -Files: 6 uploaded, 0 deleted -Resources: 2 created, 0 changed, 0 deleted, 0 unchanged diff --git a/acceptance/bundle/resource_deps/tf_path_only_error/out.deploy.direct.txt b/acceptance/bundle/resource_deps/tf_path_only_error/out.deploy.txt similarity index 100% rename from acceptance/bundle/resource_deps/tf_path_only_error/out.deploy.direct.txt rename to acceptance/bundle/resource_deps/tf_path_only_error/out.deploy.txt diff --git a/acceptance/bundle/resource_deps/tf_path_only_error/out.plan.terraform.txt b/acceptance/bundle/resource_deps/tf_path_only_error/out.plan.terraform.txt deleted file mode 100644 index ef7f5bf0c2f..00000000000 --- a/acceptance/bundle/resource_deps/tf_path_only_error/out.plan.terraform.txt +++ /dev/null @@ -1,7 +0,0 @@ -Warning: "resources.jobs.src.always_running": Terraform-only field; this reference will not work with the direct engine - in databricks.yml:10:13 - -create jobs.dst -create jobs.src - -Plan: 2 to add, 0 to change, 0 to delete, 0 unchanged diff --git a/acceptance/bundle/resource_deps/tf_path_only_error/out.plan.direct.txt b/acceptance/bundle/resource_deps/tf_path_only_error/out.plan.txt similarity index 100% rename from acceptance/bundle/resource_deps/tf_path_only_error/out.plan.direct.txt rename to acceptance/bundle/resource_deps/tf_path_only_error/out.plan.txt diff --git a/acceptance/bundle/resource_deps/tf_path_only_error/out.telemetry.terraform.txt b/acceptance/bundle/resource_deps/tf_path_only_error/out.telemetry.terraform.txt deleted file mode 100644 index 6075651fdde..00000000000 --- a/acceptance/bundle/resource_deps/tf_path_only_error/out.telemetry.terraform.txt +++ /dev/null @@ -1,23 +0,0 @@ -direct_drymigrate_success true -direct_drymigrate_warnings false -dms_compat_auto true -dms_undeclared_deploying_user false -dms_undeclared_group false -dms_undeclared_other_user false -dms_undeclared_service_principal false -experimental.use_legacy_run_as false -has_classic_interactive_compute false -has_classic_job_compute false -has_serverless_compute false -has_tf_only_references true -local.cache.attempt true -local.cache.hit true -permissions_section_set false -presets_name_prefix_is_set false -python_wheel_wrapper_is_set false -run_as_set false -skip_artifact_cleanup false -state_path_in_deployer_home true -state_path_in_other_user_home false -state_path_is_shared false -state_path_other false diff --git a/acceptance/bundle/resource_deps/tf_path_only_error/out.telemetry.direct.txt b/acceptance/bundle/resource_deps/tf_path_only_error/out.telemetry.txt similarity index 100% rename from acceptance/bundle/resource_deps/tf_path_only_error/out.telemetry.direct.txt rename to acceptance/bundle/resource_deps/tf_path_only_error/out.telemetry.txt diff --git a/acceptance/bundle/resource_deps/tf_path_only_error/out.test.toml b/acceptance/bundle/resource_deps/tf_path_only_error/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/tf_path_only_error/out.test.toml +++ b/acceptance/bundle/resource_deps/tf_path_only_error/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/tf_path_only_error/out.validate.terraform.txt b/acceptance/bundle/resource_deps/tf_path_only_error/out.validate.terraform.txt deleted file mode 100644 index 1d52bb5c81c..00000000000 --- a/acceptance/bundle/resource_deps/tf_path_only_error/out.validate.terraform.txt +++ /dev/null @@ -1,10 +0,0 @@ -Warning: "resources.jobs.src.always_running": Terraform-only field; this reference will not work with the direct engine - in databricks.yml:10:13 - -Name: test-bundle -Target: default -Workspace: - User: [USERNAME] - Path: /Workspace/Users/[USERNAME]/.bundle/test-bundle/default - -Found 1 warning diff --git a/acceptance/bundle/resource_deps/tf_path_only_error/out.validate.direct.txt b/acceptance/bundle/resource_deps/tf_path_only_error/out.validate.txt similarity index 100% rename from acceptance/bundle/resource_deps/tf_path_only_error/out.validate.direct.txt rename to acceptance/bundle/resource_deps/tf_path_only_error/out.validate.txt diff --git a/acceptance/bundle/resource_deps/tf_path_only_error/script b/acceptance/bundle/resource_deps/tf_path_only_error/script index 380f39b1e6b..3a32a4f1e31 100644 --- a/acceptance/bundle/resource_deps/tf_path_only_error/script +++ b/acceptance/bundle/resource_deps/tf_path_only_error/script @@ -1,5 +1,5 @@ -errcode $CLI bundle validate > out.validate.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 -errcode $CLI bundle plan > out.plan.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 -errcode $CLI bundle deploy > out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 -print_telemetry_bool_values > out.telemetry.$DATABRICKS_BUNDLE_ENGINE.txt +errcode $CLI bundle validate > out.validate.txt 2>&1 +errcode $CLI bundle plan > out.plan.txt 2>&1 +errcode $CLI bundle deploy > out.deploy.txt 2>&1 +print_telemetry_bool_values > out.telemetry.txt rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/resource_deps/tf_path_renames/out.plan.direct.json b/acceptance/bundle/resource_deps/tf_path_renames/out.plan.json similarity index 100% rename from acceptance/bundle/resource_deps/tf_path_renames/out.plan.direct.json rename to acceptance/bundle/resource_deps/tf_path_renames/out.plan.json diff --git a/acceptance/bundle/resource_deps/tf_path_renames/out.plan.terraform.json b/acceptance/bundle/resource_deps/tf_path_renames/out.plan.terraform.json deleted file mode 100644 index e02005dc043..00000000000 --- a/acceptance/bundle/resource_deps/tf_path_renames/out.plan.terraform.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.dst_git": { - "action": "create" - }, - "resources.jobs.dst_pipeline": { - "action": "create" - }, - "resources.jobs.dst_tasks": { - "action": "create" - }, - "resources.jobs.src_git": { - "action": "create" - }, - "resources.jobs.src_tasks": { - "action": "create" - }, - "resources.pipelines.src_pipeline": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resource_deps/tf_path_renames/out.test.toml b/acceptance/bundle/resource_deps/tf_path_renames/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/tf_path_renames/out.test.toml +++ b/acceptance/bundle/resource_deps/tf_path_renames/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/tf_path_renames/script b/acceptance/bundle/resource_deps/tf_path_renames/script index 8b082e9216a..3d50a5ac7a7 100644 --- a/acceptance/bundle/resource_deps/tf_path_renames/script +++ b/acceptance/bundle/resource_deps/tf_path_renames/script @@ -1,3 +1,3 @@ -trace $CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan.json trace $CLI bundle deploy print_requests.py //jobs | jq -rs '[.[].body.name] | sort[]' diff --git a/acceptance/bundle/resource_deps/underscore_key_reference/out.test.toml b/acceptance/bundle/resource_deps/underscore_key_reference/out.test.toml index dd4cf5e8994..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/underscore_key_reference/out.test.toml +++ b/acceptance/bundle/resource_deps/underscore_key_reference/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/underscore_key_reference/test.toml b/acceptance/bundle/resource_deps/underscore_key_reference/test.toml index 2d0d0ba09f5..a030353d571 100644 --- a/acceptance/bundle/resource_deps/underscore_key_reference/test.toml +++ b/acceptance/bundle/resource_deps/underscore_key_reference/test.toml @@ -1,2 +1 @@ RecordRequests = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] diff --git a/acceptance/bundle/resource_deps/unicode_reference/out.test.toml b/acceptance/bundle/resource_deps/unicode_reference/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/unicode_reference/out.test.toml +++ b/acceptance/bundle/resource_deps/unicode_reference/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/volume_path_contains_id/out.deploy.requests.direct.json b/acceptance/bundle/resource_deps/volume_path_contains_id/out.deploy.requests.json similarity index 100% rename from acceptance/bundle/resource_deps/volume_path_contains_id/out.deploy.requests.direct.json rename to acceptance/bundle/resource_deps/volume_path_contains_id/out.deploy.requests.json diff --git a/acceptance/bundle/resource_deps/volume_path_contains_id/out.deploy.requests.terraform.json b/acceptance/bundle/resource_deps/volume_path_contains_id/out.deploy.requests.terraform.json deleted file mode 100644 index a8cb2d0afcd..00000000000 --- a/acceptance/bundle/resource_deps/volume_path_contains_id/out.deploy.requests.terraform.json +++ /dev/null @@ -1,43 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.1/unity-catalog/volumes/mycatalog.myschema.bazname" -} -{ - "method": "GET", - "path": "/api/2.1/unity-catalog/volumes/mycatalog.myschema.fooname" -} -{ - "method": "GET", - "path": "/api/2.1/unity-catalog/volumes/mycatalog.myschema.mycatalog.myschema.bazname" -} -{ - "method": "POST", - "path": "/api/2.1/unity-catalog/volumes", - "body": { - "catalog_name": "mycatalog", - "comment": "/Volumes/mycatalog/myschema/mycatalog.myschema.bazname", - "name": "fooname", - "schema_name": "myschema", - "volume_type": "MANAGED" - } -} -{ - "method": "POST", - "path": "/api/2.1/unity-catalog/volumes", - "body": { - "catalog_name": "mycatalog", - "name": "bazname", - "schema_name": "myschema", - "volume_type": "MANAGED" - } -} -{ - "method": "POST", - "path": "/api/2.1/unity-catalog/volumes", - "body": { - "catalog_name": "mycatalog", - "name": "mycatalog.myschema.bazname", - "schema_name": "myschema", - "volume_type": "MANAGED" - } -} diff --git a/acceptance/bundle/resource_deps/volume_path_contains_id/out.plan.direct.json b/acceptance/bundle/resource_deps/volume_path_contains_id/out.plan.json similarity index 100% rename from acceptance/bundle/resource_deps/volume_path_contains_id/out.plan.direct.json rename to acceptance/bundle/resource_deps/volume_path_contains_id/out.plan.json diff --git a/acceptance/bundle/resource_deps/volume_path_contains_id/out.plan.terraform.json b/acceptance/bundle/resource_deps/volume_path_contains_id/out.plan.terraform.json deleted file mode 100644 index 1f098aa31e9..00000000000 --- a/acceptance/bundle/resource_deps/volume_path_contains_id/out.plan.terraform.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.volumes.bar": { - "action": "create" - }, - "resources.volumes.baz": { - "action": "create" - }, - "resources.volumes.foo": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resource_deps/volume_path_contains_id/out.test.toml b/acceptance/bundle/resource_deps/volume_path_contains_id/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/volume_path_contains_id/out.test.toml +++ b/acceptance/bundle/resource_deps/volume_path_contains_id/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/volume_path_contains_id/script b/acceptance/bundle/resource_deps/volume_path_contains_id/script index 5d561d60798..9ce52c2e087 100644 --- a/acceptance/bundle/resource_deps/volume_path_contains_id/script +++ b/acceptance/bundle/resource_deps/volume_path_contains_id/script @@ -5,7 +5,7 @@ cleanup() { trace $CLI bundle validate -o json | jq .resources trace $CLI bundle plan -$CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan.json trap cleanup EXIT trace errcode $CLI bundle deploy &> out.deploy.txt @@ -13,4 +13,4 @@ trace errcode $CLI bundle deploy &> out.deploy.txt # bar.name is created from baz.id (resolved during deploy), and foo.comment is # created with bar.volume_path, whose embedded baz.id reference also resolves # during deploy: -print_requests.py --sort --get //unity &> out.deploy.requests.$DATABRICKS_BUNDLE_ENGINE.json +print_requests.py --sort --get //unity &> out.deploy.requests.json diff --git a/acceptance/bundle/resource_deps/volume_path_job_ref/out.deploy.requests.direct.json b/acceptance/bundle/resource_deps/volume_path_job_ref/out.deploy.requests.json similarity index 100% rename from acceptance/bundle/resource_deps/volume_path_job_ref/out.deploy.requests.direct.json rename to acceptance/bundle/resource_deps/volume_path_job_ref/out.deploy.requests.json diff --git a/acceptance/bundle/resource_deps/volume_path_job_ref/out.deploy.direct.txt b/acceptance/bundle/resource_deps/volume_path_job_ref/out.deploy.txt similarity index 100% rename from acceptance/bundle/resource_deps/volume_path_job_ref/out.deploy.direct.txt rename to acceptance/bundle/resource_deps/volume_path_job_ref/out.deploy.txt diff --git a/acceptance/bundle/resource_deps/volume_path_job_ref/out.plan.direct.json b/acceptance/bundle/resource_deps/volume_path_job_ref/out.plan.json similarity index 100% rename from acceptance/bundle/resource_deps/volume_path_job_ref/out.plan.direct.json rename to acceptance/bundle/resource_deps/volume_path_job_ref/out.plan.json diff --git a/acceptance/bundle/resource_deps/volume_path_job_ref/out.test.toml b/acceptance/bundle/resource_deps/volume_path_job_ref/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resource_deps/volume_path_job_ref/out.test.toml +++ b/acceptance/bundle/resource_deps/volume_path_job_ref/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resource_deps/volume_path_job_ref/script b/acceptance/bundle/resource_deps/volume_path_job_ref/script index 0f2c279fecf..5298fc9cae6 100644 --- a/acceptance/bundle/resource_deps/volume_path_job_ref/script +++ b/acceptance/bundle/resource_deps/volume_path_job_ref/script @@ -8,9 +8,9 @@ trace $CLI bundle validate -o json | nostamp | jq '.resources.jobs, .resources.v # Untraced: with &> the trace header lands in the file, leaving it unfilterable. Capture the raw # plan aside and stamp it out into the golden instead. errcode $CLI bundle plan -o json &> .databricks/tmp.plan.json -nostamp < .databricks/tmp.plan.json > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +nostamp < .databricks/tmp.plan.json > out.plan.json # Deploy and inspect the create-job request: the parameter default sent to # the Jobs API must be the interpolated volume_path. -trace errcode $CLI bundle deploy &> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt -trace print_requests.py --nostamp //jobs > out.deploy.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace errcode $CLI bundle deploy &> out.deploy.txt +trace print_requests.py --nostamp //jobs > out.deploy.requests.json diff --git a/acceptance/bundle/resource_deps/volume_path_job_ref/test.toml b/acceptance/bundle/resource_deps/volume_path_job_ref/test.toml index b53e5e7fbe8..f4accc4579d 100644 --- a/acceptance/bundle/resource_deps/volume_path_job_ref/test.toml +++ b/acceptance/bundle/resource_deps/volume_path_job_ref/test.toml @@ -5,4 +5,3 @@ RecordRequests = true # direct engine resolves it at deploy; Terraform cannot export that attribute, # so the case is unsupported there (see CHANGELOG.md). Direct is the # default engine, so the motivating use case works out of the box. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/alerts/basic/out.test.toml b/acceptance/bundle/resources/alerts/basic/out.test.toml index 9aa264646c1..44f7ede3514 100644 --- a/acceptance/bundle/resources/alerts/basic/out.test.toml +++ b/acceptance/bundle/resources/alerts/basic/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/alerts/with_file/out.test.toml b/acceptance/bundle/resources/alerts/with_file/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/alerts/with_file/out.test.toml +++ b/acceptance/bundle/resources/alerts/with_file/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/alerts/with_file/test.toml b/acceptance/bundle/resources/alerts/with_file/test.toml index 7f56de1a834..4f5afd8aed9 100644 --- a/acceptance/bundle/resources/alerts/with_file/test.toml +++ b/acceptance/bundle/resources/alerts/with_file/test.toml @@ -12,7 +12,6 @@ TimeoutCloud = "5m" # Setting this environment variable prevents that conversion on windows. Env.MSYS_NO_PATHCONV = "1" -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] # redact ?[ow]=[NUMID]. Different clouds can have different URL serialization, like [DATABRICKS_URL]/sql/alerts-v2/[ALERT_ID] vs [DATABRICKS_URL]/sql/alerts-v2/[ALERT_ID]?o=[NUMID]. [[Repls]] diff --git a/acceptance/bundle/resources/alerts/with_file_not_allowed_field_error/out.test.toml b/acceptance/bundle/resources/alerts/with_file_not_allowed_field_error/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/alerts/with_file_not_allowed_field_error/out.test.toml +++ b/acceptance/bundle/resources/alerts/with_file_not_allowed_field_error/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/alerts/with_file_run_from_subdir/out.test.toml b/acceptance/bundle/resources/alerts/with_file_run_from_subdir/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/alerts/with_file_run_from_subdir/out.test.toml +++ b/acceptance/bundle/resources/alerts/with_file_run_from_subdir/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/alerts/with_file_variable_interpolation_error/out.test.toml b/acceptance/bundle/resources/alerts/with_file_variable_interpolation_error/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/alerts/with_file_variable_interpolation_error/out.test.toml +++ b/acceptance/bundle/resources/alerts/with_file_variable_interpolation_error/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/apps/config-drift-stopped/out.test.toml b/acceptance/bundle/resources/apps/config-drift-stopped/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/apps/config-drift-stopped/out.test.toml +++ b/acceptance/bundle/resources/apps/config-drift-stopped/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/apps/config-drift-stopped/test.toml b/acceptance/bundle/resources/apps/config-drift-stopped/test.toml index 52d07e6f9d0..4dfeae062b1 100644 --- a/acceptance/bundle/resources/apps/config-drift-stopped/test.toml +++ b/acceptance/bundle/resources/apps/config-drift-stopped/test.toml @@ -7,4 +7,3 @@ Ignore = [".databricks", "databricks.yml"] # Direct engine only: the skip logic lives in OverrideChangeDesc. Mirrors # config-no-deployment. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/apps/config-drift/out.plan.direct.json b/acceptance/bundle/resources/apps/config-drift/out.plan.json similarity index 100% rename from acceptance/bundle/resources/apps/config-drift/out.plan.direct.json rename to acceptance/bundle/resources/apps/config-drift/out.plan.json diff --git a/acceptance/bundle/resources/apps/config-drift/out.test.toml b/acceptance/bundle/resources/apps/config-drift/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/apps/config-drift/out.test.toml +++ b/acceptance/bundle/resources/apps/config-drift/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/apps/config-drift/script b/acceptance/bundle/resources/apps/config-drift/script index 76e0203a5d2..dbb4b7e5add 100644 --- a/acceptance/bundle/resources/apps/config-drift/script +++ b/acceptance/bundle/resources/apps/config-drift/script @@ -9,7 +9,7 @@ trap cleanup EXIT trace $CLI bundle deploy title "Verify no drift after deploy" -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.apps.myapp".changes.config // .plan."resources.apps.myapp".changes' | jq 'del(.[] | select(.action == "skip"))' > out.plan.direct.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.apps.myapp".changes.config // .plan."resources.apps.myapp".changes' | jq 'del(.[] | select(.action == "skip"))' > out.plan.json SOURCE_CODE_PATH=$(trace $CLI apps get $UNIQUE_NAME --output json | jq -r '.active_deployment.source_code_path') @@ -27,13 +27,13 @@ $CLI apps deploy $UNIQUE_NAME --no-wait --json '{ title "Plan should detect config drift" trace $CLI bundle plan # Skip entries with action "skip" -$CLI bundle plan -o json | nostamp | jq '.plan."resources.apps.myapp".changes.config // .plan."resources.apps.myapp".changes' | jq 'del(.[] | select(.action == "skip"))' >> out.plan.direct.json +$CLI bundle plan -o json | nostamp | jq '.plan."resources.apps.myapp".changes.config // .plan."resources.apps.myapp".changes' | jq 'del(.[] | select(.action == "skip"))' >> out.plan.json title "Redeploy to fix drift" trace $CLI bundle deploy title "Verify no drift after fix" -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.apps.myapp".changes.config // .plan."resources.apps.myapp".changes' | jq 'del(.[] | select(.action == "skip"))' >> out.plan.direct.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.apps.myapp".changes.config // .plan."resources.apps.myapp".changes' | jq 'del(.[] | select(.action == "skip"))' >> out.plan.json # TODO: add test for git_source drift when git_source is supported in the Deploy API # Currently it fails with the error: Git source reference is required diff --git a/acceptance/bundle/resources/apps/config-drift/test.toml b/acceptance/bundle/resources/apps/config-drift/test.toml index 008df4681cf..34cb320c59d 100644 --- a/acceptance/bundle/resources/apps/config-drift/test.toml +++ b/acceptance/bundle/resources/apps/config-drift/test.toml @@ -3,7 +3,6 @@ RecordRequests = true Ignore = [".databricks", "databricks.yml"] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # App deployment progress messages are non-deterministic on cloud (different status messages # per poll), so filter them out entirely. diff --git a/acceptance/bundle/resources/apps/config-no-deployment/out.test.toml b/acceptance/bundle/resources/apps/config-no-deployment/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/apps/config-no-deployment/out.test.toml +++ b/acceptance/bundle/resources/apps/config-no-deployment/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/apps/config-no-deployment/test.toml b/acceptance/bundle/resources/apps/config-no-deployment/test.toml index 4cd599ddea9..d9baa9e54ce 100644 --- a/acceptance/bundle/resources/apps/config-no-deployment/test.toml +++ b/acceptance/bundle/resources/apps/config-no-deployment/test.toml @@ -7,4 +7,3 @@ Ignore = [".databricks"] # Direct engine only: the skip logic lives in OverrideChangeDesc. Mirrors # lifecycle-started-omitted. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/apps/create_already_exists/out.test.toml b/acceptance/bundle/resources/apps/create_already_exists/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/apps/create_already_exists/out.test.toml +++ b/acceptance/bundle/resources/apps/create_already_exists/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/apps/create_already_exists/test.toml b/acceptance/bundle/resources/apps/create_already_exists/test.toml index bed5e07e897..262a6f41b15 100644 --- a/acceptance/bundle/resources/apps/create_already_exists/test.toml +++ b/acceptance/bundle/resources/apps/create_already_exists/test.toml @@ -1,4 +1,2 @@ Cloud = false RecordRequests = false - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/apps/default_description/out.test.toml b/acceptance/bundle/resources/apps/default_description/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/apps/default_description/out.test.toml +++ b/acceptance/bundle/resources/apps/default_description/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/apps/git-source-no-deployment/out.test.toml b/acceptance/bundle/resources/apps/git-source-no-deployment/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/apps/git-source-no-deployment/out.test.toml +++ b/acceptance/bundle/resources/apps/git-source-no-deployment/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/apps/git-source-no-deployment/test.toml b/acceptance/bundle/resources/apps/git-source-no-deployment/test.toml index f6165222373..9910ae755f3 100644 --- a/acceptance/bundle/resources/apps/git-source-no-deployment/test.toml +++ b/acceptance/bundle/resources/apps/git-source-no-deployment/test.toml @@ -7,4 +7,3 @@ Ignore = [".databricks"] # Direct engine only: the skip logic lives in OverrideChangeDesc. Mirrors # config-no-deployment. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/apps/immutable/out.test.toml b/acceptance/bundle/resources/apps/immutable/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/apps/immutable/out.test.toml +++ b/acceptance/bundle/resources/apps/immutable/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/apps/immutable/test.toml b/acceptance/bundle/resources/apps/immutable/test.toml index 862d8d8535c..87f29291d0e 100644 --- a/acceptance/bundle/resources/apps/immutable/test.toml +++ b/acceptance/bundle/resources/apps/immutable/test.toml @@ -2,7 +2,6 @@ Cloud = false # Temporary disable cloud tests until the API is fully available RecordRequests = true # immutable_folder only works with the direct engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ "databricks.yml", diff --git a/acceptance/bundle/resources/apps/inline_config/out.test.toml b/acceptance/bundle/resources/apps/inline_config/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/apps/inline_config/out.test.toml +++ b/acceptance/bundle/resources/apps/inline_config/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/apps/lifecycle-started-omitted/out.test.toml b/acceptance/bundle/resources/apps/lifecycle-started-omitted/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/apps/lifecycle-started-omitted/out.test.toml +++ b/acceptance/bundle/resources/apps/lifecycle-started-omitted/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/apps/lifecycle-started-omitted/test.toml b/acceptance/bundle/resources/apps/lifecycle-started-omitted/test.toml index c07e4fe3a26..30585e1c85d 100644 --- a/acceptance/bundle/resources/apps/lifecycle-started-omitted/test.toml +++ b/acceptance/bundle/resources/apps/lifecycle-started-omitted/test.toml @@ -3,7 +3,6 @@ RecordRequests = true Ignore = [".databricks", "databricks.yml"] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # App deployment progress messages are non-deterministic on cloud (different status messages # per poll), so filter them out entirely. diff --git a/acceptance/bundle/resources/apps/lifecycle-started-terraform-error/app/app.py b/acceptance/bundle/resources/apps/lifecycle-started-terraform-error/app/app.py deleted file mode 100644 index ad1e64f9fb0..00000000000 --- a/acceptance/bundle/resources/apps/lifecycle-started-terraform-error/app/app.py +++ /dev/null @@ -1,5 +0,0 @@ -import http.server, os - -http.server.HTTPServer( - ("", int(os.environ["DATABRICKS_APP_PORT"])), http.server.SimpleHTTPRequestHandler -).serve_forever() diff --git a/acceptance/bundle/resources/apps/lifecycle-started-terraform-error/databricks.yml.tmpl b/acceptance/bundle/resources/apps/lifecycle-started-terraform-error/databricks.yml.tmpl deleted file mode 100644 index ee78dfc1502..00000000000 --- a/acceptance/bundle/resources/apps/lifecycle-started-terraform-error/databricks.yml.tmpl +++ /dev/null @@ -1,11 +0,0 @@ -bundle: - name: lifecycle-started-$UNIQUE_NAME - -resources: - apps: - myapp: - name: $UNIQUE_NAME - description: my_app_description - source_code_path: ./app - lifecycle: - started: true diff --git a/acceptance/bundle/resources/apps/lifecycle-started-terraform-error/out.test.toml b/acceptance/bundle/resources/apps/lifecycle-started-terraform-error/out.test.toml deleted file mode 100644 index 19131430a06..00000000000 --- a/acceptance/bundle/resources/apps/lifecycle-started-terraform-error/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] -EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/apps/lifecycle-started-terraform-error/output.txt b/acceptance/bundle/resources/apps/lifecycle-started-terraform-error/output.txt deleted file mode 100644 index 80395fe51aa..00000000000 --- a/acceptance/bundle/resources/apps/lifecycle-started-terraform-error/output.txt +++ /dev/null @@ -1,16 +0,0 @@ - -=== bundle plan fails with lifecycle.started on terraform engine ->>> errcode [CLI] bundle plan -Error: lifecycle.started is only supported in direct deployment mode - in databricks.yml:11:18 - - -Exit code: 1 - -=== bundle deploy fails with lifecycle.started on terraform engine ->>> errcode [CLI] bundle deploy -Error: lifecycle.started is only supported in direct deployment mode - in databricks.yml:11:18 - - -Exit code: 1 diff --git a/acceptance/bundle/resources/apps/lifecycle-started-terraform-error/script b/acceptance/bundle/resources/apps/lifecycle-started-terraform-error/script deleted file mode 100644 index 4fb2038cd28..00000000000 --- a/acceptance/bundle/resources/apps/lifecycle-started-terraform-error/script +++ /dev/null @@ -1,7 +0,0 @@ -envsubst < databricks.yml.tmpl > databricks.yml - -title "bundle plan fails with lifecycle.started on terraform engine" -trace errcode $CLI bundle plan - -title "bundle deploy fails with lifecycle.started on terraform engine" -trace errcode $CLI bundle deploy diff --git a/acceptance/bundle/resources/apps/lifecycle-started-terraform-error/test.toml b/acceptance/bundle/resources/apps/lifecycle-started-terraform-error/test.toml deleted file mode 100644 index a80ad730d07..00000000000 --- a/acceptance/bundle/resources/apps/lifecycle-started-terraform-error/test.toml +++ /dev/null @@ -1,4 +0,0 @@ -Cloud = true -RecordRequests = false - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] diff --git a/acceptance/bundle/resources/apps/lifecycle-started-toggle/out.test.toml b/acceptance/bundle/resources/apps/lifecycle-started-toggle/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/apps/lifecycle-started-toggle/out.test.toml +++ b/acceptance/bundle/resources/apps/lifecycle-started-toggle/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/apps/lifecycle-started-toggle/test.toml b/acceptance/bundle/resources/apps/lifecycle-started-toggle/test.toml index c07e4fe3a26..30585e1c85d 100644 --- a/acceptance/bundle/resources/apps/lifecycle-started-toggle/test.toml +++ b/acceptance/bundle/resources/apps/lifecycle-started-toggle/test.toml @@ -3,7 +3,6 @@ RecordRequests = true Ignore = [".databricks", "databricks.yml"] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # App deployment progress messages are non-deterministic on cloud (different status messages # per poll), so filter them out entirely. diff --git a/acceptance/bundle/resources/apps/lifecycle-started/out.test.toml b/acceptance/bundle/resources/apps/lifecycle-started/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/apps/lifecycle-started/out.test.toml +++ b/acceptance/bundle/resources/apps/lifecycle-started/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/apps/lifecycle-started/test.toml b/acceptance/bundle/resources/apps/lifecycle-started/test.toml index c07e4fe3a26..30585e1c85d 100644 --- a/acceptance/bundle/resources/apps/lifecycle-started/test.toml +++ b/acceptance/bundle/resources/apps/lifecycle-started/test.toml @@ -3,7 +3,6 @@ RecordRequests = true Ignore = [".databricks", "databricks.yml"] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # App deployment progress messages are non-deterministic on cloud (different status messages # per poll), so filter them out entirely. diff --git a/acceptance/bundle/resources/apps/readplan-lifecycle/out.test.toml b/acceptance/bundle/resources/apps/readplan-lifecycle/out.test.toml index dd03baaabb6..f7fafbcc731 100644 --- a/acceptance/bundle/resources/apps/readplan-lifecycle/out.test.toml +++ b/acceptance/bundle/resources/apps/readplan-lifecycle/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resources/apps/readplan-lifecycle/test.toml b/acceptance/bundle/resources/apps/readplan-lifecycle/test.toml index 6c0fc07b74a..bba2c801b7d 100644 --- a/acceptance/bundle/resources/apps/readplan-lifecycle/test.toml +++ b/acceptance/bundle/resources/apps/readplan-lifecycle/test.toml @@ -1,7 +1,6 @@ Cloud = false Ignore = [".databricks", "tmp.plan.json"] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.READPLAN = ["", "1"] [[Repls]] diff --git a/acceptance/bundle/resources/apps/resource-refs/out.test.toml b/acceptance/bundle/resources/apps/resource-refs/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/apps/resource-refs/out.test.toml +++ b/acceptance/bundle/resources/apps/resource-refs/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/apps/uc-securable-drift/out.test.toml b/acceptance/bundle/resources/apps/uc-securable-drift/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/apps/uc-securable-drift/out.test.toml +++ b/acceptance/bundle/resources/apps/uc-securable-drift/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/apps/uc-securable-drift/test.toml b/acceptance/bundle/resources/apps/uc-securable-drift/test.toml index 5a8fd7adb65..b0e20067d7e 100644 --- a/acceptance/bundle/resources/apps/uc-securable-drift/test.toml +++ b/acceptance/bundle/resources/apps/uc-securable-drift/test.toml @@ -4,5 +4,3 @@ RecordRequests = false Ignore = [".databricks", "databricks.yml"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/apps/update/out.requests.direct.json b/acceptance/bundle/resources/apps/update/out.requests.json similarity index 100% rename from acceptance/bundle/resources/apps/update/out.requests.direct.json rename to acceptance/bundle/resources/apps/update/out.requests.json diff --git a/acceptance/bundle/resources/apps/update/out.requests.terraform.json b/acceptance/bundle/resources/apps/update/out.requests.terraform.json deleted file mode 100644 index 7435f53587a..00000000000 --- a/acceptance/bundle/resources/apps/update/out.requests.terraform.json +++ /dev/null @@ -1,41 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/apps", - "q": { - "no_compute": "true" - }, - "body": { - "description": "my_app_description", - "name": "myappname" - } -} -{ - "method": "PATCH", - "path": "/api/2.0/apps/myappname", - "body": { - "description": "MY_APP_DESCRIPTION", - "name": "myappname", - "service_principal_client_id": "[UUID]", - "service_principal_id": [NUMID], - "service_principal_name": "app-myappname" - } -} -{ - "method": "DELETE", - "path": "/api/2.0/apps/myappname" -} -{ - "method": "POST", - "path": "/api/2.0/apps", - "q": { - "no_compute": "true" - }, - "body": { - "description": "MY_APP_DESCRIPTION", - "name": "mynewappname" - } -} -{ - "method": "DELETE", - "path": "/api/2.0/apps/mynewappname" -} diff --git a/acceptance/bundle/resources/apps/update/out.test.toml b/acceptance/bundle/resources/apps/update/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/apps/update/out.test.toml +++ b/acceptance/bundle/resources/apps/update/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/apps/update/script b/acceptance/bundle/resources/apps/update/script index 1b9faa07547..f3578c95c54 100644 --- a/acceptance/bundle/resources/apps/update/script +++ b/acceptance/bundle/resources/apps/update/script @@ -5,14 +5,14 @@ print_requests() { trace $CLI bundle plan trace $CLI bundle deploy -trace print_requests > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests > out.requests.json trace $CLI bundle summary title "Update description and re-deploy" trace update_file.py databricks.yml my_app_description MY_APP_DESCRIPTION trace $CLI bundle plan trace $CLI bundle deploy -trace print_requests >> out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests >> out.requests.json trace $CLI bundle summary title "Update name and re-deploy" @@ -20,9 +20,9 @@ trace update_file.py databricks.yml myappname mynewappname trace $CLI bundle plan trace $CLI bundle summary trace $CLI bundle deploy -trace print_requests >> out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests >> out.requests.json trace $CLI bundle plan trace $CLI bundle summary trace $CLI bundle destroy --auto-approve -trace print_requests >> out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests >> out.requests.json diff --git a/acceptance/bundle/resources/catalogs/auto-approve/out.test.toml b/acceptance/bundle/resources/catalogs/auto-approve/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/catalogs/auto-approve/out.test.toml +++ b/acceptance/bundle/resources/catalogs/auto-approve/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/catalogs/auto-approve/test.toml b/acceptance/bundle/resources/catalogs/auto-approve/test.toml index 62edfd8f3fe..812d713d12d 100644 --- a/acceptance/bundle/resources/catalogs/auto-approve/test.toml +++ b/acceptance/bundle/resources/catalogs/auto-approve/test.toml @@ -7,5 +7,3 @@ Ignore = [ "catalog.yml", "test-file-*.txt", ] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/catalogs/basic/out.test.toml b/acceptance/bundle/resources/catalogs/basic/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/catalogs/basic/out.test.toml +++ b/acceptance/bundle/resources/catalogs/basic/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/catalogs/basic/test.toml b/acceptance/bundle/resources/catalogs/basic/test.toml index 567e35db313..37e1006eb5a 100644 --- a/acceptance/bundle/resources/catalogs/basic/test.toml +++ b/acceptance/bundle/resources/catalogs/basic/test.toml @@ -5,5 +5,3 @@ Ignore = [ ".databricks", "databricks.yml", ] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/catalogs/comment_out_of_band/out.test.toml b/acceptance/bundle/resources/catalogs/comment_out_of_band/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/catalogs/comment_out_of_band/out.test.toml +++ b/acceptance/bundle/resources/catalogs/comment_out_of_band/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/catalogs/comment_out_of_band/test.toml b/acceptance/bundle/resources/catalogs/comment_out_of_band/test.toml index 78d1d7f450b..47e0ed4dda2 100644 --- a/acceptance/bundle/resources/catalogs/comment_out_of_band/test.toml +++ b/acceptance/bundle/resources/catalogs/comment_out_of_band/test.toml @@ -1,7 +1,6 @@ Cloud = true # UpdateCatalog payload construction is direct-engine-specific. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ ".databricks", diff --git a/acceptance/bundle/resources/catalogs/drift/managed_properties/out.test.toml b/acceptance/bundle/resources/catalogs/drift/managed_properties/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/catalogs/drift/managed_properties/out.test.toml +++ b/acceptance/bundle/resources/catalogs/drift/managed_properties/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/catalogs/drift/managed_properties/test.toml b/acceptance/bundle/resources/catalogs/drift/managed_properties/test.toml index 3780cb322a0..c847c5fb439 100644 --- a/acceptance/bundle/resources/catalogs/drift/managed_properties/test.toml +++ b/acceptance/bundle/resources/catalogs/drift/managed_properties/test.toml @@ -2,4 +2,3 @@ RecordRequests = true # Terraform issues a spurious PATCH for enable_predictive_optimization on every # deploy, which is outside the scope of backend-default handling in catalogs.yml. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/catalogs/empty-name/out.test.toml b/acceptance/bundle/resources/catalogs/empty-name/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/catalogs/empty-name/out.test.toml +++ b/acceptance/bundle/resources/catalogs/empty-name/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/catalogs/empty-name/test.toml b/acceptance/bundle/resources/catalogs/empty-name/test.toml index 458319b24ad..307b9b89bf9 100644 --- a/acceptance/bundle/resources/catalogs/empty-name/test.toml +++ b/acceptance/bundle/resources/catalogs/empty-name/test.toml @@ -5,4 +5,3 @@ Ignore = [".databricks"] # Terraform rejects catalog resources before any API call, so there is nothing to # assert on that engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/catalogs/with-schemas/out.test.toml b/acceptance/bundle/resources/catalogs/with-schemas/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/catalogs/with-schemas/out.test.toml +++ b/acceptance/bundle/resources/catalogs/with-schemas/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/catalogs/with-schemas/test.toml b/acceptance/bundle/resources/catalogs/with-schemas/test.toml index 567e35db313..37e1006eb5a 100644 --- a/acceptance/bundle/resources/catalogs/with-schemas/test.toml +++ b/acceptance/bundle/resources/catalogs/with-schemas/test.toml @@ -5,5 +5,3 @@ Ignore = [ ".databricks", "databricks.yml", ] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/cluster_policies/backend_normalization/out.test.toml b/acceptance/bundle/resources/cluster_policies/backend_normalization/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/cluster_policies/backend_normalization/out.test.toml +++ b/acceptance/bundle/resources/cluster_policies/backend_normalization/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/cluster_policies/backend_normalization/test.toml b/acceptance/bundle/resources/cluster_policies/backend_normalization/test.toml index 435ad6e2630..b75424fcbd5 100644 --- a/acceptance/bundle/resources/cluster_policies/backend_normalization/test.toml +++ b/acceptance/bundle/resources/cluster_policies/backend_normalization/test.toml @@ -1,5 +1,4 @@ RecordRequests = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ ".databricks", "databricks.yml", diff --git a/acceptance/bundle/resources/cluster_policies/basic/out.test.toml b/acceptance/bundle/resources/cluster_policies/basic/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/cluster_policies/basic/out.test.toml +++ b/acceptance/bundle/resources/cluster_policies/basic/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/cluster_policies/definition_and_family_conflict/out.test.toml b/acceptance/bundle/resources/cluster_policies/definition_and_family_conflict/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/cluster_policies/definition_and_family_conflict/out.test.toml +++ b/acceptance/bundle/resources/cluster_policies/definition_and_family_conflict/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/cluster_policies/definition_multiline/out.test.toml b/acceptance/bundle/resources/cluster_policies/definition_multiline/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/cluster_policies/definition_multiline/out.test.toml +++ b/acceptance/bundle/resources/cluster_policies/definition_multiline/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/cluster_policies/definition_yaml/out.test.toml b/acceptance/bundle/resources/cluster_policies/definition_yaml/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/cluster_policies/definition_yaml/out.test.toml +++ b/acceptance/bundle/resources/cluster_policies/definition_yaml/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/cluster_policies/job_ref/out.test.toml b/acceptance/bundle/resources/cluster_policies/job_ref/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/cluster_policies/job_ref/out.test.toml +++ b/acceptance/bundle/resources/cluster_policies/job_ref/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/cluster_policies/out_of_band_change/out.test.toml b/acceptance/bundle/resources/cluster_policies/out_of_band_change/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/cluster_policies/out_of_band_change/out.test.toml +++ b/acceptance/bundle/resources/cluster_policies/out_of_band_change/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/cluster_policies/permissions/levels/out.test.toml b/acceptance/bundle/resources/cluster_policies/permissions/levels/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/cluster_policies/permissions/levels/out.test.toml +++ b/acceptance/bundle/resources/cluster_policies/permissions/levels/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/cluster_policies/permissions/out_of_band_deletion/out.test.toml b/acceptance/bundle/resources/cluster_policies/permissions/out_of_band_deletion/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/cluster_policies/permissions/out_of_band_deletion/out.test.toml +++ b/acceptance/bundle/resources/cluster_policies/permissions/out_of_band_deletion/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/cluster_policies/permissions/out_of_band_grant/out.test.toml b/acceptance/bundle/resources/cluster_policies/permissions/out_of_band_grant/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/cluster_policies/permissions/out_of_band_grant/out.test.toml +++ b/acceptance/bundle/resources/cluster_policies/permissions/out_of_band_grant/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/cluster_policies/policy_family_definition/out.test.toml b/acceptance/bundle/resources/cluster_policies/policy_family_definition/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/cluster_policies/policy_family_definition/out.test.toml +++ b/acceptance/bundle/resources/cluster_policies/policy_family_definition/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/cluster_policies/policy_family_overrides/out.test.toml b/acceptance/bundle/resources/cluster_policies/policy_family_overrides/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/cluster_policies/policy_family_overrides/out.test.toml +++ b/acceptance/bundle/resources/cluster_policies/policy_family_overrides/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/cluster_policies/test.toml b/acceptance/bundle/resources/cluster_policies/test.toml index d9b1de47061..36c17b2ed41 100644 --- a/acceptance/bundle/resources/cluster_policies/test.toml +++ b/acceptance/bundle/resources/cluster_policies/test.toml @@ -1,5 +1,4 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ "databricks.yml", diff --git a/acceptance/bundle/resources/clusters/cluster_policy/out.test.toml b/acceptance/bundle/resources/clusters/cluster_policy/out.test.toml index f9f4880725d..8bfa768b35b 100644 --- a/acceptance/bundle/resources/clusters/cluster_policy/out.test.toml +++ b/acceptance/bundle/resources/clusters/cluster_policy/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/clusters/cluster_policy/test.toml b/acceptance/bundle/resources/clusters/cluster_policy/test.toml index a3789595417..523edb2c8e0 100644 --- a/acceptance/bundle/resources/clusters/cluster_policy/test.toml +++ b/acceptance/bundle/resources/clusters/cluster_policy/test.toml @@ -3,7 +3,6 @@ # in the full cloud sweep). Output is projected to the policy tag so it is cloud-portable. Cloud = true CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] RecordRequests = false diff --git a/acceptance/bundle/resources/clusters/deploy/data_security_mode/out.test.toml b/acceptance/bundle/resources/clusters/deploy/data_security_mode/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/clusters/deploy/data_security_mode/out.test.toml +++ b/acceptance/bundle/resources/clusters/deploy/data_security_mode/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/clusters/deploy/instance_pool/out.test.toml b/acceptance/bundle/resources/clusters/deploy/instance_pool/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/clusters/deploy/instance_pool/out.test.toml +++ b/acceptance/bundle/resources/clusters/deploy/instance_pool/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/clusters/deploy/instance_pool_and_node_type/out.test.toml b/acceptance/bundle/resources/clusters/deploy/instance_pool_and_node_type/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/clusters/deploy/instance_pool_and_node_type/out.test.toml +++ b/acceptance/bundle/resources/clusters/deploy/instance_pool_and_node_type/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/clusters/deploy/local_ssd_count/out.requests.direct.json b/acceptance/bundle/resources/clusters/deploy/local_ssd_count/out.requests.json similarity index 100% rename from acceptance/bundle/resources/clusters/deploy/local_ssd_count/out.requests.direct.json rename to acceptance/bundle/resources/clusters/deploy/local_ssd_count/out.requests.json diff --git a/acceptance/bundle/resources/clusters/deploy/local_ssd_count/out.requests.terraform.json b/acceptance/bundle/resources/clusters/deploy/local_ssd_count/out.requests.terraform.json deleted file mode 100644 index f8ef61075c4..00000000000 --- a/acceptance/bundle/resources/clusters/deploy/local_ssd_count/out.requests.terraform.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.1/clusters/create", - "body": { - "autotermination_minutes": 60, - "cluster_name": "test-cluster-[UNIQUE_NAME]", - "gcp_attributes": { - "availability": "PREEMPTIBLE_GCP", - "zone_id": "auto" - }, - "node_type_id": "[NODE_TYPE_ID]", - "num_workers": 1, - "spark_version": "13.3.x-snapshot-scala2.12" - } -} diff --git a/acceptance/bundle/resources/clusters/deploy/local_ssd_count/out.result.terraform.txt b/acceptance/bundle/resources/clusters/deploy/local_ssd_count/out.result.terraform.txt deleted file mode 100644 index b92f0cc5fa6..00000000000 --- a/acceptance/bundle/resources/clusters/deploy/local_ssd_count/out.result.terraform.txt +++ /dev/null @@ -1,4 +0,0 @@ -json.gcp_attributes.availability = "PREEMPTIBLE_GCP"; -json.gcp_attributes.first_on_demand = 1; -json.gcp_attributes.use_preemptible_executors = false; -json.gcp_attributes.zone_id = "auto"; diff --git a/acceptance/bundle/resources/clusters/deploy/local_ssd_count/out.result.direct.txt b/acceptance/bundle/resources/clusters/deploy/local_ssd_count/out.result.txt similarity index 100% rename from acceptance/bundle/resources/clusters/deploy/local_ssd_count/out.result.direct.txt rename to acceptance/bundle/resources/clusters/deploy/local_ssd_count/out.result.txt diff --git a/acceptance/bundle/resources/clusters/deploy/local_ssd_count/out.test.toml b/acceptance/bundle/resources/clusters/deploy/local_ssd_count/out.test.toml index 5fdd615973c..729951c6593 100644 --- a/acceptance/bundle/resources/clusters/deploy/local_ssd_count/out.test.toml +++ b/acceptance/bundle/resources/clusters/deploy/local_ssd_count/out.test.toml @@ -2,5 +2,4 @@ Cloud = true CloudEnvs.aws = false CloudEnvs.azure = false CloudEnvs.gcp = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/clusters/deploy/local_ssd_count/script b/acceptance/bundle/resources/clusters/deploy/local_ssd_count/script index e6994c1eb01..7455e441da8 100644 --- a/acceptance/bundle/resources/clusters/deploy/local_ssd_count/script +++ b/acceptance/bundle/resources/clusters/deploy/local_ssd_count/script @@ -7,8 +7,8 @@ cleanup() { trap cleanup EXIT trace $CLI bundle deploy -print_requests.py //cluster > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +print_requests.py //cluster > out.requests.json title "Cluster should exist after bundle deployment:\n" CLUSTER_ID=`read_id.py test_cluster` -$CLI clusters get "${CLUSTER_ID}" | gron.py | grep json.gcp_attributes > out.result.$DATABRICKS_BUNDLE_ENGINE.txt +$CLI clusters get "${CLUSTER_ID}" | gron.py | grep json.gcp_attributes > out.result.txt diff --git a/acceptance/bundle/resources/clusters/deploy/num_workers_absent/out.test.toml b/acceptance/bundle/resources/clusters/deploy/num_workers_absent/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/clusters/deploy/num_workers_absent/out.test.toml +++ b/acceptance/bundle/resources/clusters/deploy/num_workers_absent/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/clusters/deploy/simple/out.test.toml b/acceptance/bundle/resources/clusters/deploy/simple/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/clusters/deploy/simple/out.test.toml +++ b/acceptance/bundle/resources/clusters/deploy/simple/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/clusters/deploy/update-after-create/out.test.toml b/acceptance/bundle/resources/clusters/deploy/update-after-create/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/clusters/deploy/update-after-create/out.test.toml +++ b/acceptance/bundle/resources/clusters/deploy/update-after-create/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/out.plan_.direct.json b/acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/out.plan_.json similarity index 100% rename from acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/out.plan_.direct.json rename to acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/out.plan_.json diff --git a/acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/out.plan_.terraform.json b/acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/out.plan_.terraform.json deleted file mode 100644 index d3c66d89f8f..00000000000 --- a/acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/out.plan_.terraform.json +++ /dev/null @@ -1,40 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.clusters.test_cluster": { - "action": "create" - } - } -} -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.clusters.test_cluster": { - "action": "update" - } - } -} -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.clusters.test_cluster": { - "action": "update" - } - } -} -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.clusters.test_cluster": { - "action": "update" - } - } -} -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.clusters.test_cluster": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/out.plan_.terraform.txt b/acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/out.plan_.terraform.txt deleted file mode 100644 index 73b40dacde6..00000000000 --- a/acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/out.plan_.terraform.txt +++ /dev/null @@ -1,15 +0,0 @@ -create clusters.test_cluster - -Plan: 1 to add, 0 to change, 0 to delete, 0 unchanged -update clusters.test_cluster - -Plan: 0 to add, 1 to change, 0 to delete, 0 unchanged -update clusters.test_cluster - -Plan: 0 to add, 1 to change, 0 to delete, 0 unchanged -update clusters.test_cluster - -Plan: 0 to add, 1 to change, 0 to delete, 0 unchanged -update clusters.test_cluster - -Plan: 0 to add, 1 to change, 0 to delete, 0 unchanged diff --git a/acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/out.plan_.direct.txt b/acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/out.plan_.txt similarity index 100% rename from acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/out.plan_.direct.txt rename to acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/out.plan_.txt diff --git a/acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/out.test.toml b/acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/out.test.toml +++ b/acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/script b/acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/script index 60cc69d7038..e336ebc564f 100755 --- a/acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/script +++ b/acceptance/bundle/resources/clusters/deploy/update-and-resize-autoscale/script @@ -9,8 +9,8 @@ trap cleanup EXIT # Deploy with -q throughout: the engines name this action differently (direct reports # resize, terraform update), so the per-resource line would diverge. The Resources: # summary agrees, so it is kept rather than using -qq. -$CLI bundle plan > out.plan_.$DATABRICKS_BUNDLE_ENGINE.txt -$CLI bundle plan -o json | nostamp > out.plan_.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan > out.plan_.txt +$CLI bundle plan -o json | nostamp > out.plan_.json trace $CLI bundle deploy -q title "Cluster should exist with num_workers after bundle deployment:\n" @@ -25,8 +25,8 @@ title "Adding autoscale section should call update API on stopped cluster\n" update_file.py databricks.yml " num_workers: 2" " autoscale: min_workers: 2 max_workers: 4" -$CLI bundle plan >> out.plan_.$DATABRICKS_BUNDLE_ENGINE.txt -$CLI bundle plan -o json | nostamp >> out.plan_.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan >> out.plan_.txt +$CLI bundle plan -o json | nostamp >> out.plan_.json trace $CLI bundle deploy -q trace jq 'select(.method == "POST" and (.path | contains("/clusters/edit"))) | del(.body.aws_attributes, .body.driver_node_type_id, .body.data_security_mode, .body.enable_elastic_disk)' "$OUT_REQUESTS" rm "$OUT_REQUESTS" @@ -37,8 +37,8 @@ $CLI clusters get "${CLUSTER_ID}" | jq '{cluster_name,num_workers,autoscale}' title "Changing autoscale should call update API on stopped cluster\n" update_file.py databricks.yml "min_workers: 2" "min_workers: 3" update_file.py databricks.yml "max_workers: 4" "max_workers: 5" -$CLI bundle plan >> out.plan_.$DATABRICKS_BUNDLE_ENGINE.txt -$CLI bundle plan -o json | nostamp >> out.plan_.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan >> out.plan_.txt +$CLI bundle plan -o json | nostamp >> out.plan_.json trace $CLI bundle deploy -q trace jq 'select(.method == "POST" and (.path | contains("/clusters/edit"))) | del(.body.aws_attributes, .body.driver_node_type_id, .body.data_security_mode, .body.enable_elastic_disk)' "$OUT_REQUESTS" rm "$OUT_REQUESTS" @@ -52,8 +52,8 @@ $CLI clusters start "${CLUSTER_ID}" title "Changing autoscale should call resize API on running cluster\n" update_file.py databricks.yml "min_workers: 3" "min_workers: 4" update_file.py databricks.yml "max_workers: 5" "max_workers: 6" -$CLI bundle plan >> out.plan_.$DATABRICKS_BUNDLE_ENGINE.txt -$CLI bundle plan -o json | nostamp >> out.plan_.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan >> out.plan_.txt +$CLI bundle plan -o json | nostamp >> out.plan_.json trace $CLI bundle deploy -q trace jq 'select(.method == "POST" and (.path | contains("/clusters/resize")))' "$OUT_REQUESTS" rm "$OUT_REQUESTS" @@ -65,8 +65,8 @@ title "Removing autoscale section should call resize API\n" update_file.py databricks.yml " autoscale: min_workers: 4 max_workers: 6" " num_workers: 3" -$CLI bundle plan >> out.plan_.$DATABRICKS_BUNDLE_ENGINE.txt -$CLI bundle plan -o json | nostamp >> out.plan_.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan >> out.plan_.txt +$CLI bundle plan -o json | nostamp >> out.plan_.json trace $CLI bundle deploy -q trace jq 'select(.method == "POST" and (.path | contains("/clusters/resize")))' "$OUT_REQUESTS" rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/resources/clusters/deploy/update-and-resize/out.plan_.direct.json b/acceptance/bundle/resources/clusters/deploy/update-and-resize/out.plan_.json similarity index 100% rename from acceptance/bundle/resources/clusters/deploy/update-and-resize/out.plan_.direct.json rename to acceptance/bundle/resources/clusters/deploy/update-and-resize/out.plan_.json diff --git a/acceptance/bundle/resources/clusters/deploy/update-and-resize/out.plan_.terraform.json b/acceptance/bundle/resources/clusters/deploy/update-and-resize/out.plan_.terraform.json deleted file mode 100644 index 9dccd78ae21..00000000000 --- a/acceptance/bundle/resources/clusters/deploy/update-and-resize/out.plan_.terraform.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.clusters.test_cluster": { - "action": "create" - } - } -} -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.clusters.test_cluster": { - "action": "update" - } - } -} -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.clusters.test_cluster": { - "action": "update" - } - } -} -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.clusters.test_cluster": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/clusters/deploy/update-and-resize/out.plan_.terraform.txt b/acceptance/bundle/resources/clusters/deploy/update-and-resize/out.plan_.terraform.txt deleted file mode 100644 index d51cd2abf07..00000000000 --- a/acceptance/bundle/resources/clusters/deploy/update-and-resize/out.plan_.terraform.txt +++ /dev/null @@ -1,12 +0,0 @@ -create clusters.test_cluster - -Plan: 1 to add, 0 to change, 0 to delete, 0 unchanged -update clusters.test_cluster - -Plan: 0 to add, 1 to change, 0 to delete, 0 unchanged -update clusters.test_cluster - -Plan: 0 to add, 1 to change, 0 to delete, 0 unchanged -update clusters.test_cluster - -Plan: 0 to add, 1 to change, 0 to delete, 0 unchanged diff --git a/acceptance/bundle/resources/clusters/deploy/update-and-resize/out.plan_.direct.txt b/acceptance/bundle/resources/clusters/deploy/update-and-resize/out.plan_.txt similarity index 100% rename from acceptance/bundle/resources/clusters/deploy/update-and-resize/out.plan_.direct.txt rename to acceptance/bundle/resources/clusters/deploy/update-and-resize/out.plan_.txt diff --git a/acceptance/bundle/resources/clusters/deploy/update-and-resize/out.test.toml b/acceptance/bundle/resources/clusters/deploy/update-and-resize/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/clusters/deploy/update-and-resize/out.test.toml +++ b/acceptance/bundle/resources/clusters/deploy/update-and-resize/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/clusters/deploy/update-and-resize/script b/acceptance/bundle/resources/clusters/deploy/update-and-resize/script index f4ca0459540..06d5ae378cc 100644 --- a/acceptance/bundle/resources/clusters/deploy/update-and-resize/script +++ b/acceptance/bundle/resources/clusters/deploy/update-and-resize/script @@ -9,8 +9,8 @@ trap cleanup EXIT # Deploy with -q throughout: the engines name this action differently (direct reports # resize, terraform update), so the per-resource line would diverge. The Resources: # summary agrees, so it is kept rather than using -qq. -$CLI bundle plan > out.plan_.$DATABRICKS_BUNDLE_ENGINE.txt -$CLI bundle plan -o json | nostamp > out.plan_.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan > out.plan_.txt +$CLI bundle plan -o json | nostamp > out.plan_.json trace $CLI bundle deploy -q title "Cluster should exist after bundle deployment:\n" @@ -20,8 +20,8 @@ $CLI clusters get "${CLUSTER_ID}" | jq '{cluster_name,num_workers}' title "Changing num_workers should call update API on stopped cluster\n" update_file.py databricks.yml "num_workers: 2" "num_workers: 3" -$CLI bundle plan >> out.plan_.$DATABRICKS_BUNDLE_ENGINE.txt -$CLI bundle plan -o json | nostamp >> out.plan_.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan >> out.plan_.txt +$CLI bundle plan -o json | nostamp >> out.plan_.json trace $CLI bundle deploy -q trace jq 'select(.method == "POST" and (.path | contains("/clusters/edit"))) | del(.body.aws_attributes, .body.driver_node_type_id, .body.data_security_mode, .body.enable_elastic_disk)' "$OUT_REQUESTS" rm "$OUT_REQUESTS" @@ -34,8 +34,8 @@ $CLI clusters start "${CLUSTER_ID}" title "Changing num_workers should call resize API on running cluster\n" update_file.py databricks.yml "num_workers: 3" "num_workers: 4" -$CLI bundle plan >> out.plan_.$DATABRICKS_BUNDLE_ENGINE.txt -$CLI bundle plan -o json | nostamp >> out.plan_.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan >> out.plan_.txt +$CLI bundle plan -o json | nostamp >> out.plan_.json trace $CLI bundle deploy -q trace jq 'select(.method == "POST" and (.path | contains("/clusters/resize")))' "$OUT_REQUESTS" rm "$OUT_REQUESTS" @@ -46,8 +46,8 @@ $CLI clusters get "${CLUSTER_ID}" | jq '{cluster_name,num_workers}' title "Changing num_workers and spark_conf should call update API\n" update_file.py databricks.yml "num_workers: 4" "num_workers: 5" update_file.py databricks.yml '"spark.executor.memory": "2g"' '"spark.executor.memory": "4g"' -$CLI bundle plan >> out.plan_.$DATABRICKS_BUNDLE_ENGINE.txt -$CLI bundle plan -o json | nostamp >> out.plan_.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan >> out.plan_.txt +$CLI bundle plan -o json | nostamp >> out.plan_.json trace $CLI bundle deploy -q trace jq 'select(.method == "POST" and (.path | contains("/clusters/edit"))) | del(.body.aws_attributes, .body.driver_node_type_id, .body.data_security_mode, .body.enable_elastic_disk)' "$OUT_REQUESTS" rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/resources/clusters/deploy/workload_type/out.test.toml b/acceptance/bundle/resources/clusters/deploy/workload_type/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/clusters/deploy/workload_type/out.test.toml +++ b/acceptance/bundle/resources/clusters/deploy/workload_type/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/clusters/lifecycle-started-terraform-error/databricks.yml.tmpl b/acceptance/bundle/resources/clusters/lifecycle-started-terraform-error/databricks.yml.tmpl deleted file mode 100644 index cd0a5360ab8..00000000000 --- a/acceptance/bundle/resources/clusters/lifecycle-started-terraform-error/databricks.yml.tmpl +++ /dev/null @@ -1,16 +0,0 @@ -bundle: - name: lifecycle-started-$UNIQUE_NAME - -workspace: - root_path: ~/.bundle/$UNIQUE_NAME - -resources: - clusters: - mycluster: - cluster_name: $UNIQUE_NAME - spark_version: 15.4.x-scala2.12 - node_type_id: $NODE_TYPE_ID - instance_pool_id: $TEST_INSTANCE_POOL_ID - num_workers: 1 - lifecycle: - started: true diff --git a/acceptance/bundle/resources/clusters/lifecycle-started-terraform-error/out.test.toml b/acceptance/bundle/resources/clusters/lifecycle-started-terraform-error/out.test.toml deleted file mode 100644 index 19131430a06..00000000000 --- a/acceptance/bundle/resources/clusters/lifecycle-started-terraform-error/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] -EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/clusters/lifecycle-started-terraform-error/output.txt b/acceptance/bundle/resources/clusters/lifecycle-started-terraform-error/output.txt deleted file mode 100644 index a7adb36a0b2..00000000000 --- a/acceptance/bundle/resources/clusters/lifecycle-started-terraform-error/output.txt +++ /dev/null @@ -1,16 +0,0 @@ - -=== bundle plan fails with lifecycle.started on terraform engine ->>> errcode [CLI] bundle plan -Error: lifecycle.started is only supported in direct deployment mode - in databricks.yml:16:18 - - -Exit code: 1 - -=== bundle deploy fails with lifecycle.started on terraform engine ->>> errcode [CLI] bundle deploy -Error: lifecycle.started is only supported in direct deployment mode - in databricks.yml:16:18 - - -Exit code: 1 diff --git a/acceptance/bundle/resources/clusters/lifecycle-started-terraform-error/script b/acceptance/bundle/resources/clusters/lifecycle-started-terraform-error/script deleted file mode 100644 index 4fb2038cd28..00000000000 --- a/acceptance/bundle/resources/clusters/lifecycle-started-terraform-error/script +++ /dev/null @@ -1,7 +0,0 @@ -envsubst < databricks.yml.tmpl > databricks.yml - -title "bundle plan fails with lifecycle.started on terraform engine" -trace errcode $CLI bundle plan - -title "bundle deploy fails with lifecycle.started on terraform engine" -trace errcode $CLI bundle deploy diff --git a/acceptance/bundle/resources/clusters/lifecycle-started-terraform-error/test.toml b/acceptance/bundle/resources/clusters/lifecycle-started-terraform-error/test.toml deleted file mode 100644 index a80ad730d07..00000000000 --- a/acceptance/bundle/resources/clusters/lifecycle-started-terraform-error/test.toml +++ /dev/null @@ -1,4 +0,0 @@ -Cloud = true -RecordRequests = false - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] diff --git a/acceptance/bundle/resources/clusters/lifecycle-started-toggle/out.test.toml b/acceptance/bundle/resources/clusters/lifecycle-started-toggle/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/clusters/lifecycle-started-toggle/out.test.toml +++ b/acceptance/bundle/resources/clusters/lifecycle-started-toggle/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/clusters/lifecycle-started-toggle/test.toml b/acceptance/bundle/resources/clusters/lifecycle-started-toggle/test.toml index 984a8114a36..a9e7431ea45 100644 --- a/acceptance/bundle/resources/clusters/lifecycle-started-toggle/test.toml +++ b/acceptance/bundle/resources/clusters/lifecycle-started-toggle/test.toml @@ -3,7 +3,6 @@ RecordRequests = true Ignore = [".databricks", "databricks.yml"] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] [[Repls]] Old = "[0-9]{4}-[0-9]{6}-[0-9a-z]{8}" diff --git a/acceptance/bundle/resources/clusters/lifecycle-started/out.test.toml b/acceptance/bundle/resources/clusters/lifecycle-started/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/clusters/lifecycle-started/out.test.toml +++ b/acceptance/bundle/resources/clusters/lifecycle-started/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/clusters/lifecycle-started/test.toml b/acceptance/bundle/resources/clusters/lifecycle-started/test.toml index 984a8114a36..a9e7431ea45 100644 --- a/acceptance/bundle/resources/clusters/lifecycle-started/test.toml +++ b/acceptance/bundle/resources/clusters/lifecycle-started/test.toml @@ -3,7 +3,6 @@ RecordRequests = true Ignore = [".databricks", "databricks.yml"] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] [[Repls]] Old = "[0-9]{4}-[0-9]{6}-[0-9a-z]{8}" diff --git a/acceptance/bundle/resources/clusters/readplan-lifecycle/out.test.toml b/acceptance/bundle/resources/clusters/readplan-lifecycle/out.test.toml index dd03baaabb6..f7fafbcc731 100644 --- a/acceptance/bundle/resources/clusters/readplan-lifecycle/out.test.toml +++ b/acceptance/bundle/resources/clusters/readplan-lifecycle/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resources/clusters/readplan-lifecycle/test.toml b/acceptance/bundle/resources/clusters/readplan-lifecycle/test.toml index 8fc50d962df..5bad0f70d3c 100644 --- a/acceptance/bundle/resources/clusters/readplan-lifecycle/test.toml +++ b/acceptance/bundle/resources/clusters/readplan-lifecycle/test.toml @@ -1,7 +1,6 @@ Cloud = false Ignore = [".databricks", "tmp.plan.json"] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.READPLAN = ["", "1"] [[Repls]] diff --git a/acceptance/bundle/resources/clusters/resize-terminated-fallback/out.test.toml b/acceptance/bundle/resources/clusters/resize-terminated-fallback/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/clusters/resize-terminated-fallback/out.test.toml +++ b/acceptance/bundle/resources/clusters/resize-terminated-fallback/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/clusters/resize-terminated-fallback/test.toml b/acceptance/bundle/resources/clusters/resize-terminated-fallback/test.toml index e9882212b04..7e11a4565e9 100644 --- a/acceptance/bundle/resources/clusters/resize-terminated-fallback/test.toml +++ b/acceptance/bundle/resources/clusters/resize-terminated-fallback/test.toml @@ -2,5 +2,3 @@ Cloud = true RecordRequests = true Ignore = [".databricks", "databricks.yml", "plan.json"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/clusters/run/spark_python_task/out.test.toml b/acceptance/bundle/resources/clusters/run/spark_python_task/out.test.toml index 52b4eef3488..542162e7f25 100644 --- a/acceptance/bundle/resources/clusters/run/spark_python_task/out.test.toml +++ b/acceptance/bundle/resources/clusters/run/spark_python_task/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudSlow = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/dashboards/change-embed-credentials/out.patch.requests.terraform.txt b/acceptance/bundle/resources/dashboards/change-embed-credentials/out.patch.requests.terraform.txt deleted file mode 100644 index 7697866cf48..00000000000 --- a/acceptance/bundle/resources/dashboards/change-embed-credentials/out.patch.requests.terraform.txt +++ /dev/null @@ -1,16 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.0/lakeview/dashboards/[DASHBOARD_ID]", - "body": { - "create_time": "[TIMESTAMP]", - "dashboard_id": "[DASHBOARD_ID]", - "display_name": "test dashboard", - "etag": "[ETAG]", - "lifecycle_state": "ACTIVE", - "parent_path": "/Users/[USERNAME]/.bundle/change-embed-credentials-[UNIQUE_NAME]/default/resources", - "path": "/Users/[USERNAME]/.bundle/change-embed-credentials-[UNIQUE_NAME]/default/resources/test dashboard.lvdash.json", - "serialized_dashboard": "{}\n", - "update_time": "[TIMESTAMP]", - "warehouse_id": "[TEST_DEFAULT_WAREHOUSE_ID]" - } -} diff --git a/acceptance/bundle/resources/dashboards/change-embed-credentials/out.patch.requests.direct.txt b/acceptance/bundle/resources/dashboards/change-embed-credentials/out.patch.requests.txt similarity index 100% rename from acceptance/bundle/resources/dashboards/change-embed-credentials/out.patch.requests.direct.txt rename to acceptance/bundle/resources/dashboards/change-embed-credentials/out.patch.requests.txt diff --git a/acceptance/bundle/resources/dashboards/change-embed-credentials/out.test.toml b/acceptance/bundle/resources/dashboards/change-embed-credentials/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/dashboards/change-embed-credentials/out.test.toml +++ b/acceptance/bundle/resources/dashboards/change-embed-credentials/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/dashboards/change-embed-credentials/script b/acceptance/bundle/resources/dashboards/change-embed-credentials/script index ec9e046bf3b..b22533e9348 100755 --- a/acceptance/bundle/resources/dashboards/change-embed-credentials/script +++ b/acceptance/bundle/resources/dashboards/change-embed-credentials/script @@ -35,7 +35,7 @@ deploy_dashboard cat "$OUT_REQUESTS" | \ jq 'select(.method == "PATCH")' | \ jq 'select( (.path | contains("/api/2.0/lakeview/dashboards")) or ((.path == "/api/2.0/workspace/mkdirs") and (.body.path | contains("/default/resources"))))' \ - > out.patch.requests.$DATABRICKS_BUNDLE_ENGINE.txt + > out.patch.requests.txt cat "$OUT_REQUESTS" | \ jq 'select(.method == "POST")' | \ diff --git a/acceptance/bundle/resources/dashboards/change-name/out.patch.requests.terraform.txt b/acceptance/bundle/resources/dashboards/change-name/out.patch.requests.terraform.txt deleted file mode 100644 index 1a3df84f499..00000000000 --- a/acceptance/bundle/resources/dashboards/change-name/out.patch.requests.terraform.txt +++ /dev/null @@ -1,16 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.0/lakeview/dashboards/[DASHBOARD_ID]", - "body": { - "create_time": "[TIMESTAMP]", - "dashboard_id": "[DASHBOARD_ID]", - "display_name": "dashboard2", - "etag": "[ETAG]", - "lifecycle_state": "ACTIVE", - "parent_path": "/Users/[USERNAME]/.bundle/change-name-[UNIQUE_NAME]/default/resources", - "path": "/Users/[USERNAME]/.bundle/change-name-[UNIQUE_NAME]/default/resources/dashboard1.lvdash.json", - "serialized_dashboard": "{}\n", - "update_time": "[TIMESTAMP]", - "warehouse_id": "[TEST_DEFAULT_WAREHOUSE_ID]" - } -} diff --git a/acceptance/bundle/resources/dashboards/change-name/out.patch.requests.direct.txt b/acceptance/bundle/resources/dashboards/change-name/out.patch.requests.txt similarity index 100% rename from acceptance/bundle/resources/dashboards/change-name/out.patch.requests.direct.txt rename to acceptance/bundle/resources/dashboards/change-name/out.patch.requests.txt diff --git a/acceptance/bundle/resources/dashboards/change-name/out.test.toml b/acceptance/bundle/resources/dashboards/change-name/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/dashboards/change-name/out.test.toml +++ b/acceptance/bundle/resources/dashboards/change-name/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/dashboards/change-name/script b/acceptance/bundle/resources/dashboards/change-name/script index ac6f1d260b7..60d9ccc0b43 100644 --- a/acceptance/bundle/resources/dashboards/change-name/script +++ b/acceptance/bundle/resources/dashboards/change-name/script @@ -36,7 +36,7 @@ deploy_dashboard cat "$OUT_REQUESTS" | \ jq 'select(.method == "PATCH")' | \ jq 'select( (.path | contains("/api/2.0/lakeview/dashboards")) or ((.path == "/api/2.0/workspace/mkdirs") and (.body.path | contains("/default/resources"))))' \ - > out.patch.requests.$DATABRICKS_BUNDLE_ENGINE.txt + > out.patch.requests.txt cat "$OUT_REQUESTS" | \ jq 'select(.method == "POST")' | \ diff --git a/acceptance/bundle/resources/dashboards/change-parent-path/out.test.toml b/acceptance/bundle/resources/dashboards/change-parent-path/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/dashboards/change-parent-path/out.test.toml +++ b/acceptance/bundle/resources/dashboards/change-parent-path/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.patch.requests.terraform.txt b/acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.patch.requests.terraform.txt deleted file mode 100644 index f53d8e447c5..00000000000 --- a/acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.patch.requests.terraform.txt +++ /dev/null @@ -1,15 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.0/lakeview/dashboards/[DASHBOARD_ID]", - "body": { - "create_time": "[TIMESTAMP]", - "dashboard_id": "[DASHBOARD_ID]", - "display_name": "test dashboard", - "lifecycle_state": "ACTIVE", - "parent_path": "/Users/[USERNAME]/.bundle/change-serialized-dashboard-[UNIQUE_NAME]/default/resources", - "path": "/Users/[USERNAME]/.bundle/change-serialized-dashboard-[UNIQUE_NAME]/default/resources/test dashboard.lvdash.json", - "serialized_dashboard": "{\"pages\":[{\"name\":\"name2\",\"displayName\":\"name2\",\"pageType\":\"PAGE_TYPE_CANVAS\"}]}\n", - "update_time": "[TIMESTAMP]", - "warehouse_id": "[TEST_DEFAULT_WAREHOUSE_ID]" - } -} diff --git a/acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.patch.requests.direct.txt b/acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.patch.requests.txt similarity index 100% rename from acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.patch.requests.direct.txt rename to acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.patch.requests.txt diff --git a/acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.state.direct.txt b/acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.state.txt similarity index 100% rename from acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.state.direct.txt rename to acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.state.txt diff --git a/acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.state_after_update.direct.txt b/acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.state_after_update.txt similarity index 100% rename from acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.state_after_update.direct.txt rename to acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.state_after_update.txt diff --git a/acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.test.toml b/acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.test.toml index b1bef937a27..7a62f726f25 100644 --- a/acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.test.toml +++ b/acceptance/bundle/resources/dashboards/change-serialized-dashboard/out.test.toml @@ -1,4 +1,3 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resources/dashboards/change-serialized-dashboard/script b/acceptance/bundle/resources/dashboards/change-serialized-dashboard/script index 015613ca361..e087da8515c 100755 --- a/acceptance/bundle/resources/dashboards/change-serialized-dashboard/script +++ b/acceptance/bundle/resources/dashboards/change-serialized-dashboard/script @@ -36,9 +36,7 @@ add_repl "$dashboard_id" DASHBOARD_ID # serialized_dashboard is stored in direct-engine state as a content hash, not the full JSON # (terraform stores it verbatim), so this check is direct-only. The full content still reached # the API (out.post.requests.txt) and stays in the plan's new_state. -if [ "$DATABRICKS_BUNDLE_ENGINE" = "direct" ]; then - print_state.py | gron.py | grep serialized_dashboard > out.state.direct.txt -fi +print_state.py | gron.py | grep serialized_dashboard > out.state.txt # No-op re-plan: the hash in state compares equal to the config, so the stored hash does not # produce a phantom serialized_dashboard update. @@ -49,9 +47,7 @@ export PAGE_NAME="name2" deploy_dashboard # The edit changes the content, so state holds the new hash (direct-only, as above). -if [ "$DATABRICKS_BUNDLE_ENGINE" = "direct" ]; then - print_state.py | gron.py | grep serialized_dashboard > out.state_after_update.direct.txt -fi +print_state.py | gron.py | grep serialized_dashboard > out.state_after_update.txt # Print API requests made to create parent_path or create / update the dashboard. # Terraform serialized OUTPUT_ONLY fields in the request body while direct does not. @@ -61,7 +57,7 @@ cat "$OUT_REQUESTS" | \ jq 'select(.method == "PATCH")' | \ jq 'select( (.path | contains("/api/2.0/lakeview/dashboards")) or ((.path == "/api/2.0/workspace/mkdirs") and (.body.path | contains("/default/resources"))))' | \ sed 's/\\r\\n/\\n/g' \ - > out.patch.requests.$DATABRICKS_BUNDLE_ENGINE.txt + > out.patch.requests.txt cat "$OUT_REQUESTS" | \ jq 'select(.method == "POST")' | \ diff --git a/acceptance/bundle/resources/dashboards/change-serialized-inline/out.plan.direct.json b/acceptance/bundle/resources/dashboards/change-serialized-inline/out.plan.json similarity index 100% rename from acceptance/bundle/resources/dashboards/change-serialized-inline/out.plan.direct.json rename to acceptance/bundle/resources/dashboards/change-serialized-inline/out.plan.json diff --git a/acceptance/bundle/resources/dashboards/change-serialized-inline/out.plan.terraform.json b/acceptance/bundle/resources/dashboards/change-serialized-inline/out.plan.terraform.json deleted file mode 100644 index 7795272689a..00000000000 --- a/acceptance/bundle/resources/dashboards/change-serialized-inline/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.dashboards.inline_dash": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/dashboards/change-serialized-inline/out.requests.terraform.txt b/acceptance/bundle/resources/dashboards/change-serialized-inline/out.requests.terraform.txt deleted file mode 100644 index 641cd24882e..00000000000 --- a/acceptance/bundle/resources/dashboards/change-serialized-inline/out.requests.terraform.txt +++ /dev/null @@ -1,23 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.0/lakeview/dashboards/[DASHBOARD_ID]", - "body": { - "create_time": "[TIMESTAMP]", - "dashboard_id": "[DASHBOARD_ID]", - "display_name": "Inline Dash", - "lifecycle_state": "ACTIVE", - "parent_path": "/Users/[USERNAME]/.bundle/change-serialized-inline-[UNIQUE_NAME]/default/resources", - "path": "/Users/[USERNAME]/.bundle/change-serialized-inline-[UNIQUE_NAME]/default/resources/Inline Dash.lvdash.json", - "serialized_dashboard": "{\"pages\":[{\"displayName\":\"Page One\",\"name\":\"page1\"}]}", - "update_time": "[TIMESTAMP]", - "warehouse_id": "[TEST_DEFAULT_WAREHOUSE_ID]" - } -} -{ - "method": "POST", - "path": "/api/2.0/lakeview/dashboards/[DASHBOARD_ID]/published", - "body": { - "embed_credentials": false, - "warehouse_id": "[TEST_DEFAULT_WAREHOUSE_ID]" - } -} diff --git a/acceptance/bundle/resources/dashboards/change-serialized-inline/out.requests.direct.txt b/acceptance/bundle/resources/dashboards/change-serialized-inline/out.requests.txt similarity index 100% rename from acceptance/bundle/resources/dashboards/change-serialized-inline/out.requests.direct.txt rename to acceptance/bundle/resources/dashboards/change-serialized-inline/out.requests.txt diff --git a/acceptance/bundle/resources/dashboards/change-serialized-inline/out.test.toml b/acceptance/bundle/resources/dashboards/change-serialized-inline/out.test.toml index bf4f0e7d3c6..f7fafbcc731 100644 --- a/acceptance/bundle/resources/dashboards/change-serialized-inline/out.test.toml +++ b/acceptance/bundle/resources/dashboards/change-serialized-inline/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resources/dashboards/change-serialized-inline/script b/acceptance/bundle/resources/dashboards/change-serialized-inline/script index 12a45b9420e..f16a2584031 100644 --- a/acceptance/bundle/resources/dashboards/change-serialized-inline/script +++ b/acceptance/bundle/resources/dashboards/change-serialized-inline/script @@ -24,11 +24,11 @@ update_file.py databricks.yml "Page 1" "Page One" trace $CLI bundle plan | contains.py "update" "!recreate" # Save raw plan (with DMS headers) to tmp file for deployment -trace $CLI bundle plan -o json > plan_raw.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json > plan_raw.json # Generate golden file by applying nostamp for comparison (discard output) -cat plan_raw.$DATABRICKS_BUNDLE_ENGINE.json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +cat plan_raw.json | nostamp > out.plan.json title "deploy the change\n" -$CLI bundle deploy $(readplanarg plan_raw.$DATABRICKS_BUNDLE_ENGINE.json) +$CLI bundle deploy $(readplanarg plan_raw.json) -print_requests.py //api/2.0/lakeview/dashboards > out.requests.$DATABRICKS_BUNDLE_ENGINE.txt +print_requests.py //api/2.0/lakeview/dashboards > out.requests.txt diff --git a/acceptance/bundle/resources/dashboards/change-serialized-inline/test.toml b/acceptance/bundle/resources/dashboards/change-serialized-inline/test.toml index d6cc7185a84..32329a6946f 100644 --- a/acceptance/bundle/resources/dashboards/change-serialized-inline/test.toml +++ b/acceptance/bundle/resources/dashboards/change-serialized-inline/test.toml @@ -6,7 +6,7 @@ Cloud = false Ignore = [ "databricks.yml", "plan_raw.terraform.json", - "plan_raw.direct.json", + "plan_raw.json", ] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resources/dashboards/dataset-catalog-schema/out.plan.direct.json b/acceptance/bundle/resources/dashboards/dataset-catalog-schema/out.plan.json similarity index 100% rename from acceptance/bundle/resources/dashboards/dataset-catalog-schema/out.plan.direct.json rename to acceptance/bundle/resources/dashboards/dataset-catalog-schema/out.plan.json diff --git a/acceptance/bundle/resources/dashboards/dataset-catalog-schema/out.plan.terraform.json b/acceptance/bundle/resources/dashboards/dataset-catalog-schema/out.plan.terraform.json deleted file mode 100644 index 4e469fa6771..00000000000 --- a/acceptance/bundle/resources/dashboards/dataset-catalog-schema/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.dashboards.dashboard1": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/resources/dashboards/dataset-catalog-schema/out.test.toml b/acceptance/bundle/resources/dashboards/dataset-catalog-schema/out.test.toml index 3035c7addb4..0f167effef1 100644 --- a/acceptance/bundle/resources/dashboards/dataset-catalog-schema/out.test.toml +++ b/acceptance/bundle/resources/dashboards/dataset-catalog-schema/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/dashboards/dataset-catalog-schema/script b/acceptance/bundle/resources/dashboards/dataset-catalog-schema/script index ac838ddf56a..05c28b54213 100755 --- a/acceptance/bundle/resources/dashboards/dataset-catalog-schema/script +++ b/acceptance/bundle/resources/dashboards/dataset-catalog-schema/script @@ -30,19 +30,17 @@ echo "$DASHBOARD" | jq '.serialized_dashboard | fromjson | .datasets[] | {catalo # Verify that there is no drift right after deploy. # Save raw plan (with DMS headers), then apply nostamp for golden file -trace $CLI bundle plan -o json > plan_raw.$DATABRICKS_BUNDLE_ENGINE.json -cat plan_raw.$DATABRICKS_BUNDLE_ENGINE.json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json > plan_raw.json +cat plan_raw.json | nostamp > out.plan.json # Modify the direct plan to replace "serialized_dashboard" with a fixture. # It is normalized on the backend so we cannot compare reliably across local and cloud. -if [ "$DATABRICKS_BUNDLE_ENGINE" = "direct" ]; then - jq '.plan["resources.dashboards.dashboard1"].remote_state.serialized_dashboard |= - if . then "[SERIALIZED_FIXTURE]" else . end' \ - out.plan.direct.json > out.plan.direct.json.tmp && mv out.plan.direct.json.tmp out.plan.direct.json - jq '.plan["resources.dashboards.dashboard1"].changes.serialized_dashboard |= - if . then {"action": .action, "old": "[SERIALIZED_FIXTURE_OLD]", "new": "[SERIALIZED_FIXTURE_NEW]"} else . end' \ - out.plan.direct.json > out.plan.direct.json.tmp && mv out.plan.direct.json.tmp out.plan.direct.json -fi +jq '.plan["resources.dashboards.dashboard1"].remote_state.serialized_dashboard |= + if . then "[SERIALIZED_FIXTURE]" else . end' \ + out.plan.json > out.plan.json.tmp && mv out.plan.json.tmp out.plan.json +jq '.plan["resources.dashboards.dashboard1"].changes.serialized_dashboard |= + if . then {"action": .action, "old": "[SERIALIZED_FIXTURE_OLD]", "new": "[SERIALIZED_FIXTURE_NEW]"} else . end' \ + out.plan.json > out.plan.json.tmp && mv out.plan.json.tmp out.plan.json # Print API requests made to create the dashboard. # This verifies that dataset_catalog and dataset_schema are passed to the API. diff --git a/acceptance/bundle/resources/dashboards/dataset-catalog-schema/test.toml b/acceptance/bundle/resources/dashboards/dataset-catalog-schema/test.toml index d86ff66a53d..f68c9b85944 100644 --- a/acceptance/bundle/resources/dashboards/dataset-catalog-schema/test.toml +++ b/acceptance/bundle/resources/dashboards/dataset-catalog-schema/test.toml @@ -1,8 +1,7 @@ Cloud = true RecordRequests = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] Ignore = [ "plan_raw.terraform.json", - "plan_raw.direct.json", + "plan_raw.json", ] diff --git a/acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/out.plan.direct.json b/acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/out.plan.json similarity index 100% rename from acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/out.plan.direct.json rename to acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/out.plan.json diff --git a/acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/out.plan.terraform.json b/acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/out.plan.terraform.json deleted file mode 100644 index 4c4e6636fa6..00000000000 --- a/acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.dashboards.dashboard1": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/out.test.toml b/acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/out.test.toml +++ b/acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/script b/acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/script index 78de1b2cc4c..dae7cb2f68d 100755 --- a/acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/script +++ b/acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/script @@ -26,8 +26,8 @@ trace $CLI lakeview trash $DASHBOARD_ID trace $CLI bundle plan # Save raw plan (with DMS headers), then apply nostamp for golden file -trace $CLI bundle plan -o json > plan_raw.$DATABRICKS_BUNDLE_ENGINE.json -cat plan_raw.$DATABRICKS_BUNDLE_ENGINE.json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json > plan_raw.json +cat plan_raw.json | nostamp > out.plan.json # Run destroy - should succeed even though dashboard is already trashed. # -qq drops the summary: terraform refreshes the trashed dashboard away and reports diff --git a/acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/test.toml b/acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/test.toml index 7694da9756d..b0940181e87 100644 --- a/acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/test.toml +++ b/acceptance/bundle/resources/dashboards/delete-trashed-out-of-band/test.toml @@ -5,5 +5,5 @@ RunsOnDbr = true Ignore = [ "databricks.yml", "plan_raw.terraform.json", - "plan_raw.direct.json", + "plan_raw.json", ] diff --git a/acceptance/bundle/resources/dashboards/destroy/out.test.toml b/acceptance/bundle/resources/dashboards/destroy/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/dashboards/destroy/out.test.toml +++ b/acceptance/bundle/resources/dashboards/destroy/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/dashboards/detect-change/out.patch.requests.terraform.txt b/acceptance/bundle/resources/dashboards/detect-change/out.patch.requests.terraform.txt deleted file mode 100644 index 65c491ab301..00000000000 --- a/acceptance/bundle/resources/dashboards/detect-change/out.patch.requests.terraform.txt +++ /dev/null @@ -1,23 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.0/lakeview/dashboards/[DASHBOARD_ID]", - "body": { - "serialized_dashboard": "{}", - "warehouse_id": "[TEST_DEFAULT_WAREHOUSE_ID]" - } -} -{ - "method": "PATCH", - "path": "/api/2.0/lakeview/dashboards/[DASHBOARD_ID]", - "body": { - "create_time": "[TIMESTAMP]", - "dashboard_id": "[DASHBOARD_ID]", - "display_name": "test-dashboard-[UNIQUE_NAME]", - "lifecycle_state": "ACTIVE", - "parent_path": "/Users/[USERNAME]/.bundle/[UNIQUE_NAME]/resources", - "path": "/Users/[USERNAME]/.bundle/[UNIQUE_NAME]/resources/test-dashboard-[UNIQUE_NAME].lvdash.json", - "serialized_dashboard": "{\n \"pages\": [\n {\n \"displayName\": \"New Page\",\n \"layout\": [\n {\n \"position\": {\n \"height\": 2,\n \"width\": 6,\n \"x\": 0,\n \"y\": 0\n },\n \"widget\": {\n \"name\": \"82eb9107\",\n \"textbox_spec\": \"# I'm a title\"\n }\n },\n {\n \"position\": {\n \"height\": 2,\n \"width\": 6,\n \"x\": 0,\n \"y\": 2\n },\n \"widget\": {\n \"name\": \"ffa6de4f\",\n \"textbox_spec\": \"Text\"\n }\n }\n ],\n \"name\": \"fdd21a3c\"\n }\n ]\n}\n", - "update_time": "[TIMESTAMP]", - "warehouse_id": "[TEST_DEFAULT_WAREHOUSE_ID]" - } -} diff --git a/acceptance/bundle/resources/dashboards/detect-change/out.patch.requests.direct.txt b/acceptance/bundle/resources/dashboards/detect-change/out.patch.requests.txt similarity index 100% rename from acceptance/bundle/resources/dashboards/detect-change/out.patch.requests.direct.txt rename to acceptance/bundle/resources/dashboards/detect-change/out.patch.requests.txt diff --git a/acceptance/bundle/resources/dashboards/detect-change/out.plan.direct.json b/acceptance/bundle/resources/dashboards/detect-change/out.plan.json similarity index 100% rename from acceptance/bundle/resources/dashboards/detect-change/out.plan.direct.json rename to acceptance/bundle/resources/dashboards/detect-change/out.plan.json diff --git a/acceptance/bundle/resources/dashboards/detect-change/out.plan.terraform.json b/acceptance/bundle/resources/dashboards/detect-change/out.plan.terraform.json deleted file mode 100644 index 8e81f0bf531..00000000000 --- a/acceptance/bundle/resources/dashboards/detect-change/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.dashboards.file_reference": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/dashboards/detect-change/out.test.toml b/acceptance/bundle/resources/dashboards/detect-change/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/dashboards/detect-change/out.test.toml +++ b/acceptance/bundle/resources/dashboards/detect-change/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/dashboards/detect-change/script b/acceptance/bundle/resources/dashboards/detect-change/script index 9407afafed0..cdc1d201a15 100644 --- a/acceptance/bundle/resources/dashboards/detect-change/script +++ b/acceptance/bundle/resources/dashboards/detect-change/script @@ -39,8 +39,8 @@ add_repl "$(echo "$UPDATE_RESP" | jq -r '.etag')" ETAG_2 title "Try to redeploy the bundle and confirm that the out of band modification is detected:" trace $CLI bundle plan # Save raw plan (with DMS headers), then apply nostamp for golden file -trace $CLI bundle plan -o json > plan_raw.$DATABRICKS_BUNDLE_ENGINE.json -cat plan_raw.$DATABRICKS_BUNDLE_ENGINE.json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json > plan_raw.json +cat plan_raw.json | nostamp > out.plan.json trace errcode $CLI bundle deploy title "Redeploy the bundle with the --force flag and confirm that the out of band modification is ignored:" @@ -52,7 +52,7 @@ trace errcode $CLI bundle deploy --force cat "$OUT_REQUESTS" | \ jq 'select(.method == "PATCH")' | \ jq 'select( (.path | contains("/api/2.0/lakeview/dashboards")) or ((.path == "/api/2.0/workspace/mkdirs") and (.body.path | contains("/default/resources"))))' \ - > out.patch.requests.$DATABRICKS_BUNDLE_ENGINE.txt + > out.patch.requests.txt # POST requests are the same across both modes cat "$OUT_REQUESTS" | \ diff --git a/acceptance/bundle/resources/dashboards/detect-change/test.toml b/acceptance/bundle/resources/dashboards/detect-change/test.toml index 83028566e5f..c11c2c34bfc 100644 --- a/acceptance/bundle/resources/dashboards/detect-change/test.toml +++ b/acceptance/bundle/resources/dashboards/detect-change/test.toml @@ -3,7 +3,7 @@ Cloud = true Ignore = [ "databricks.yml", "plan_raw.terraform.json", - "plan_raw.direct.json", + "plan_raw.json", ] # MSYS2 automatically converts absolute paths like /Users/$username/$UNIQUE_NAME to diff --git a/acceptance/bundle/resources/dashboards/generate_inplace/out.test.toml b/acceptance/bundle/resources/dashboards/generate_inplace/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/dashboards/generate_inplace/out.test.toml +++ b/acceptance/bundle/resources/dashboards/generate_inplace/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/dashboards/generate_inplace/test.toml b/acceptance/bundle/resources/dashboards/generate_inplace/test.toml index 96b263c004a..7d7ae48db25 100644 --- a/acceptance/bundle/resources/dashboards/generate_inplace/test.toml +++ b/acceptance/bundle/resources/dashboards/generate_inplace/test.toml @@ -1,5 +1,3 @@ Cloud = true RecordRequests = false RunsOnDbr = true - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/bundle/resources/dashboards/nested-folders/out.test.toml b/acceptance/bundle/resources/dashboards/nested-folders/out.test.toml index 0e852edd37c..31f264f361a 100644 --- a/acceptance/bundle/resources/dashboards/nested-folders/out.test.toml +++ b/acceptance/bundle/resources/dashboards/nested-folders/out.test.toml @@ -1,5 +1,4 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resources/dashboards/publish-failure-cleans-up-dashboard/out.deploy.terraform.txt b/acceptance/bundle/resources/dashboards/publish-failure-cleans-up-dashboard/out.deploy.terraform.txt deleted file mode 100644 index 8ba5e3511f3..00000000000 --- a/acceptance/bundle/resources/dashboards/publish-failure-cleans-up-dashboard/out.deploy.terraform.txt +++ /dev/null @@ -1,14 +0,0 @@ -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/publish-failure-cleans-up-dashboard/default/files... -Error: terraform apply: exit status 1 - -Error: cannot create dashboard: Warehouse doesnotexist does not exist - - with databricks_dashboard.dashboard1, - on bundle.tf.json line 21, in resource.databricks_dashboard.dashboard1: - 21: } - - - -Files: 7 uploaded, 0 deleted - -Exit code: 1 diff --git a/acceptance/bundle/resources/dashboards/publish-failure-cleans-up-dashboard/out.deploy.direct.txt b/acceptance/bundle/resources/dashboards/publish-failure-cleans-up-dashboard/out.deploy.txt similarity index 100% rename from acceptance/bundle/resources/dashboards/publish-failure-cleans-up-dashboard/out.deploy.direct.txt rename to acceptance/bundle/resources/dashboards/publish-failure-cleans-up-dashboard/out.deploy.txt diff --git a/acceptance/bundle/resources/dashboards/publish-failure-cleans-up-dashboard/out.test.toml b/acceptance/bundle/resources/dashboards/publish-failure-cleans-up-dashboard/out.test.toml index bf4f0e7d3c6..f7fafbcc731 100644 --- a/acceptance/bundle/resources/dashboards/publish-failure-cleans-up-dashboard/out.test.toml +++ b/acceptance/bundle/resources/dashboards/publish-failure-cleans-up-dashboard/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resources/dashboards/publish-failure-cleans-up-dashboard/script b/acceptance/bundle/resources/dashboards/publish-failure-cleans-up-dashboard/script index f6c01d0f654..e9ad93d3079 100755 --- a/acceptance/bundle/resources/dashboards/publish-failure-cleans-up-dashboard/script +++ b/acceptance/bundle/resources/dashboards/publish-failure-cleans-up-dashboard/script @@ -3,7 +3,7 @@ envsubst < databricks.yml.tmpl > databricks.yml # Deploy the dashboard. The dashboard will be created but publish will fail because the warehouse does not exist. $CLI bundle plan -o json > tmp.plan.json -errcode $CLI bundle deploy $(readplanarg tmp.plan.json) &> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt +errcode $CLI bundle deploy $(readplanarg tmp.plan.json) &> out.deploy.txt trace $CLI bundle summary diff --git a/acceptance/bundle/resources/dashboards/publish-failure-stale-content/out.test.toml b/acceptance/bundle/resources/dashboards/publish-failure-stale-content/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/dashboards/publish-failure-stale-content/out.test.toml +++ b/acceptance/bundle/resources/dashboards/publish-failure-stale-content/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/dashboards/publish-failure-stale-content/test.toml b/acceptance/bundle/resources/dashboards/publish-failure-stale-content/test.toml index 744ce820ba1..43cd3c397dc 100644 --- a/acceptance/bundle/resources/dashboards/publish-failure-stale-content/test.toml +++ b/acceptance/bundle/resources/dashboards/publish-failure-stale-content/test.toml @@ -7,7 +7,6 @@ Ignore = [ "databricks.yml", ] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] [[Repls]] Old = '\?[ow]=\d+' diff --git a/acceptance/bundle/resources/dashboards/republish-after-draft-update/out.test.toml b/acceptance/bundle/resources/dashboards/republish-after-draft-update/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/dashboards/republish-after-draft-update/out.test.toml +++ b/acceptance/bundle/resources/dashboards/republish-after-draft-update/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/dashboards/republish-after-draft-update/test.toml b/acceptance/bundle/resources/dashboards/republish-after-draft-update/test.toml index e211ad7215e..7e3bec0f862 100644 --- a/acceptance/bundle/resources/dashboards/republish-after-draft-update/test.toml +++ b/acceptance/bundle/resources/dashboards/republish-after-draft-update/test.toml @@ -10,7 +10,6 @@ RecordRequests = false # own read observe stale values and mask the change, so opt out of it here. Env.INJECT_STALE_ON_DIRECT = "0" -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] [[Repls]] Old = '2\d\d\d-\d\d-\d\d(T| )\d\d:\d\d:\d\d(\.\d+(Z|\+\d\d:\d\d)?)?Z' diff --git a/acceptance/bundle/resources/dashboards/serialized-inline/out.test.toml b/acceptance/bundle/resources/dashboards/serialized-inline/out.test.toml index b1bef937a27..7a62f726f25 100644 --- a/acceptance/bundle/resources/dashboards/serialized-inline/out.test.toml +++ b/acceptance/bundle/resources/dashboards/serialized-inline/out.test.toml @@ -1,4 +1,3 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resources/dashboards/simple/out.plan.direct.json b/acceptance/bundle/resources/dashboards/simple/out.plan.json similarity index 100% rename from acceptance/bundle/resources/dashboards/simple/out.plan.direct.json rename to acceptance/bundle/resources/dashboards/simple/out.plan.json diff --git a/acceptance/bundle/resources/dashboards/simple/out.plan.terraform.json b/acceptance/bundle/resources/dashboards/simple/out.plan.terraform.json deleted file mode 100644 index 4e469fa6771..00000000000 --- a/acceptance/bundle/resources/dashboards/simple/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.dashboards.dashboard1": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/resources/dashboards/simple/out.test.toml b/acceptance/bundle/resources/dashboards/simple/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/dashboards/simple/out.test.toml +++ b/acceptance/bundle/resources/dashboards/simple/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/dashboards/simple/script b/acceptance/bundle/resources/dashboards/simple/script index 8f7d1a2e8ec..c17660bedf7 100644 --- a/acceptance/bundle/resources/dashboards/simple/script +++ b/acceptance/bundle/resources/dashboards/simple/script @@ -25,5 +25,5 @@ echo "$DASHBOARD" | jq '{lifecycle_state, parent_path, path, serialized_dashboar # Verify that there is no drift right after deploy. We use |= to update the serialized_dashboard field in place to account # for formatting that the cloud server applies to the serialized_dashboard field. # Save raw plan (with DMS headers), then apply nostamp for golden file -trace $CLI bundle plan -o json > plan_raw.$DATABRICKS_BUNDLE_ENGINE.json -cat plan_raw.$DATABRICKS_BUNDLE_ENGINE.json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json > plan_raw.json +cat plan_raw.json | nostamp > out.plan.json diff --git a/acceptance/bundle/resources/dashboards/simple/test.toml b/acceptance/bundle/resources/dashboards/simple/test.toml index 7694da9756d..b0940181e87 100644 --- a/acceptance/bundle/resources/dashboards/simple/test.toml +++ b/acceptance/bundle/resources/dashboards/simple/test.toml @@ -5,5 +5,5 @@ RunsOnDbr = true Ignore = [ "databricks.yml", "plan_raw.terraform.json", - "plan_raw.direct.json", + "plan_raw.json", ] diff --git a/acceptance/bundle/resources/dashboards/simple_outside_bundle_root/out.test.toml b/acceptance/bundle/resources/dashboards/simple_outside_bundle_root/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/dashboards/simple_outside_bundle_root/out.test.toml +++ b/acceptance/bundle/resources/dashboards/simple_outside_bundle_root/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/dashboards/simple_syncroot/out.test.toml b/acceptance/bundle/resources/dashboards/simple_syncroot/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/dashboards/simple_syncroot/out.test.toml +++ b/acceptance/bundle/resources/dashboards/simple_syncroot/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/dashboards/test.toml b/acceptance/bundle/resources/dashboards/test.toml index 8cb107c206f..b551c84cca9 100644 --- a/acceptance/bundle/resources/dashboards/test.toml +++ b/acceptance/bundle/resources/dashboards/test.toml @@ -14,5 +14,3 @@ Env.INJECT_STALE_ON_DIRECT = "1" # which flaked these read-after-deploy checks. 20 attempts x 1000ms gives a ~20s window. Env.RETRY_MAX_ATTEMPTS = "20" Env.RETRY_INTERVAL_MS = "1000" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.get_published.terraform.txt b/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.get_published.terraform.txt deleted file mode 100644 index 82fdc2992ea..00000000000 --- a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.get_published.terraform.txt +++ /dev/null @@ -1,5 +0,0 @@ - ->>> errcode [CLI] lakeview get-published [DASHBOARD1_ID] -Error: Unable to find published dashboard [[DASHBOARD1_ID]] - -Exit code: 1 diff --git a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.get_published.direct.txt b/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.get_published.txt similarity index 100% rename from acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.get_published.direct.txt rename to acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.get_published.txt diff --git a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan.direct.json b/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan.json similarity index 100% rename from acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan.direct.json rename to acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan.json diff --git a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan.terraform.json b/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan.terraform.json deleted file mode 100644 index 4e469fa6771..00000000000 --- a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.dashboards.dashboard1": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan.direct.txt b/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan.txt similarity index 100% rename from acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan.direct.txt rename to acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan.txt diff --git a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan_initial.direct.json b/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan_initial.json similarity index 100% rename from acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan_initial.direct.json rename to acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan_initial.json diff --git a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan_initial.terraform.json b/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan_initial.terraform.json deleted file mode 100644 index 4c4e6636fa6..00000000000 --- a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan_initial.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.dashboards.dashboard1": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.state.direct.json b/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.state.json similarity index 100% rename from acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.state.direct.json rename to acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.state.json diff --git a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.state.terraform.json b/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.state.terraform.json deleted file mode 100644 index 2852fcd2935..00000000000 --- a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.state.terraform.json +++ /dev/null @@ -1,2 +0,0 @@ - "parent_path": "/Users/[USERNAME]/.bundle/unpublish-out-of-band-[UNIQUE_NAME]/default/resources", - "path": "/Users/[USERNAME]/.bundle/unpublish-out-of-band-[UNIQUE_NAME]/default/resources/test bundle-deploy-dashboard [UNIQUE_NAME].lvdash.json", diff --git a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.test.toml b/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.test.toml +++ b/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/script b/acceptance/bundle/resources/dashboards/unpublish-out-of-band/script index 4b816672c5b..f41bee7b917 100644 --- a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/script +++ b/acceptance/bundle/resources/dashboards/unpublish-out-of-band/script @@ -7,15 +7,15 @@ cleanup() { trap cleanup EXIT # Save raw plan (with DMS headers), then apply nostamp for golden file -trace $CLI bundle plan -o json > plan_raw_initial.$DATABRICKS_BUNDLE_ENGINE.json -cat plan_raw_initial.$DATABRICKS_BUNDLE_ENGINE.json | nostamp > out.plan_initial.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json > plan_raw_initial.json +cat plan_raw_initial.json | nostamp > out.plan_initial.json # Deploy the dashboard trace $CLI bundle deploy -qq DASHBOARD_ID=$(read_id.py dashboard1) add_repl "$(retry $CLI lakeview get $DASHBOARD_ID | jq -r '.etag')" ETAG -trace print_state.py | grep publish > out.state.$DATABRICKS_BUNDLE_ENGINE.json +trace print_state.py | grep publish > out.state.json # Verify dashboard was deployed and is published trace $CLI lakeview get-published $DASHBOARD_ID | jq '{embed_credentials}' @@ -25,13 +25,13 @@ trace $CLI lakeview unpublish $DASHBOARD_ID # Terraform: shows "skip" because it only reads draft state, not published state # Direct: shows "update" because Published field changes from false to true -trace $CLI bundle plan > out.plan.$DATABRICKS_BUNDLE_ENGINE.txt +trace $CLI bundle plan > out.plan.txt # Save raw plan (with DMS headers), then apply nostamp for golden file -$CLI bundle plan -o json > plan_raw.$DATABRICKS_BUNDLE_ENGINE.json -cat plan_raw.$DATABRICKS_BUNDLE_ENGINE.json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json -json_in_json_normalize.py out.plan.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json > plan_raw.json +cat plan_raw.json | nostamp > out.plan.json +json_in_json_normalize.py out.plan.json trace $CLI bundle deploy -qq -trace errcode $CLI lakeview get-published $DASHBOARD_ID &> out.get_published.$DATABRICKS_BUNDLE_ENGINE.txt +trace errcode $CLI lakeview get-published $DASHBOARD_ID &> out.get_published.txt diff --git a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/test.toml b/acceptance/bundle/resources/dashboards/unpublish-out-of-band/test.toml index cd67bcda24f..e40d8ecb122 100644 --- a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/test.toml +++ b/acceptance/bundle/resources/dashboards/unpublish-out-of-band/test.toml @@ -5,7 +5,7 @@ RunsOnDbr = true Ignore = [ "databricks.yml", "plan_raw_initial.terraform.json", - "plan_raw_initial.direct.json", + "plan_raw_initial.json", "plan_raw.terraform.json", - "plan_raw.direct.json", + "plan_raw.json", ] diff --git a/acceptance/bundle/resources/database_catalogs/basic/out.test.toml b/acceptance/bundle/resources/database_catalogs/basic/out.test.toml index f6514a8cd9d..7ce718742f8 100644 --- a/acceptance/bundle/resources/database_catalogs/basic/out.test.toml +++ b/acceptance/bundle/resources/database_catalogs/basic/out.test.toml @@ -2,5 +2,4 @@ Cloud = true CloudSlow = true RunsOnDbr = true CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/database_catalogs/recreate/out.test.toml b/acceptance/bundle/resources/database_catalogs/recreate/out.test.toml index bfeb0bd3aea..f7840b7a1df 100644 --- a/acceptance/bundle/resources/database_catalogs/recreate/out.test.toml +++ b/acceptance/bundle/resources/database_catalogs/recreate/out.test.toml @@ -1,4 +1,3 @@ Cloud = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/database_catalogs/recreate/test.toml b/acceptance/bundle/resources/database_catalogs/recreate/test.toml index 731a0a503cb..3fc85054798 100644 --- a/acceptance/bundle/resources/database_catalogs/recreate/test.toml +++ b/acceptance/bundle/resources/database_catalogs/recreate/test.toml @@ -1,7 +1,6 @@ # The Database API has no UpdateDatabaseCatalog endpoint (PATCH returns 501), so # any field change must go through delete + create. The direct engine handles # this; the terraform path would need an upstream provider fix and is excluded. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] RecordRequests = true Ignore = [ diff --git a/acceptance/bundle/resources/database_instances/recreate/out.test.toml b/acceptance/bundle/resources/database_instances/recreate/out.test.toml index bfeb0bd3aea..f7840b7a1df 100644 --- a/acceptance/bundle/resources/database_instances/recreate/out.test.toml +++ b/acceptance/bundle/resources/database_instances/recreate/out.test.toml @@ -1,4 +1,3 @@ Cloud = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/database_instances/recreate/test.toml b/acceptance/bundle/resources/database_instances/recreate/test.toml index d928c965cec..e4f979e5aa0 100644 --- a/acceptance/bundle/resources/database_instances/recreate/test.toml +++ b/acceptance/bundle/resources/database_instances/recreate/test.toml @@ -2,7 +2,6 @@ # endpoint, so changing it must go through delete + create. Only the direct # engine handles this correctly; the terraform path needs an upstream provider # fix (marking name immutable in the spec) and is excluded here. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] RecordRequests = true Ignore = [ diff --git a/acceptance/bundle/resources/database_instances/single-instance/out.test.toml b/acceptance/bundle/resources/database_instances/single-instance/out.test.toml index 2dd1ac4d727..7c3dd4f02ef 100644 --- a/acceptance/bundle/resources/database_instances/single-instance/out.test.toml +++ b/acceptance/bundle/resources/database_instances/single-instance/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudSlow = true CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/experiments/basic/out.plan.terraform.txt b/acceptance/bundle/resources/experiments/basic/out.plan.terraform.txt deleted file mode 100644 index 986d3cf68cd..00000000000 --- a/acceptance/bundle/resources/experiments/basic/out.plan.terraform.txt +++ /dev/null @@ -1,3 +0,0 @@ -update experiments.my_experiment - -Plan: 0 to add, 1 to change, 0 to delete, 0 unchanged diff --git a/acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan.terraform.txt b/acceptance/bundle/resources/experiments/basic/out.plan.txt similarity index 100% rename from acceptance/bundle/resources/dashboards/unpublish-out-of-band/out.plan.terraform.txt rename to acceptance/bundle/resources/experiments/basic/out.plan.txt diff --git a/acceptance/bundle/resources/experiments/basic/out.test.toml b/acceptance/bundle/resources/experiments/basic/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/experiments/basic/out.test.toml +++ b/acceptance/bundle/resources/experiments/basic/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/experiments/basic/script b/acceptance/bundle/resources/experiments/basic/script index 3513bf00cbd..cdb522e9184 100755 --- a/acceptance/bundle/resources/experiments/basic/script +++ b/acceptance/bundle/resources/experiments/basic/script @@ -31,7 +31,7 @@ trace $CLI experiments get-experiment $experiment_id | jq '.experiment | {name, title "adding a new tag should be a no-op" trace envsubst < templates/two_tag.tmpl > databricks.yml -trace $CLI bundle plan > out.plan.$DATABRICKS_BUNDLE_ENGINE.txt +trace $CLI bundle plan > out.plan.txt trace $CLI bundle deploy -qq experiment_id=$($CLI bundle summary --output json | jq -r '.resources.experiments.my_experiment.id') trace $CLI experiments get-experiment $experiment_id | jq '.experiment | {name, artifact_location, tags}' diff --git a/acceptance/bundle/resources/external_locations/comment_cleared/out.test.toml b/acceptance/bundle/resources/external_locations/comment_cleared/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/external_locations/comment_cleared/out.test.toml +++ b/acceptance/bundle/resources/external_locations/comment_cleared/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/external_locations/comment_cleared/test.toml b/acceptance/bundle/resources/external_locations/comment_cleared/test.toml index 31bed342069..7975e770d90 100644 --- a/acceptance/bundle/resources/external_locations/comment_cleared/test.toml +++ b/acceptance/bundle/resources/external_locations/comment_cleared/test.toml @@ -5,7 +5,6 @@ Cloud = false RecordRequests = true # UpdateExternalLocation payload construction is direct-engine-specific. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ ".databricks", diff --git a/acceptance/bundle/resources/external_locations/out.test.toml b/acceptance/bundle/resources/external_locations/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/external_locations/out.test.toml +++ b/acceptance/bundle/resources/external_locations/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/external_locations/test.toml b/acceptance/bundle/resources/external_locations/test.toml index 3f634495af0..7c22912f15e 100644 --- a/acceptance/bundle/resources/external_locations/test.toml +++ b/acceptance/bundle/resources/external_locations/test.toml @@ -7,5 +7,3 @@ Ignore = [ ".databricks", "databricks.yml", ] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/genie_spaces/change-serialized-space/out.test.toml b/acceptance/bundle/resources/genie_spaces/change-serialized-space/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/genie_spaces/change-serialized-space/out.test.toml +++ b/acceptance/bundle/resources/genie_spaces/change-serialized-space/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/genie_spaces/delete_warning/out.test.toml b/acceptance/bundle/resources/genie_spaces/delete_warning/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/genie_spaces/delete_warning/out.test.toml +++ b/acceptance/bundle/resources/genie_spaces/delete_warning/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/genie_spaces/inline/out.test.toml b/acceptance/bundle/resources/genie_spaces/inline/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/genie_spaces/inline/out.test.toml +++ b/acceptance/bundle/resources/genie_spaces/inline/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/genie_spaces/parent_path_update/out.test.toml b/acceptance/bundle/resources/genie_spaces/parent_path_update/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/genie_spaces/parent_path_update/out.test.toml +++ b/acceptance/bundle/resources/genie_spaces/parent_path_update/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/genie_spaces/recreate_when_gone/out.test.toml b/acceptance/bundle/resources/genie_spaces/recreate_when_gone/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/genie_spaces/recreate_when_gone/out.test.toml +++ b/acceptance/bundle/resources/genie_spaces/recreate_when_gone/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/genie_spaces/serialized_space/out.test.toml b/acceptance/bundle/resources/genie_spaces/serialized_space/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/genie_spaces/serialized_space/out.test.toml +++ b/acceptance/bundle/resources/genie_spaces/serialized_space/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/genie_spaces/simple/out.test.toml b/acceptance/bundle/resources/genie_spaces/simple/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/genie_spaces/simple/out.test.toml +++ b/acceptance/bundle/resources/genie_spaces/simple/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/genie_spaces/test.toml b/acceptance/bundle/resources/genie_spaces/test.toml index 76d0e77bfd5..855e2b1ce44 100644 --- a/acceptance/bundle/resources/genie_spaces/test.toml +++ b/acceptance/bundle/resources/genie_spaces/test.toml @@ -1,5 +1,4 @@ # Genie spaces are only deployed via the direct deployment engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # Genie space lifecycle tests also run against a real workspace. They use a # minimal serialized_space ({"version": 1}) the backend accepts, plus a real diff --git a/acceptance/bundle/resources/genie_spaces/version_migration/out.test.toml b/acceptance/bundle/resources/genie_spaces/version_migration/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/genie_spaces/version_migration/out.test.toml +++ b/acceptance/bundle/resources/genie_spaces/version_migration/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/grants/catalogs/out.deploy1.requests.direct.json b/acceptance/bundle/resources/grants/catalogs/out.deploy1.requests.json similarity index 100% rename from acceptance/bundle/resources/grants/catalogs/out.deploy1.requests.direct.json rename to acceptance/bundle/resources/grants/catalogs/out.deploy1.requests.json diff --git a/acceptance/bundle/resources/grants/catalogs/out.deploy2.requests.direct.json b/acceptance/bundle/resources/grants/catalogs/out.deploy2.requests.json similarity index 100% rename from acceptance/bundle/resources/grants/catalogs/out.deploy2.requests.direct.json rename to acceptance/bundle/resources/grants/catalogs/out.deploy2.requests.json diff --git a/acceptance/bundle/resource_deps/job_tasks/out.drymigrate.direct.txt b/acceptance/bundle/resources/grants/catalogs/out.destroy.requests.json similarity index 100% rename from acceptance/bundle/resource_deps/job_tasks/out.drymigrate.direct.txt rename to acceptance/bundle/resources/grants/catalogs/out.destroy.requests.json diff --git a/acceptance/bundle/resources/grants/catalogs/out.plan1.direct.json b/acceptance/bundle/resources/grants/catalogs/out.plan1.json similarity index 100% rename from acceptance/bundle/resources/grants/catalogs/out.plan1.direct.json rename to acceptance/bundle/resources/grants/catalogs/out.plan1.json diff --git a/acceptance/bundle/resources/grants/catalogs/out.plan2.direct.json b/acceptance/bundle/resources/grants/catalogs/out.plan2.json similarity index 100% rename from acceptance/bundle/resources/grants/catalogs/out.plan2.direct.json rename to acceptance/bundle/resources/grants/catalogs/out.plan2.json diff --git a/acceptance/bundle/resources/grants/catalogs/out.test.toml b/acceptance/bundle/resources/grants/catalogs/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/grants/catalogs/out.test.toml +++ b/acceptance/bundle/resources/grants/catalogs/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/grants/catalogs/output.txt b/acceptance/bundle/resources/grants/catalogs/output.txt index e8996f5f7d2..ec16b45f8f6 100644 --- a/acceptance/bundle/resources/grants/catalogs/output.txt +++ b/acceptance/bundle/resources/grants/catalogs/output.txt @@ -13,7 +13,7 @@ Plan: 2 to add, 0 to change, 0 to delete, 0 unchanged Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/catalog-grants-[UNIQUE_NAME]/default/files... Created catalogs.grants_catalog Created catalogs.grants_catalog.grants -Files: 5 uploaded, 0 deleted +Files: 4 uploaded, 0 deleted Resources: 2 created, 0 changed, 0 deleted, 0 unchanged >>> print_requests.py //permissions diff --git a/acceptance/bundle/resources/grants/catalogs/script b/acceptance/bundle/resources/grants/catalogs/script index 5dd1ab465fb..712644486c2 100755 --- a/acceptance/bundle/resources/grants/catalogs/script +++ b/acceptance/bundle/resources/grants/catalogs/script @@ -1,10 +1,10 @@ envsubst < databricks.yml.tmpl > databricks.yml trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | normalize_uc_payload.py created_at created_by updated_at updated_by metastore_id browse_only effective_predictive_optimization_flag enable_predictive_optimization isolation_mode securable_type > out.plan1.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | normalize_uc_payload.py created_at created_by updated_at updated_by metastore_id browse_only effective_predictive_optimization_flag enable_predictive_optimization isolation_mode securable_type > out.plan1.json trace print_requests.py --get //permissions trace $CLI bundle deploy -trace print_requests.py //permissions > out.deploy1.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //permissions > out.deploy1.requests.json trace $CLI bundle plan @@ -13,12 +13,12 @@ trace $CLI grants get catalog catalog_grants_$UNIQUE_NAME | jq --sort-keys update_file.py databricks.yml CREATE_SCHEMA USE_SCHEMA -trace $CLI bundle plan -o json | nostamp | normalize_uc_payload.py created_at created_by updated_at updated_by metastore_id browse_only effective_predictive_optimization_flag enable_predictive_optimization isolation_mode securable_type > out.plan2.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | normalize_uc_payload.py created_at created_by updated_at updated_by metastore_id browse_only effective_predictive_optimization_flag enable_predictive_optimization isolation_mode securable_type > out.plan2.json trace print_requests.py --get //permissions trace $CLI bundle deploy -trace print_requests.py //permissions > out.deploy2.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //permissions > out.deploy2.requests.json trace $CLI grants get catalog catalog_grants_$UNIQUE_NAME | jq --sort-keys trace $CLI bundle destroy --auto-approve -trace print_requests.py //permissions > out.destroy.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //permissions > out.destroy.requests.json diff --git a/acceptance/bundle/resources/grants/catalogs/test.toml b/acceptance/bundle/resources/grants/catalogs/test.toml deleted file mode 100644 index 9609e1af299..00000000000 --- a/acceptance/bundle/resources/grants/catalogs/test.toml +++ /dev/null @@ -1 +0,0 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/grants/mcp_services/out.deploy1.requests.direct.json b/acceptance/bundle/resources/grants/mcp_services/out.deploy1.requests.json similarity index 100% rename from acceptance/bundle/resources/grants/mcp_services/out.deploy1.requests.direct.json rename to acceptance/bundle/resources/grants/mcp_services/out.deploy1.requests.json diff --git a/acceptance/bundle/resource_deps/resources_var/out.drymigrate.direct.txt b/acceptance/bundle/resources/grants/mcp_services/out.destroy.requests.json similarity index 100% rename from acceptance/bundle/resource_deps/resources_var/out.drymigrate.direct.txt rename to acceptance/bundle/resources/grants/mcp_services/out.destroy.requests.json diff --git a/acceptance/bundle/resources/grants/mcp_services/out.plan1.direct.json b/acceptance/bundle/resources/grants/mcp_services/out.plan1.json similarity index 100% rename from acceptance/bundle/resources/grants/mcp_services/out.plan1.direct.json rename to acceptance/bundle/resources/grants/mcp_services/out.plan1.json diff --git a/acceptance/bundle/resources/grants/mcp_services/out.test.toml b/acceptance/bundle/resources/grants/mcp_services/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/grants/mcp_services/out.test.toml +++ b/acceptance/bundle/resources/grants/mcp_services/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/grants/mcp_services/script b/acceptance/bundle/resources/grants/mcp_services/script index e52883f3522..eafb6a07c58 100644 --- a/acceptance/bundle/resources/grants/mcp_services/script +++ b/acceptance/bundle/resources/grants/mcp_services/script @@ -1,12 +1,12 @@ envsubst < databricks.yml.tmpl > databricks.yml -trace $CLI bundle plan -o json | jq 'del(.features)' > out.plan1.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | jq 'del(.features)' > out.plan1.json trace print_requests.py --get //permissions trace $CLI bundle deploy -trace print_requests.py //permissions > out.deploy1.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //permissions > out.deploy1.requests.json # Assert the end result: the grant is applied on the MCP service securable. trace $CLI grants get mcp_service main.myschema.myservice | jq --sort-keys trace $CLI bundle destroy --auto-approve -trace print_requests.py //permissions > out.destroy.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //permissions > out.destroy.requests.json diff --git a/acceptance/bundle/resources/grants/mcp_services/test.toml b/acceptance/bundle/resources/grants/mcp_services/test.toml index 439e55ce050..9434ef4a40a 100644 --- a/acceptance/bundle/resources/grants/mcp_services/test.toml +++ b/acceptance/bundle/resources/grants/mcp_services/test.toml @@ -2,4 +2,3 @@ # there is no direct-vs-terraform request divergence to reconcile on cloud; # compare the recorded requests locally instead. Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/grants/model_provider_services/out.deploy1.requests.direct.json b/acceptance/bundle/resources/grants/model_provider_services/out.deploy1.requests.json similarity index 100% rename from acceptance/bundle/resources/grants/model_provider_services/out.deploy1.requests.direct.json rename to acceptance/bundle/resources/grants/model_provider_services/out.deploy1.requests.json diff --git a/acceptance/bundle/resources/grants/catalogs/out.destroy.requests.direct.json b/acceptance/bundle/resources/grants/model_provider_services/out.destroy.requests.json similarity index 100% rename from acceptance/bundle/resources/grants/catalogs/out.destroy.requests.direct.json rename to acceptance/bundle/resources/grants/model_provider_services/out.destroy.requests.json diff --git a/acceptance/bundle/resources/grants/model_provider_services/out.plan1.direct.json b/acceptance/bundle/resources/grants/model_provider_services/out.plan1.json similarity index 100% rename from acceptance/bundle/resources/grants/model_provider_services/out.plan1.direct.json rename to acceptance/bundle/resources/grants/model_provider_services/out.plan1.json diff --git a/acceptance/bundle/resources/grants/model_provider_services/out.test.toml b/acceptance/bundle/resources/grants/model_provider_services/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/grants/model_provider_services/out.test.toml +++ b/acceptance/bundle/resources/grants/model_provider_services/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/grants/model_provider_services/script b/acceptance/bundle/resources/grants/model_provider_services/script index 3cfa9e1c6cb..7c9f39f37db 100644 --- a/acceptance/bundle/resources/grants/model_provider_services/script +++ b/acceptance/bundle/resources/grants/model_provider_services/script @@ -1,12 +1,12 @@ envsubst < databricks.yml.tmpl > databricks.yml -trace $CLI bundle plan -o json | jq 'del(.features)' > out.plan1.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | jq 'del(.features)' > out.plan1.json trace print_requests.py --get //permissions trace $CLI bundle deploy -trace print_requests.py //permissions > out.deploy1.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //permissions > out.deploy1.requests.json # Assert the end result: the grant is applied on the model provider service securable. trace $CLI grants get model_provider_service main.myschema.myservice | jq --sort-keys trace $CLI bundle destroy --auto-approve -trace print_requests.py //permissions > out.destroy.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //permissions > out.destroy.requests.json diff --git a/acceptance/bundle/resources/grants/model_provider_services/test.toml b/acceptance/bundle/resources/grants/model_provider_services/test.toml index 439e55ce050..9434ef4a40a 100644 --- a/acceptance/bundle/resources/grants/model_provider_services/test.toml +++ b/acceptance/bundle/resources/grants/model_provider_services/test.toml @@ -2,4 +2,3 @@ # there is no direct-vs-terraform request divergence to reconcile on cloud; # compare the recorded requests locally instead. Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/grants/model_services/out.deploy1.requests.direct.json b/acceptance/bundle/resources/grants/model_services/out.deploy1.requests.json similarity index 100% rename from acceptance/bundle/resources/grants/model_services/out.deploy1.requests.direct.json rename to acceptance/bundle/resources/grants/model_services/out.deploy1.requests.json diff --git a/acceptance/bundle/resources/grants/mcp_services/out.destroy.requests.direct.json b/acceptance/bundle/resources/grants/model_services/out.destroy.requests.json similarity index 100% rename from acceptance/bundle/resources/grants/mcp_services/out.destroy.requests.direct.json rename to acceptance/bundle/resources/grants/model_services/out.destroy.requests.json diff --git a/acceptance/bundle/resources/grants/model_services/out.plan1.direct.json b/acceptance/bundle/resources/grants/model_services/out.plan1.json similarity index 100% rename from acceptance/bundle/resources/grants/model_services/out.plan1.direct.json rename to acceptance/bundle/resources/grants/model_services/out.plan1.json diff --git a/acceptance/bundle/resources/grants/model_services/out.test.toml b/acceptance/bundle/resources/grants/model_services/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/grants/model_services/out.test.toml +++ b/acceptance/bundle/resources/grants/model_services/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/grants/model_services/script b/acceptance/bundle/resources/grants/model_services/script index 01e2e1a56f1..60f6d70750c 100644 --- a/acceptance/bundle/resources/grants/model_services/script +++ b/acceptance/bundle/resources/grants/model_services/script @@ -1,12 +1,12 @@ envsubst < databricks.yml.tmpl > databricks.yml -trace $CLI bundle plan -o json | jq 'del(.features)' > out.plan1.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | jq 'del(.features)' > out.plan1.json trace print_requests.py --get //permissions trace $CLI bundle deploy -trace print_requests.py //permissions > out.deploy1.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //permissions > out.deploy1.requests.json # Assert the end result: the grant is applied on the model service securable. trace $CLI grants get model_service main.myschema.myservice | jq --sort-keys trace $CLI bundle destroy --auto-approve -trace print_requests.py //permissions > out.destroy.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //permissions > out.destroy.requests.json diff --git a/acceptance/bundle/resources/grants/model_services/test.toml b/acceptance/bundle/resources/grants/model_services/test.toml index 439e55ce050..9434ef4a40a 100644 --- a/acceptance/bundle/resources/grants/model_services/test.toml +++ b/acceptance/bundle/resources/grants/model_services/test.toml @@ -2,4 +2,3 @@ # there is no direct-vs-terraform request divergence to reconcile on cloud; # compare the recorded requests locally instead. Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/grants/registered_models/out.deploy1.requests.direct.json b/acceptance/bundle/resources/grants/registered_models/out.deploy1.requests.json similarity index 100% rename from acceptance/bundle/resources/grants/registered_models/out.deploy1.requests.direct.json rename to acceptance/bundle/resources/grants/registered_models/out.deploy1.requests.json diff --git a/acceptance/bundle/resources/grants/registered_models/out.deploy1.requests.terraform.json b/acceptance/bundle/resources/grants/registered_models/out.deploy1.requests.terraform.json deleted file mode 100644 index 81ca56fd5da..00000000000 --- a/acceptance/bundle/resources/grants/registered_models/out.deploy1.requests.terraform.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.1/unity-catalog/permissions/function/main.myschema_[UNIQUE_NAME].mymodel", - "body": { - "changes": [ - { - "add": [ - "APPLY_TAG" - ], - "principal": "deco-test-user@databricks.com" - } - ] - } -} diff --git a/acceptance/bundle/resources/grants/model_provider_services/out.destroy.requests.direct.json b/acceptance/bundle/resources/grants/registered_models/out.destroy.requests.json similarity index 100% rename from acceptance/bundle/resources/grants/model_provider_services/out.destroy.requests.direct.json rename to acceptance/bundle/resources/grants/registered_models/out.destroy.requests.json diff --git a/acceptance/bundle/resources/grants/registered_models/out.destroy.requests.terraform.json b/acceptance/bundle/resources/grants/registered_models/out.destroy.requests.terraform.json deleted file mode 100644 index a7b7aa0014e..00000000000 --- a/acceptance/bundle/resources/grants/registered_models/out.destroy.requests.terraform.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.1/unity-catalog/permissions/function/main.myschema_[UNIQUE_NAME].mymodel", - "body": { - "changes": [ - { - "principal": "deco-test-user@databricks.com", - "remove": [ - "APPLY_TAG" - ] - } - ] - } -} diff --git a/acceptance/bundle/resources/grants/registered_models/out.plan1.direct.json b/acceptance/bundle/resources/grants/registered_models/out.plan1.json similarity index 100% rename from acceptance/bundle/resources/grants/registered_models/out.plan1.direct.json rename to acceptance/bundle/resources/grants/registered_models/out.plan1.json diff --git a/acceptance/bundle/resources/grants/registered_models/out.plan1.terraform.json b/acceptance/bundle/resources/grants/registered_models/out.plan1.terraform.json deleted file mode 100644 index fc1627b9ed3..00000000000 --- a/acceptance/bundle/resources/grants/registered_models/out.plan1.terraform.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.registered_models.my_registered_model": { - "action": "create" - }, - "resources.registered_models.my_registered_model.grants": { - "action": "create" - }, - "resources.schemas.my_schema": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/grants/registered_models/out.test.toml b/acceptance/bundle/resources/grants/registered_models/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/grants/registered_models/out.test.toml +++ b/acceptance/bundle/resources/grants/registered_models/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/grants/registered_models/script b/acceptance/bundle/resources/grants/registered_models/script index 88cc72a1017..f47f85565de 100644 --- a/acceptance/bundle/resources/grants/registered_models/script +++ b/acceptance/bundle/resources/grants/registered_models/script @@ -1,12 +1,12 @@ envsubst < databricks.yml.tmpl > databricks.yml -trace $CLI bundle plan -o json | nostamp > out.plan1.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan1.json trace print_requests.py --get //permissions trace $CLI bundle deploy -trace print_requests.py //permissions > out.deploy1.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //permissions > out.deploy1.requests.json # Since we're sending different requests between terraform and direct, assert that the end result is the same: trace $CLI grants get function main.myschema_$UNIQUE_NAME.mymodel | jq --sort-keys trace $CLI bundle destroy --auto-approve -trace print_requests.py //permissions > out.destroy.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //permissions > out.destroy.requests.json diff --git a/acceptance/bundle/resources/grants/schemas/all_privileges/out.requests.terraform.txt b/acceptance/bundle/resources/grants/schemas/all_privileges/out.requests.terraform.txt deleted file mode 100644 index 5fc2fe369b7..00000000000 --- a/acceptance/bundle/resources/grants/schemas/all_privileges/out.requests.terraform.txt +++ /dev/null @@ -1,26 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.1/unity-catalog/permissions/schema/main.schema_dup_grants_[UNIQUE_NAME]" -} -{ - "method": "PATCH", - "path": "/api/2.1/unity-catalog/permissions/schema/main.schema_dup_grants_[UNIQUE_NAME]", - "body": { - "changes": [ - { - "add": [ - "ALL_PRIVILEGES" - ], - "principal": "deco-test-user@databricks.com" - } - ] - } -} -{ - "method": "GET", - "path": "/api/2.1/unity-catalog/permissions/schema/main.schema_dup_grants_[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.1/unity-catalog/permissions/schema/main.schema_dup_grants_[UNIQUE_NAME]" -} diff --git a/acceptance/bundle/resources/grants/schemas/all_privileges/out.requests.direct.txt b/acceptance/bundle/resources/grants/schemas/all_privileges/out.requests.txt similarity index 100% rename from acceptance/bundle/resources/grants/schemas/all_privileges/out.requests.direct.txt rename to acceptance/bundle/resources/grants/schemas/all_privileges/out.requests.txt diff --git a/acceptance/bundle/resources/grants/schemas/all_privileges/out.test.toml b/acceptance/bundle/resources/grants/schemas/all_privileges/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/grants/schemas/all_privileges/out.test.toml +++ b/acceptance/bundle/resources/grants/schemas/all_privileges/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/grants/schemas/all_privileges/script b/acceptance/bundle/resources/grants/schemas/all_privileges/script index 23e484a8b24..2c75f89b237 100644 --- a/acceptance/bundle/resources/grants/schemas/all_privileges/script +++ b/acceptance/bundle/resources/grants/schemas/all_privileges/script @@ -9,4 +9,4 @@ trap cleanup EXIT # The direct engine puts ALL_PRIVILEGES in both the Add and Remove lists in the PATCH request, # which the backend rejects with "Duplicate privileges to add and delete". $CLI bundle deploy -print_requests.py --get //permissions --keep > out.requests.$DATABRICKS_BUNDLE_ENGINE.txt +print_requests.py --get //permissions --keep > out.requests.txt diff --git a/acceptance/bundle/resources/grants/schemas/all_privileges_coexist/out.plan.terraform.txt b/acceptance/bundle/resources/grants/schemas/all_privileges_coexist/out.plan.terraform.txt deleted file mode 100644 index 8c7f94dfa63..00000000000 --- a/acceptance/bundle/resources/grants/schemas/all_privileges_coexist/out.plan.terraform.txt +++ /dev/null @@ -1,5 +0,0 @@ - ->>> [CLI] bundle plan -update schemas.grants_schema.grants - -Plan: 0 to add, 1 to change, 0 to delete, 1 unchanged diff --git a/acceptance/bundle/resources/grants/schemas/all_privileges_coexist/out.plan.direct.txt b/acceptance/bundle/resources/grants/schemas/all_privileges_coexist/out.plan.txt similarity index 100% rename from acceptance/bundle/resources/grants/schemas/all_privileges_coexist/out.plan.direct.txt rename to acceptance/bundle/resources/grants/schemas/all_privileges_coexist/out.plan.txt diff --git a/acceptance/bundle/resources/grants/schemas/all_privileges_coexist/out.test.toml b/acceptance/bundle/resources/grants/schemas/all_privileges_coexist/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/grants/schemas/all_privileges_coexist/out.test.toml +++ b/acceptance/bundle/resources/grants/schemas/all_privileges_coexist/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/grants/schemas/all_privileges_coexist/script b/acceptance/bundle/resources/grants/schemas/all_privileges_coexist/script index 4e6e6eab932..58ff16f7f46 100644 --- a/acceptance/bundle/resources/grants/schemas/all_privileges_coexist/script +++ b/acceptance/bundle/resources/grants/schemas/all_privileges_coexist/script @@ -19,7 +19,7 @@ trace $CLI grants update schema "$SCHEMA_FULL_NAME" --json @update.resolved.json # The first plan differs between engines: the direct engine treats ALL_PRIVILEGES # as implying every concrete privilege, so it reports no drift (issue #6030), # while terraform revokes the extra privilege to match the config exactly. -trace $CLI bundle plan > out.plan.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 +trace $CLI bundle plan > out.plan.txt 2>&1 # After deploying, both engines converge: the follow-up plan reports no changes. # The deploy summary itself still diverges here (terraform revokes the extra diff --git a/acceptance/bundle/resources/grants/schemas/all_privileges_manage/out.test.toml b/acceptance/bundle/resources/grants/schemas/all_privileges_manage/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/grants/schemas/all_privileges_manage/out.test.toml +++ b/acceptance/bundle/resources/grants/schemas/all_privileges_manage/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/grants/schemas/change_privilege/out.deploy1.requests.direct.json b/acceptance/bundle/resources/grants/schemas/change_privilege/out.deploy1.requests.json similarity index 100% rename from acceptance/bundle/resources/grants/schemas/change_privilege/out.deploy1.requests.direct.json rename to acceptance/bundle/resources/grants/schemas/change_privilege/out.deploy1.requests.json diff --git a/acceptance/bundle/resources/grants/schemas/change_privilege/out.deploy1.requests.terraform.json b/acceptance/bundle/resources/grants/schemas/change_privilege/out.deploy1.requests.terraform.json deleted file mode 100644 index 8df50a099a6..00000000000 --- a/acceptance/bundle/resources/grants/schemas/change_privilege/out.deploy1.requests.terraform.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.1/unity-catalog/permissions/schema/main.schema_grants_[UNIQUE_NAME]", - "body": { - "changes": [ - { - "add": [ - "CREATE_TABLE", - "USE_SCHEMA" - ], - "principal": "deco-test-user@databricks.com" - } - ] - } -} diff --git a/acceptance/bundle/resources/grants/schemas/change_privilege/out.deploy2.requests.direct.json b/acceptance/bundle/resources/grants/schemas/change_privilege/out.deploy2.requests.json similarity index 100% rename from acceptance/bundle/resources/grants/schemas/change_privilege/out.deploy2.requests.direct.json rename to acceptance/bundle/resources/grants/schemas/change_privilege/out.deploy2.requests.json diff --git a/acceptance/bundle/resources/grants/schemas/change_privilege/out.deploy2.requests.terraform.json b/acceptance/bundle/resources/grants/schemas/change_privilege/out.deploy2.requests.terraform.json deleted file mode 100644 index ed621fada48..00000000000 --- a/acceptance/bundle/resources/grants/schemas/change_privilege/out.deploy2.requests.terraform.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.1/unity-catalog/permissions/schema/main.schema_grants_[UNIQUE_NAME]", - "body": { - "changes": [ - { - "add": [ - "APPLY_TAG" - ], - "principal": "deco-test-user@databricks.com", - "remove": [ - "USE_SCHEMA" - ] - } - ] - } -} diff --git a/acceptance/bundle/resources/grants/model_services/out.destroy.requests.direct.json b/acceptance/bundle/resources/grants/schemas/change_privilege/out.destroy.requests.json similarity index 100% rename from acceptance/bundle/resources/grants/model_services/out.destroy.requests.direct.json rename to acceptance/bundle/resources/grants/schemas/change_privilege/out.destroy.requests.json diff --git a/acceptance/bundle/resources/grants/schemas/change_privilege/out.destroy.requests.terraform.json b/acceptance/bundle/resources/grants/schemas/change_privilege/out.destroy.requests.terraform.json deleted file mode 100644 index 4c2f8a1b01d..00000000000 --- a/acceptance/bundle/resources/grants/schemas/change_privilege/out.destroy.requests.terraform.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.1/unity-catalog/permissions/schema/main.schema_grants_[UNIQUE_NAME]", - "body": { - "changes": [ - { - "principal": "deco-test-user@databricks.com", - "remove": [ - "CREATE_TABLE", - "APPLY_TAG" - ] - } - ] - } -} diff --git a/acceptance/bundle/resources/grants/schemas/change_privilege/out.plan1.direct.json b/acceptance/bundle/resources/grants/schemas/change_privilege/out.plan1.json similarity index 100% rename from acceptance/bundle/resources/grants/schemas/change_privilege/out.plan1.direct.json rename to acceptance/bundle/resources/grants/schemas/change_privilege/out.plan1.json diff --git a/acceptance/bundle/resources/grants/schemas/change_privilege/out.plan1.terraform.json b/acceptance/bundle/resources/grants/schemas/change_privilege/out.plan1.terraform.json deleted file mode 100644 index 08938d3b63f..00000000000 --- a/acceptance/bundle/resources/grants/schemas/change_privilege/out.plan1.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.schemas.grants_schema": { - "action": "create" - }, - "resources.schemas.grants_schema.grants": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/grants/schemas/change_privilege/out.plan2.direct.json b/acceptance/bundle/resources/grants/schemas/change_privilege/out.plan2.json similarity index 100% rename from acceptance/bundle/resources/grants/schemas/change_privilege/out.plan2.direct.json rename to acceptance/bundle/resources/grants/schemas/change_privilege/out.plan2.json diff --git a/acceptance/bundle/resources/grants/schemas/change_privilege/out.plan2.terraform.json b/acceptance/bundle/resources/grants/schemas/change_privilege/out.plan2.terraform.json deleted file mode 100644 index f110cfe4a81..00000000000 --- a/acceptance/bundle/resources/grants/schemas/change_privilege/out.plan2.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.schemas.grants_schema": { - "action": "skip" - }, - "resources.schemas.grants_schema.grants": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/grants/schemas/change_privilege/out.test.toml b/acceptance/bundle/resources/grants/schemas/change_privilege/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/grants/schemas/change_privilege/out.test.toml +++ b/acceptance/bundle/resources/grants/schemas/change_privilege/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/grants/schemas/change_privilege/script b/acceptance/bundle/resources/grants/schemas/change_privilege/script index d79c9559a79..dfdd127c75e 100644 --- a/acceptance/bundle/resources/grants/schemas/change_privilege/script +++ b/acceptance/bundle/resources/grants/schemas/change_privilege/script @@ -1,10 +1,10 @@ envsubst < databricks.yml.tmpl > databricks.yml trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp > out.plan1.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan1.json trace print_requests.py --get //permissions trace $CLI bundle deploy -trace print_requests.py //permissions > out.deploy1.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //permissions > out.deploy1.requests.json trace $CLI bundle plan @@ -13,12 +13,12 @@ trace $CLI grants get schema main.schema_grants_$UNIQUE_NAME | jq --sort-keys update_file.py databricks.yml USE_SCHEMA APPLY_TAG -trace $CLI bundle plan -o json | nostamp | normalize_uc_payload.py effective_predictive_optimization_flag enable_predictive_optimization metastore_id schema_id updated_at updated_by > out.plan2.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | normalize_uc_payload.py effective_predictive_optimization_flag enable_predictive_optimization metastore_id schema_id updated_at updated_by > out.plan2.json trace print_requests.py --get //permissions trace $CLI bundle deploy -trace print_requests.py //permissions > out.deploy2.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //permissions > out.deploy2.requests.json trace $CLI grants get schema main.schema_grants_$UNIQUE_NAME | jq --sort-keys trace $CLI bundle destroy --auto-approve -trace print_requests.py //permissions > out.destroy.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //permissions > out.destroy.requests.json diff --git a/acceptance/bundle/resources/grants/schemas/duplicate_principals/out.plan.direct.json b/acceptance/bundle/resources/grants/schemas/duplicate_principals/out.plan.json similarity index 100% rename from acceptance/bundle/resources/grants/schemas/duplicate_principals/out.plan.direct.json rename to acceptance/bundle/resources/grants/schemas/duplicate_principals/out.plan.json diff --git a/acceptance/bundle/resources/grants/schemas/duplicate_principals/out.plan.terraform.json b/acceptance/bundle/resources/grants/schemas/duplicate_principals/out.plan.terraform.json deleted file mode 100644 index bcc57df961e..00000000000 --- a/acceptance/bundle/resources/grants/schemas/duplicate_principals/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.schemas.apps_schema": { - "action": "skip" - }, - "resources.schemas.apps_schema.grants": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/resources/grants/schemas/duplicate_principals/out.requests.terraform.txt b/acceptance/bundle/resources/grants/schemas/duplicate_principals/out.requests.terraform.txt deleted file mode 100644 index fdb92f6f3d5..00000000000 --- a/acceptance/bundle/resources/grants/schemas/duplicate_principals/out.requests.terraform.txt +++ /dev/null @@ -1,26 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.1/unity-catalog/permissions/schema/main.schema_dup_grants_[UNIQUE_NAME]" -} -{ - "method": "PATCH", - "path": "/api/2.1/unity-catalog/permissions/schema/main.schema_dup_grants_[UNIQUE_NAME]", - "body": { - "changes": [ - { - "add": [ - "CREATE_TABLE" - ], - "principal": "deco-test-user@databricks.com" - } - ] - } -} -{ - "method": "GET", - "path": "/api/2.1/unity-catalog/permissions/schema/main.schema_dup_grants_[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.1/unity-catalog/permissions/schema/main.schema_dup_grants_[UNIQUE_NAME]" -} diff --git a/acceptance/bundle/resources/grants/schemas/duplicate_principals/out.requests.direct.txt b/acceptance/bundle/resources/grants/schemas/duplicate_principals/out.requests.txt similarity index 100% rename from acceptance/bundle/resources/grants/schemas/duplicate_principals/out.requests.direct.txt rename to acceptance/bundle/resources/grants/schemas/duplicate_principals/out.requests.txt diff --git a/acceptance/bundle/resources/grants/schemas/duplicate_principals/out.test.toml b/acceptance/bundle/resources/grants/schemas/duplicate_principals/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/grants/schemas/duplicate_principals/out.test.toml +++ b/acceptance/bundle/resources/grants/schemas/duplicate_principals/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/grants/schemas/duplicate_principals/script b/acceptance/bundle/resources/grants/schemas/duplicate_principals/script index cac858c1e68..df7108ec558 100644 --- a/acceptance/bundle/resources/grants/schemas/duplicate_principals/script +++ b/acceptance/bundle/resources/grants/schemas/duplicate_principals/script @@ -8,7 +8,7 @@ trap cleanup EXIT # Same principal listed twice with the same privilege. trace $CLI bundle deploy -print_requests.py --get //permissions --keep > out.requests.$DATABRICKS_BUNDLE_ENGINE.txt +print_requests.py --get //permissions --keep > out.requests.txt # effective_predictive_optimization_flag is inherited from the metastore and backend-controlled; drop it so the test does not depend on metastore settings. # updated_at/updated_by reflect UC's post-create system write that populates managed defaults, so on managed-defaults clouds they show a system principal rather than the creator; drop them. -trace $CLI bundle plan -o json | nostamp | normalize_uc_payload.py effective_predictive_optimization_flag updated_at updated_by > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | normalize_uc_payload.py effective_predictive_optimization_flag updated_at updated_by > out.plan.json diff --git a/acceptance/bundle/resources/grants/schemas/duplicate_privileges/out.requests.terraform.txt b/acceptance/bundle/resources/grants/schemas/duplicate_privileges/out.requests.terraform.txt deleted file mode 100644 index fdb92f6f3d5..00000000000 --- a/acceptance/bundle/resources/grants/schemas/duplicate_privileges/out.requests.terraform.txt +++ /dev/null @@ -1,26 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.1/unity-catalog/permissions/schema/main.schema_dup_grants_[UNIQUE_NAME]" -} -{ - "method": "PATCH", - "path": "/api/2.1/unity-catalog/permissions/schema/main.schema_dup_grants_[UNIQUE_NAME]", - "body": { - "changes": [ - { - "add": [ - "CREATE_TABLE" - ], - "principal": "deco-test-user@databricks.com" - } - ] - } -} -{ - "method": "GET", - "path": "/api/2.1/unity-catalog/permissions/schema/main.schema_dup_grants_[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.1/unity-catalog/permissions/schema/main.schema_dup_grants_[UNIQUE_NAME]" -} diff --git a/acceptance/bundle/resources/grants/schemas/duplicate_privileges/out.requests.direct.txt b/acceptance/bundle/resources/grants/schemas/duplicate_privileges/out.requests.txt similarity index 100% rename from acceptance/bundle/resources/grants/schemas/duplicate_privileges/out.requests.direct.txt rename to acceptance/bundle/resources/grants/schemas/duplicate_privileges/out.requests.txt diff --git a/acceptance/bundle/resources/grants/schemas/duplicate_privileges/out.test.toml b/acceptance/bundle/resources/grants/schemas/duplicate_privileges/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/grants/schemas/duplicate_privileges/out.test.toml +++ b/acceptance/bundle/resources/grants/schemas/duplicate_privileges/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/grants/schemas/duplicate_privileges/script b/acceptance/bundle/resources/grants/schemas/duplicate_privileges/script index 4180fa13154..e8b3ea6f6df 100644 --- a/acceptance/bundle/resources/grants/schemas/duplicate_privileges/script +++ b/acceptance/bundle/resources/grants/schemas/duplicate_privileges/script @@ -8,5 +8,5 @@ trap cleanup EXIT # Same privilege listed twice for the same principal in a single entry. trace $CLI bundle deploy -print_requests.py --get //permissions --keep > out.requests.$DATABRICKS_BUNDLE_ENGINE.txt +print_requests.py --get //permissions --keep > out.requests.txt trace $CLI bundle plan > out.plan.txt 2>&1 diff --git a/acceptance/bundle/resources/grants/schemas/empty_array/out.test.toml b/acceptance/bundle/resources/grants/schemas/empty_array/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/grants/schemas/empty_array/out.test.toml +++ b/acceptance/bundle/resources/grants/schemas/empty_array/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/grants/schemas/manage_out_of_band/out.test.toml b/acceptance/bundle/resources/grants/schemas/manage_out_of_band/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/grants/schemas/manage_out_of_band/out.test.toml +++ b/acceptance/bundle/resources/grants/schemas/manage_out_of_band/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.embed.terraform.txt b/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.embed.terraform.txt deleted file mode 100644 index c5b4eb68634..00000000000 --- a/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.embed.terraform.txt +++ /dev/null @@ -1 +0,0 @@ -json = null; diff --git a/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.embed.direct.txt b/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.embed.txt similarity index 100% rename from acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.embed.direct.txt rename to acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.embed.txt diff --git a/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.plan.direct.json b/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.plan.json similarity index 100% rename from acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.plan.direct.json rename to acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.plan.json diff --git a/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.plan.terraform.json b/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.plan.terraform.json deleted file mode 100644 index f110cfe4a81..00000000000 --- a/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.schemas.grants_schema": { - "action": "skip" - }, - "resources.schemas.grants_schema.grants": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.plan2.direct.json b/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.plan2.json similarity index 100% rename from acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.plan2.direct.json rename to acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.plan2.json diff --git a/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.plan2.terraform.json b/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.plan2.terraform.json deleted file mode 100644 index fb331bc85e9..00000000000 --- a/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.plan2.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.schemas.grants_schema": { - "action": "skip" - }, - "resources.schemas.grants_schema.grants": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.test.toml b/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.test.toml +++ b/acceptance/bundle/resources/grants/schemas/out_of_band_principal/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/grants/schemas/out_of_band_principal/script b/acceptance/bundle/resources/grants/schemas/out_of_band_principal/script index 4ee1e5c2dbf..27424de2bdc 100644 --- a/acceptance/bundle/resources/grants/schemas/out_of_band_principal/script +++ b/acceptance/bundle/resources/grants/schemas/out_of_band_principal/script @@ -12,13 +12,13 @@ trap cleanup EXIT trace $CLI bundle deploy trace $CLI grants update schema "$SCHEMA_FULL_NAME" --json @update.json > /dev/null $CLI grants get schema "$SCHEMA_FULL_NAME" | gron.py --noindex | sort | contains.py "$CURRENT_USER_NAME" 'deco-test-user@databricks.com' > /dev/null -trace $CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan.json # remote_state.__embed__ order is non-deterministic; extract and sort separately into per-engine file -jq '.plan["resources.schemas.grants_schema.grants"].remote_state.__embed__' out.plan.$DATABRICKS_BUNDLE_ENGINE.json | gron.py --noindex | sort_lines.py --repl > out.embed.$DATABRICKS_BUNDLE_ENGINE.txt +jq '.plan["resources.schemas.grants_schema.grants"].remote_state.__embed__' out.plan.json | gron.py --noindex | sort_lines.py --repl > out.embed.txt tmp=$(mktemp) # __embed__ is extracted above; drop it so its non-deterministic order does not churn this golden. # effective_predictive_optimization_flag is inherited from the metastore and backend-controlled; drop it so the test does not depend on metastore settings. # updated_at/updated_by reflect UC's post-create system write that populates managed defaults, so on managed-defaults clouds they show a system principal rather than the creator; drop them. -jq 'del(.plan["resources.schemas.grants_schema.grants"].remote_state.__embed__)' out.plan.$DATABRICKS_BUNDLE_ENGINE.json | normalize_uc_payload.py effective_predictive_optimization_flag updated_at updated_by > "$tmp" && mv "$tmp" out.plan.$DATABRICKS_BUNDLE_ENGINE.json +jq 'del(.plan["resources.schemas.grants_schema.grants"].remote_state.__embed__)' out.plan.json | normalize_uc_payload.py effective_predictive_optimization_flag updated_at updated_by > "$tmp" && mv "$tmp" out.plan.json trace $CLI bundle deploy -trace $CLI bundle plan -o json | nostamp | normalize_uc_payload.py effective_predictive_optimization_flag updated_at updated_by > out.plan2.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | normalize_uc_payload.py effective_predictive_optimization_flag updated_at updated_by > out.plan2.json diff --git a/acceptance/bundle/resources/grants/schemas/remove_all/out.test.toml b/acceptance/bundle/resources/grants/schemas/remove_all/out.test.toml index 9b8ddfcd2bd..f68b4a89c36 100644 --- a/acceptance/bundle/resources/grants/schemas/remove_all/out.test.toml +++ b/acceptance/bundle/resources/grants/schemas/remove_all/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/resources/grants/schemas/remove_principal/out.test.toml b/acceptance/bundle/resources/grants/schemas/remove_principal/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/grants/schemas/remove_principal/out.test.toml +++ b/acceptance/bundle/resources/grants/schemas/remove_principal/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/grants/volumes/out.deploy1.requests.direct.json b/acceptance/bundle/resources/grants/volumes/out.deploy1.requests.json similarity index 100% rename from acceptance/bundle/resources/grants/volumes/out.deploy1.requests.direct.json rename to acceptance/bundle/resources/grants/volumes/out.deploy1.requests.json diff --git a/acceptance/bundle/resources/grants/volumes/out.deploy1.requests.terraform.json b/acceptance/bundle/resources/grants/volumes/out.deploy1.requests.terraform.json deleted file mode 100644 index 1e8bdf282a7..00000000000 --- a/acceptance/bundle/resources/grants/volumes/out.deploy1.requests.terraform.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.1/unity-catalog/permissions/volume/main.schema_grants_[UNIQUE_NAME].volume_name", - "body": { - "changes": [ - { - "add": [ - "READ_VOLUME", - "WRITE_VOLUME" - ], - "principal": "deco-test-user@databricks.com" - } - ] - } -} diff --git a/acceptance/bundle/resources/grants/volumes/out.deploy2.requests.direct.json b/acceptance/bundle/resources/grants/volumes/out.deploy2.requests.json similarity index 100% rename from acceptance/bundle/resources/grants/volumes/out.deploy2.requests.direct.json rename to acceptance/bundle/resources/grants/volumes/out.deploy2.requests.json diff --git a/acceptance/bundle/resources/grants/volumes/out.deploy2.requests.terraform.json b/acceptance/bundle/resources/grants/volumes/out.deploy2.requests.terraform.json deleted file mode 100644 index 5a2ad0d6eab..00000000000 --- a/acceptance/bundle/resources/grants/volumes/out.deploy2.requests.terraform.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.1/unity-catalog/permissions/volume/main.schema_grants_[UNIQUE_NAME].volume_name", - "body": { - "changes": [ - { - "add": [ - "MANAGE" - ], - "principal": "deco-test-user@databricks.com", - "remove": [ - "WRITE_VOLUME" - ] - } - ] - } -} diff --git a/acceptance/bundle/resources/grants/registered_models/out.destroy.requests.direct.json b/acceptance/bundle/resources/grants/volumes/out.destroy.requests.json similarity index 100% rename from acceptance/bundle/resources/grants/registered_models/out.destroy.requests.direct.json rename to acceptance/bundle/resources/grants/volumes/out.destroy.requests.json diff --git a/acceptance/bundle/resources/grants/volumes/out.destroy.requests.terraform.json b/acceptance/bundle/resources/grants/volumes/out.destroy.requests.terraform.json deleted file mode 100644 index 6dce8b24791..00000000000 --- a/acceptance/bundle/resources/grants/volumes/out.destroy.requests.terraform.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.1/unity-catalog/permissions/volume/main.schema_grants_[UNIQUE_NAME].volume_name", - "body": { - "changes": [ - { - "principal": "deco-test-user@databricks.com", - "remove": [ - "READ_VOLUME", - "MANAGE" - ] - } - ] - } -} diff --git a/acceptance/bundle/resources/grants/volumes/out.plan1.direct.json b/acceptance/bundle/resources/grants/volumes/out.plan1.json similarity index 100% rename from acceptance/bundle/resources/grants/volumes/out.plan1.direct.json rename to acceptance/bundle/resources/grants/volumes/out.plan1.json diff --git a/acceptance/bundle/resources/grants/volumes/out.plan1.terraform.json b/acceptance/bundle/resources/grants/volumes/out.plan1.terraform.json deleted file mode 100644 index 4764feb08fc..00000000000 --- a/acceptance/bundle/resources/grants/volumes/out.plan1.terraform.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.schemas.grants_schema": { - "action": "create" - }, - "resources.volumes.grants_volume": { - "action": "create" - }, - "resources.volumes.grants_volume.grants": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/grants/volumes/out.plan2.direct.json b/acceptance/bundle/resources/grants/volumes/out.plan2.json similarity index 100% rename from acceptance/bundle/resources/grants/volumes/out.plan2.direct.json rename to acceptance/bundle/resources/grants/volumes/out.plan2.json diff --git a/acceptance/bundle/resources/grants/volumes/out.plan2.terraform.json b/acceptance/bundle/resources/grants/volumes/out.plan2.terraform.json deleted file mode 100644 index 3def90a305b..00000000000 --- a/acceptance/bundle/resources/grants/volumes/out.plan2.terraform.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.schemas.grants_schema": { - "action": "skip" - }, - "resources.volumes.grants_volume": { - "action": "skip" - }, - "resources.volumes.grants_volume.grants": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/grants/volumes/out.test.toml b/acceptance/bundle/resources/grants/volumes/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/grants/volumes/out.test.toml +++ b/acceptance/bundle/resources/grants/volumes/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/grants/volumes/script b/acceptance/bundle/resources/grants/volumes/script index 9eb77b83730..2bc0695cf57 100644 --- a/acceptance/bundle/resources/grants/volumes/script +++ b/acceptance/bundle/resources/grants/volumes/script @@ -1,8 +1,8 @@ envsubst < databricks.yml.tmpl > databricks.yml -trace $CLI bundle plan -o json | nostamp > out.plan1.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan1.json trace $CLI bundle deploy -trace print_requests.py //permissions > out.deploy1.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //permissions > out.deploy1.requests.json # Since we're sending different requests between terraform and direct, assert that the end result is the same: trace $CLI grants get volume main.schema_grants_$UNIQUE_NAME.volume_name | jq --sort-keys @@ -10,11 +10,11 @@ trace $CLI grants get volume main.schema_grants_$UNIQUE_NAME.volume_name | jq -- update_file.py databricks.yml WRITE_VOLUME MANAGE # different on cloud vs local due to remote state -trace $CLI bundle plan -o json | nostamp | normalize_uc_payload.py effective_predictive_optimization_flag enable_predictive_optimization metastore_id schema_id updated_at updated_by volume_id > out.plan2.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | normalize_uc_payload.py effective_predictive_optimization_flag enable_predictive_optimization metastore_id schema_id updated_at updated_by volume_id > out.plan2.json trace $CLI bundle deploy -trace print_requests.py //permissions > out.deploy2.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //permissions > out.deploy2.requests.json trace $CLI grants get volume main.schema_grants_$UNIQUE_NAME.volume_name | jq --sort-keys trace $CLI bundle destroy --auto-approve -trace print_requests.py //permissions > out.destroy.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //permissions > out.destroy.requests.json diff --git a/acceptance/bundle/resources/independent/out.test.toml b/acceptance/bundle/resources/independent/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/independent/out.test.toml +++ b/acceptance/bundle/resources/independent/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/instance_pools/out.test.toml b/acceptance/bundle/resources/instance_pools/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/instance_pools/out.test.toml +++ b/acceptance/bundle/resources/instance_pools/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/instance_pools/test.toml b/acceptance/bundle/resources/instance_pools/test.toml index 3fe510e7c1b..0b34135a1cd 100644 --- a/acceptance/bundle/resources/instance_pools/test.toml +++ b/acceptance/bundle/resources/instance_pools/test.toml @@ -1,5 +1,4 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ "databricks.yml", diff --git a/acceptance/bundle/resources/job_runs/basic/out.test.toml b/acceptance/bundle/resources/job_runs/basic/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/job_runs/basic/out.test.toml +++ b/acceptance/bundle/resources/job_runs/basic/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/job_runs/destroy_unfinished_run/out.test.toml b/acceptance/bundle/resources/job_runs/destroy_unfinished_run/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/job_runs/destroy_unfinished_run/out.test.toml +++ b/acceptance/bundle/resources/job_runs/destroy_unfinished_run/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/job_runs/failed_run/out.test.toml b/acceptance/bundle/resources/job_runs/failed_run/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/job_runs/failed_run/out.test.toml +++ b/acceptance/bundle/resources/job_runs/failed_run/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/job_runs/interrupted_run/out.test.toml b/acceptance/bundle/resources/job_runs/interrupted_run/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/job_runs/interrupted_run/out.test.toml +++ b/acceptance/bundle/resources/job_runs/interrupted_run/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/job_runs/job_parameters/out.test.toml b/acceptance/bundle/resources/job_runs/job_parameters/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/job_runs/job_parameters/out.test.toml +++ b/acceptance/bundle/resources/job_runs/job_parameters/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/job_runs/on_bundle_deploy/out.test.toml b/acceptance/bundle/resources/job_runs/on_bundle_deploy/out.test.toml index dd03baaabb6..f7fafbcc731 100644 --- a/acceptance/bundle/resources/job_runs/on_bundle_deploy/out.test.toml +++ b/acceptance/bundle/resources/job_runs/on_bundle_deploy/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resources/job_runs/on_file_change/out.test.toml b/acceptance/bundle/resources/job_runs/on_file_change/out.test.toml index dd03baaabb6..f7fafbcc731 100644 --- a/acceptance/bundle/resources/job_runs/on_file_change/out.test.toml +++ b/acceptance/bundle/resources/job_runs/on_file_change/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resources/job_runs/on_file_change_build/out.test.toml b/acceptance/bundle/resources/job_runs/on_file_change_build/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/job_runs/on_file_change_build/out.test.toml +++ b/acceptance/bundle/resources/job_runs/on_file_change_build/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/job_runs/on_file_change_errors/out.test.toml b/acceptance/bundle/resources/job_runs/on_file_change_errors/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/job_runs/on_file_change_errors/out.test.toml +++ b/acceptance/bundle/resources/job_runs/on_file_change_errors/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/job_runs/on_file_change_glob/out.test.toml b/acceptance/bundle/resources/job_runs/on_file_change_glob/out.test.toml index dd03baaabb6..f7fafbcc731 100644 --- a/acceptance/bundle/resources/job_runs/on_file_change_glob/out.test.toml +++ b/acceptance/bundle/resources/job_runs/on_file_change_glob/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resources/job_runs/on_file_change_include_sync_root/out.test.toml b/acceptance/bundle/resources/job_runs/on_file_change_include_sync_root/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/job_runs/on_file_change_include_sync_root/out.test.toml +++ b/acceptance/bundle/resources/job_runs/on_file_change_include_sync_root/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/job_runs/on_file_change_predeploy/out.test.toml b/acceptance/bundle/resources/job_runs/on_file_change_predeploy/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/job_runs/on_file_change_predeploy/out.test.toml +++ b/acceptance/bundle/resources/job_runs/on_file_change_predeploy/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/job_runs/redeploy/out.test.toml b/acceptance/bundle/resources/job_runs/redeploy/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/job_runs/redeploy/out.test.toml +++ b/acceptance/bundle/resources/job_runs/redeploy/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/job_runs/retried_run_now/out.test.toml b/acceptance/bundle/resources/job_runs/retried_run_now/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/job_runs/retried_run_now/out.test.toml +++ b/acceptance/bundle/resources/job_runs/retried_run_now/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/job_runs/test.toml b/acceptance/bundle/resources/job_runs/test.toml deleted file mode 100644 index b056e544027..00000000000 --- a/acceptance/bundle/resources/job_runs/test.toml +++ /dev/null @@ -1,3 +0,0 @@ -# job_runs is a direct-engine-only resource; the Terraform provider has no -# equivalent, so restrict the matrix to direct. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/job_runs/wait/out.test.toml b/acceptance/bundle/resources/job_runs/wait/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/job_runs/wait/out.test.toml +++ b/acceptance/bundle/resources/job_runs/wait/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/alert-task/out.test.toml b/acceptance/bundle/resources/jobs/alert-task/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/jobs/alert-task/out.test.toml +++ b/acceptance/bundle/resources/jobs/alert-task/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/big_id/out.plan.direct.json b/acceptance/bundle/resources/jobs/big_id/out.plan.json similarity index 100% rename from acceptance/bundle/resources/jobs/big_id/out.plan.direct.json rename to acceptance/bundle/resources/jobs/big_id/out.plan.json diff --git a/acceptance/bundle/resources/jobs/big_id/out.state.direct.json b/acceptance/bundle/resources/jobs/big_id/out.state.json similarity index 100% rename from acceptance/bundle/resources/jobs/big_id/out.state.direct.json rename to acceptance/bundle/resources/jobs/big_id/out.state.json diff --git a/acceptance/bundle/resources/jobs/big_id/out.test.toml b/acceptance/bundle/resources/jobs/big_id/out.test.toml index dd03baaabb6..f7fafbcc731 100644 --- a/acceptance/bundle/resources/jobs/big_id/out.test.toml +++ b/acceptance/bundle/resources/jobs/big_id/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resources/jobs/big_id/script b/acceptance/bundle/resources/jobs/big_id/script index 6ad92c41f56..b3a3291d8f1 100644 --- a/acceptance/bundle/resources/jobs/big_id/script +++ b/acceptance/bundle/resources/jobs/big_id/script @@ -2,10 +2,10 @@ mkdir -p .databricks trace $CLI bundle validate -o json | jq .resources > out.validate.json trace $CLI bundle plan -o json > .databricks/tmp.plan.json -nostamp < .databricks/tmp.plan.json > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +nostamp < .databricks/tmp.plan.json > out.plan.json $CLI bundle deploy $(readplanarg .databricks/tmp.plan.json) trace print_requests.py //jobs --nostamp -print_state.py > out.state.$DATABRICKS_BUNDLE_ENGINE.json +print_state.py > out.state.json trace $CLI bundle plan | contains.py '0 to add, 0 to change, 0 to delete' trace $CLI bundle destroy --auto-approve trace print_requests.py //jobs --nostamp diff --git a/acceptance/bundle/resources/jobs/big_id/test.toml b/acceptance/bundle/resources/jobs/big_id/test.toml index e8500a3ae18..2314f05bd30 100644 --- a/acceptance/bundle/resources/jobs/big_id/test.toml +++ b/acceptance/bundle/resources/jobs/big_id/test.toml @@ -1,6 +1,5 @@ # terraform fails with: # panic: Error reading level state: strconv.ParseInt: parsing "[NUMID]": value out of range -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ['direct'] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resources/jobs/check-metadata/out.test.toml b/acceptance/bundle/resources/jobs/check-metadata/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/jobs/check-metadata/out.test.toml +++ b/acceptance/bundle/resources/jobs/check-metadata/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/cluster_policy/config_conflicts_policy/out.test.toml b/acceptance/bundle/resources/jobs/cluster_policy/config_conflicts_policy/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/jobs/cluster_policy/config_conflicts_policy/out.test.toml +++ b/acceptance/bundle/resources/jobs/cluster_policy/config_conflicts_policy/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/cluster_policy/default_flag/out.test.toml b/acceptance/bundle/resources/jobs/cluster_policy/default_flag/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/jobs/cluster_policy/default_flag/out.test.toml +++ b/acceptance/bundle/resources/jobs/cluster_policy/default_flag/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/cluster_policy/fixed_addition/out.test.toml b/acceptance/bundle/resources/jobs/cluster_policy/fixed_addition/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/jobs/cluster_policy/fixed_addition/out.test.toml +++ b/acceptance/bundle/resources/jobs/cluster_policy/fixed_addition/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/cluster_policy/owned_tag_drift/out.test.toml b/acceptance/bundle/resources/jobs/cluster_policy/owned_tag_drift/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/jobs/cluster_policy/owned_tag_drift/out.test.toml +++ b/acceptance/bundle/resources/jobs/cluster_policy/owned_tag_drift/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/cluster_policy/policy_id_scoping/out.test.toml b/acceptance/bundle/resources/jobs/cluster_policy/policy_id_scoping/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/jobs/cluster_policy/policy_id_scoping/out.test.toml +++ b/acceptance/bundle/resources/jobs/cluster_policy/policy_id_scoping/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/cluster_policy/test.toml b/acceptance/bundle/resources/jobs/cluster_policy/test.toml index 1114c31f86d..63cb5b569cf 100644 --- a/acceptance/bundle/resources/jobs/cluster_policy/test.toml +++ b/acceptance/bundle/resources/jobs/cluster_policy/test.toml @@ -2,7 +2,6 @@ # inherited engine matrix to direct. Cloud = true adds a real-workspace run; every test here # also runs locally against the testserver. Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] RecordRequests = false diff --git a/acceptance/bundle/resources/jobs/create-error/out.test.toml b/acceptance/bundle/resources/jobs/create-error/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/jobs/create-error/out.test.toml +++ b/acceptance/bundle/resources/jobs/create-error/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/create-error/test.toml b/acceptance/bundle/resources/jobs/create-error/test.toml index 450cadfab24..7b22301ecc1 100644 --- a/acceptance/bundle/resources/jobs/create-error/test.toml +++ b/acceptance/bundle/resources/jobs/create-error/test.toml @@ -18,7 +18,6 @@ RecordRequests = false # 25: } # # At least 1 "new_cluster" blocks are required. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] [[Server]] Pattern = "POST /api/2.2/jobs/create" diff --git a/acceptance/bundle/resources/jobs/delete_job/out.plan.direct.json b/acceptance/bundle/resources/jobs/delete_job/out.plan.json similarity index 100% rename from acceptance/bundle/resources/jobs/delete_job/out.plan.direct.json rename to acceptance/bundle/resources/jobs/delete_job/out.plan.json diff --git a/acceptance/bundle/resources/jobs/delete_job/out.plan.terraform.json b/acceptance/bundle/resources/jobs/delete_job/out.plan.terraform.json deleted file mode 100644 index 8d6a6747698..00000000000 --- a/acceptance/bundle/resources/jobs/delete_job/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.job": { - "action": "delete" - } - } -} diff --git a/acceptance/bundle/resources/jobs/delete_job/out.test.toml b/acceptance/bundle/resources/jobs/delete_job/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/jobs/delete_job/out.test.toml +++ b/acceptance/bundle/resources/jobs/delete_job/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/delete_job/script b/acceptance/bundle/resources/jobs/delete_job/script index 1622b3e11cb..feb32bce383 100644 --- a/acceptance/bundle/resources/jobs/delete_job/script +++ b/acceptance/bundle/resources/jobs/delete_job/script @@ -1,5 +1,5 @@ trace $CLI bundle deploy cp empty.yml databricks.yml -$CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan.json trace $CLI bundle deploy print_requests.py //jobs --nostamp diff --git a/acceptance/bundle/resources/jobs/delete_task/out.plan_create.direct.json b/acceptance/bundle/resources/jobs/delete_task/out.plan_create.json similarity index 100% rename from acceptance/bundle/resources/jobs/delete_task/out.plan_create.direct.json rename to acceptance/bundle/resources/jobs/delete_task/out.plan_create.json diff --git a/acceptance/bundle/resources/jobs/delete_task/out.plan_create.terraform.json b/acceptance/bundle/resources/jobs/delete_task/out.plan_create.terraform.json deleted file mode 100644 index 2e825b3672d..00000000000 --- a/acceptance/bundle/resources/jobs/delete_task/out.plan_create.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.job": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/jobs/delete_task/out.plan_update.direct.json b/acceptance/bundle/resources/jobs/delete_task/out.plan_update.json similarity index 100% rename from acceptance/bundle/resources/jobs/delete_task/out.plan_update.direct.json rename to acceptance/bundle/resources/jobs/delete_task/out.plan_update.json diff --git a/acceptance/bundle/resources/jobs/delete_task/out.plan_update.terraform.json b/acceptance/bundle/resources/jobs/delete_task/out.plan_update.terraform.json deleted file mode 100644 index 8580ad3cea8..00000000000 --- a/acceptance/bundle/resources/jobs/delete_task/out.plan_update.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.job": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/jobs/delete_task/out.test.toml b/acceptance/bundle/resources/jobs/delete_task/out.test.toml index bf4f0e7d3c6..f7fafbcc731 100644 --- a/acceptance/bundle/resources/jobs/delete_task/out.test.toml +++ b/acceptance/bundle/resources/jobs/delete_task/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resources/jobs/delete_task/script b/acceptance/bundle/resources/jobs/delete_task/script index d4b38a78cc8..2ea14386cfe 100644 --- a/acceptance/bundle/resources/jobs/delete_task/script +++ b/acceptance/bundle/resources/jobs/delete_task/script @@ -2,10 +2,10 @@ mkdir -p .databricks $CLI bundle plan -o json > .databricks/tmp.plan_create.json -nostamp < .databricks/tmp.plan_create.json > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +nostamp < .databricks/tmp.plan_create.json > out.plan_create.json $CLI bundle deploy $(readplanarg .databricks/tmp.plan_create.json) grep -v TO_DELETE databricks.yml > tmp.yml && mv tmp.yml databricks.yml trace cat databricks.yml $CLI bundle plan -o json > .databricks/tmp.plan_update.json -nostamp < .databricks/tmp.plan_update.json > out.plan_update.$DATABRICKS_BUNDLE_ENGINE.json +nostamp < .databricks/tmp.plan_update.json > out.plan_update.json $CLI bundle deploy $(readplanarg .databricks/tmp.plan_update.json) diff --git a/acceptance/bundle/resources/jobs/double-underscore-keys/out.test.toml b/acceptance/bundle/resources/jobs/double-underscore-keys/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/jobs/double-underscore-keys/out.test.toml +++ b/acceptance/bundle/resources/jobs/double-underscore-keys/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/fail-on-active-runs/out.test.toml b/acceptance/bundle/resources/jobs/fail-on-active-runs/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/jobs/fail-on-active-runs/out.test.toml +++ b/acceptance/bundle/resources/jobs/fail-on-active-runs/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/instance_pool_and_node_type/out.test.toml b/acceptance/bundle/resources/jobs/instance_pool_and_node_type/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/jobs/instance_pool_and_node_type/out.test.toml +++ b/acceptance/bundle/resources/jobs/instance_pool_and_node_type/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/no-git-provider/out.deploy.terraform.txt b/acceptance/bundle/resources/jobs/no-git-provider/out.deploy.terraform.txt deleted file mode 100644 index df5f838399e..00000000000 --- a/acceptance/bundle/resources/jobs/no-git-provider/out.deploy.terraform.txt +++ /dev/null @@ -1,10 +0,0 @@ - ->>> errcode [CLI] bundle deploy --force-lock -Warning: required field "git_provider" is not set - at resources.jobs.foo.git_source - in databricks.yml:12:9 - -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/[UNIQUE_NAME]/files... -Created jobs.foo -Files: 5 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged diff --git a/acceptance/bundle/resources/jobs/no-git-provider/out.deploy.direct.txt b/acceptance/bundle/resources/jobs/no-git-provider/out.deploy.txt similarity index 100% rename from acceptance/bundle/resources/jobs/no-git-provider/out.deploy.direct.txt rename to acceptance/bundle/resources/jobs/no-git-provider/out.deploy.txt diff --git a/acceptance/bundle/resources/jobs/no-git-provider/out.destroy.terraform.txt b/acceptance/bundle/resources/jobs/no-git-provider/out.destroy.terraform.txt deleted file mode 100644 index a3e25190f3e..00000000000 --- a/acceptance/bundle/resources/jobs/no-git-provider/out.destroy.terraform.txt +++ /dev/null @@ -1,12 +0,0 @@ - ->>> errcode [CLI] bundle destroy --auto-approve -Warning: required field "git_provider" is not set - at resources.jobs.foo.git_source - in databricks.yml:12:9 - -The following resources will be deleted: - delete resources.jobs.foo - -All files and directories at the following location will be deleted: /Workspace/Users/[USERNAME]/.bundle/[UNIQUE_NAME] - -Destroy: 1 deleted diff --git a/acceptance/bundle/resources/jobs/no-git-provider/out.destroy.direct.txt b/acceptance/bundle/resources/jobs/no-git-provider/out.destroy.txt similarity index 100% rename from acceptance/bundle/resources/jobs/no-git-provider/out.destroy.direct.txt rename to acceptance/bundle/resources/jobs/no-git-provider/out.destroy.txt diff --git a/acceptance/bundle/resources/jobs/no-git-provider/out.test.toml b/acceptance/bundle/resources/jobs/no-git-provider/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/jobs/no-git-provider/out.test.toml +++ b/acceptance/bundle/resources/jobs/no-git-provider/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/no-git-provider/script b/acceptance/bundle/resources/jobs/no-git-provider/script index 7c78841a145..acaec1e9066 100644 --- a/acceptance/bundle/resources/jobs/no-git-provider/script +++ b/acceptance/bundle/resources/jobs/no-git-provider/script @@ -1,7 +1,7 @@ envsubst < databricks.yml.tmpl > databricks.yml cleanup() { - trace errcode $CLI bundle destroy --auto-approve > out.destroy.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 + trace errcode $CLI bundle destroy --auto-approve > out.destroy.txt 2>&1 } trap cleanup EXIT -trace errcode $CLI bundle deploy --force-lock > out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 +trace errcode $CLI bundle deploy --force-lock > out.deploy.txt 2>&1 diff --git a/acceptance/bundle/resources/jobs/num_workers/out.test.toml b/acceptance/bundle/resources/jobs/num_workers/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/jobs/num_workers/out.test.toml +++ b/acceptance/bundle/resources/jobs/num_workers/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/on_failure_empty_slice/out.plan.direct.json b/acceptance/bundle/resources/jobs/on_failure_empty_slice/out.plan.json similarity index 100% rename from acceptance/bundle/resources/jobs/on_failure_empty_slice/out.plan.direct.json rename to acceptance/bundle/resources/jobs/on_failure_empty_slice/out.plan.json diff --git a/acceptance/bundle/resources/jobs/on_failure_empty_slice/out.plan.terraform.json b/acceptance/bundle/resources/jobs/on_failure_empty_slice/out.plan.terraform.json deleted file mode 100644 index f8638f3b7f1..00000000000 --- a/acceptance/bundle/resources/jobs/on_failure_empty_slice/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.refresh_usage_logs": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/resources/jobs/on_failure_empty_slice/out.test.toml b/acceptance/bundle/resources/jobs/on_failure_empty_slice/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/jobs/on_failure_empty_slice/out.test.toml +++ b/acceptance/bundle/resources/jobs/on_failure_empty_slice/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/on_failure_empty_slice/script b/acceptance/bundle/resources/jobs/on_failure_empty_slice/script index 6f0606bc346..f218f84fd3e 100644 --- a/acceptance/bundle/resources/jobs/on_failure_empty_slice/script +++ b/acceptance/bundle/resources/jobs/on_failure_empty_slice/script @@ -1,3 +1,3 @@ trace $CLI bundle plan trace $CLI bundle deploy -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.jobs.refresh_usage_logs".changes // .' > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.jobs.refresh_usage_logs".changes // .' > out.plan.json diff --git a/acceptance/bundle/resources/jobs/remote_add_tag/out.plan_post_update.direct.json b/acceptance/bundle/resources/jobs/remote_add_tag/out.plan_post_update.json similarity index 100% rename from acceptance/bundle/resources/jobs/remote_add_tag/out.plan_post_update.direct.json rename to acceptance/bundle/resources/jobs/remote_add_tag/out.plan_post_update.json diff --git a/acceptance/bundle/resources/jobs/remote_add_tag/out.plan_post_update.terraform.json b/acceptance/bundle/resources/jobs/remote_add_tag/out.plan_post_update.terraform.json deleted file mode 100644 index b5415d47a54..00000000000 --- a/acceptance/bundle/resources/jobs/remote_add_tag/out.plan_post_update.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.foo": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/jobs/remote_add_tag/out.test.toml b/acceptance/bundle/resources/jobs/remote_add_tag/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/jobs/remote_add_tag/out.test.toml +++ b/acceptance/bundle/resources/jobs/remote_add_tag/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/remote_add_tag/script b/acceptance/bundle/resources/jobs/remote_add_tag/script index 3a651737979..c60ed4571ce 100644 --- a/acceptance/bundle/resources/jobs/remote_add_tag/script +++ b/acceptance/bundle/resources/jobs/remote_add_tag/script @@ -8,4 +8,4 @@ r["tags"]["new_tag"] = "new_value" EOF $CLI bundle plan -$CLI bundle plan -o json | nostamp > out.plan_post_update.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan_post_update.json diff --git a/acceptance/bundle/resources/jobs/remote_delete/deploy/out.plan.direct.json b/acceptance/bundle/resources/jobs/remote_delete/deploy/out.plan.json similarity index 100% rename from acceptance/bundle/resources/jobs/remote_delete/deploy/out.plan.direct.json rename to acceptance/bundle/resources/jobs/remote_delete/deploy/out.plan.json diff --git a/acceptance/bundle/resources/jobs/remote_delete/deploy/out.plan.terraform.json b/acceptance/bundle/resources/jobs/remote_delete/deploy/out.plan.terraform.json deleted file mode 100644 index 5a250db78de..00000000000 --- a/acceptance/bundle/resources/jobs/remote_delete/deploy/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.foo": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/jobs/remote_delete/deploy/out.test.toml b/acceptance/bundle/resources/jobs/remote_delete/deploy/out.test.toml index bf4f0e7d3c6..f7fafbcc731 100644 --- a/acceptance/bundle/resources/jobs/remote_delete/deploy/out.test.toml +++ b/acceptance/bundle/resources/jobs/remote_delete/deploy/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resources/jobs/remote_delete/deploy/script b/acceptance/bundle/resources/jobs/remote_delete/deploy/script index b12efc6affc..fd985ad10d2 100644 --- a/acceptance/bundle/resources/jobs/remote_delete/deploy/script +++ b/acceptance/bundle/resources/jobs/remote_delete/deploy/script @@ -7,5 +7,5 @@ job_id=`$CLI bundle summary -o json | jq -r .resources.jobs.foo.id` trace $CLI jobs delete $job_id trace $CLI bundle plan $CLI bundle plan -o json &> .databricks/tmp.plan.json -nostamp < .databricks/tmp.plan.json > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +nostamp < .databricks/tmp.plan.json > out.plan.json $CLI bundle deploy $(readplanarg .databricks/tmp.plan.json) diff --git a/acceptance/bundle/resources/jobs/remote_delete/destroy/out.test.toml b/acceptance/bundle/resources/jobs/remote_delete/destroy/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/jobs/remote_delete/destroy/out.test.toml +++ b/acceptance/bundle/resources/jobs/remote_delete/destroy/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.deploy_removed.terraform.txt b/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.deploy_removed.terraform.txt deleted file mode 100644 index be8b0698ea5..00000000000 --- a/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.deploy_removed.terraform.txt +++ /dev/null @@ -1,5 +0,0 @@ - ->>> [CLI] bundle deploy --auto-approve -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 4 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 0 unchanged diff --git a/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.deploy_removed.direct.txt b/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.deploy_removed.txt similarity index 100% rename from acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.deploy_removed.direct.txt rename to acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.deploy_removed.txt diff --git a/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.plan_removed.terraform.txt b/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.plan_removed.terraform.txt deleted file mode 100644 index ed49fd178e0..00000000000 --- a/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.plan_removed.terraform.txt +++ /dev/null @@ -1,3 +0,0 @@ - ->>> [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 0 unchanged diff --git a/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.plan_removed.direct.txt b/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.plan_removed.txt similarity index 100% rename from acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.plan_removed.direct.txt rename to acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.plan_removed.txt diff --git a/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.summary.terraform.txt b/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.summary.terraform.txt deleted file mode 100644 index 1f15be287ce..00000000000 --- a/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.summary.terraform.txt +++ /dev/null @@ -1,16 +0,0 @@ - ->>> [CLI] bundle summary -Name: test-bundle -Target: default -Workspace: - User: [USERNAME] - Path: /Workspace/Users/[USERNAME]/.bundle/test-bundle/default -Resources: - Jobs: - foo: - Name: - URL: [DATABRICKS_URL]/jobs/[NUMID]?w=[NUMID] - Pipelines: - bar: - Name: - URL: [DATABRICKS_URL]/pipelines/[UUID]?w=[NUMID] diff --git a/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.summary.direct.txt b/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.summary.txt similarity index 100% rename from acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.summary.direct.txt rename to acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.summary.txt diff --git a/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.test.toml b/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.test.toml +++ b/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/script b/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/script index 89525ab713e..07562997192 100644 --- a/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/script +++ b/acceptance/bundle/resources/jobs/remote_delete/removed_from_config/script @@ -9,13 +9,13 @@ title "Remove resources from config, plan and deploy" cp empty.yml databricks.yml # Drain requests recorded so far; only requests made after the config removal matter below. print_requests.py --get // &> LOG.requests_setup -trace $CLI bundle plan &> out.plan_removed.$DATABRICKS_BUNDLE_ENGINE.txt -trace $CLI bundle deploy --auto-approve &> out.deploy_removed.$DATABRICKS_BUNDLE_ENGINE.txt +trace $CLI bundle plan &> out.plan_removed.txt +trace $CLI bundle deploy --auto-approve &> out.deploy_removed.txt title "Plan and deploy again, then summary" trace $CLI bundle plan trace $CLI bundle deploy -trace $CLI bundle summary &> out.summary.$DATABRICKS_BUNDLE_ENGINE.txt +trace $CLI bundle summary &> out.summary.txt title "No delete API calls for resources that are already gone remotely" trace print_requests.py //jobs/delete //pipelines/ --nostamp diff --git a/acceptance/bundle/resources/jobs/remote_matches_config/out.plan.direct.json b/acceptance/bundle/resources/jobs/remote_matches_config/out.plan.json similarity index 100% rename from acceptance/bundle/resources/jobs/remote_matches_config/out.plan.direct.json rename to acceptance/bundle/resources/jobs/remote_matches_config/out.plan.json diff --git a/acceptance/bundle/resources/jobs/remote_matches_config/out.plan.terraform.json b/acceptance/bundle/resources/jobs/remote_matches_config/out.plan.terraform.json deleted file mode 100644 index 0b518506d84..00000000000 --- a/acceptance/bundle/resources/jobs/remote_matches_config/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.my_job": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/resources/jobs/remote_matches_config/out.test.toml b/acceptance/bundle/resources/jobs/remote_matches_config/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/jobs/remote_matches_config/out.test.toml +++ b/acceptance/bundle/resources/jobs/remote_matches_config/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/remote_matches_config/script b/acceptance/bundle/resources/jobs/remote_matches_config/script index b8108be15cf..3b3b62ad4a1 100755 --- a/acceptance/bundle/resources/jobs/remote_matches_config/script +++ b/acceptance/bundle/resources/jobs/remote_matches_config/script @@ -13,7 +13,7 @@ r["max_concurrent_runs"] = 2 EOF trace $CLI bundle plan -$CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan.json rm "$OUT_REQUESTS" # XXX READPLAN diff --git a/acceptance/bundle/resources/jobs/shared-root-path/out.test.toml b/acceptance/bundle/resources/jobs/shared-root-path/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/jobs/shared-root-path/out.test.toml +++ b/acceptance/bundle/resources/jobs/shared-root-path/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/tags_empty_map/out.plan.direct.json b/acceptance/bundle/resources/jobs/tags_empty_map/out.plan.json similarity index 100% rename from acceptance/bundle/resources/jobs/tags_empty_map/out.plan.direct.json rename to acceptance/bundle/resources/jobs/tags_empty_map/out.plan.json diff --git a/acceptance/bundle/resources/jobs/tags_empty_map/out.plan.terraform.json b/acceptance/bundle/resources/jobs/tags_empty_map/out.plan.terraform.json deleted file mode 100644 index 5c1784708bf..00000000000 --- a/acceptance/bundle/resources/jobs/tags_empty_map/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.test_job": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/resources/jobs/tags_empty_map/out.test.toml b/acceptance/bundle/resources/jobs/tags_empty_map/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/jobs/tags_empty_map/out.test.toml +++ b/acceptance/bundle/resources/jobs/tags_empty_map/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/tags_empty_map/script b/acceptance/bundle/resources/jobs/tags_empty_map/script index 4a232723bd0..5708cef5ecb 100644 --- a/acceptance/bundle/resources/jobs/tags_empty_map/script +++ b/acceptance/bundle/resources/jobs/tags_empty_map/script @@ -1,3 +1,3 @@ trace $CLI bundle plan trace $CLI bundle deploy -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.jobs.test_job".changes // .' > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.jobs.test_job".changes // .' > out.plan.json diff --git a/acceptance/bundle/resources/jobs/task-source/out.git_job.terraform.txt b/acceptance/bundle/resources/jobs/task-source/out.git_job.terraform.txt deleted file mode 100644 index c1bd5634456..00000000000 --- a/acceptance/bundle/resources/jobs/task-source/out.git_job.terraform.txt +++ /dev/null @@ -1,204 +0,0 @@ -{ - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/task-source/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "git_source": { - "git_branch": "main", - "git_provider": "github", - "git_url": "https://github.com/databricks/cli.git" - }, - "max_concurrent_runs": 1, - "name": "git_job", - "queue": { - "enabled": true - }, - "tasks": [ - { - "dbt_task": { - "commands": [ - "dbt run" - ], - "project_directory": "./dbt_project", - "schema": "default", - "source": "GIT" - }, - "new_cluster": { - "custom_tags": { - "ResourceClass": "SingleNode" - }, - "num_workers": 0, - "spark_conf": { - "spark.databricks.cluster.profile": "singleNode", - "spark.master": "local[*]" - }, - "spark_version": "15.4.x-scala2.12" - }, - "task_key": "test_task_dbt" - }, - { - "for_each_task": { - "inputs": "[1]", - "task": { - "notebook_task": { - "notebook_path": "./notebook.py", - "source": "GIT" - }, - "task_key": "test_task_foreach_no_source" - } - }, - "task_key": "test_task_foreach_no_source" - }, - { - "for_each_task": { - "inputs": "[1]", - "task": { - "notebook_task": { - "notebook_path": "./notebook.py", - "source": "WORKSPACE" - }, - "task_key": "test_task_foreach_workspace" - } - }, - "task_key": "test_task_foreach_workspace" - }, - { - "notebook_task": { - "notebook_path": "./notebook.py", - "source": "GIT" - }, - "task_key": "test_task_no_source" - }, - { - "notebook_task": { - "notebook_path": "./notebook.py", - "source": "WORKSPACE" - }, - "task_key": "test_task_source_workspace" - }, - { - "sql_task": { - "file": { - "path": "./sql.sql", - "source": "GIT" - }, - "warehouse_id": "cafef00d" - }, - "task_key": "test_task_sql" - } - ] -} -{ - "job_id": [NUMID], - "new_settings": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/task-source/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "email_notifications": {}, - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "git_job", - "queue": { - "enabled": true - }, - "run_as": { - "user_name": "[USERNAME]" - }, - "tasks": [ - { - "dbt_task": { - "commands": [ - "dbt run" - ], - "project_directory": "/Workspace/Users/[USERNAME]/.bundle/task-source/default/files/dbt_project", - "schema": "default", - "source": "WORKSPACE" - }, - "email_notifications": {}, - "new_cluster": { - "aws_attributes": { - "availability": "SPOT_WITH_FALLBACK", - "zone_id": "us-east-1c" - }, - "custom_tags": { - "ResourceClass": "SingleNode" - }, - "data_security_mode": "SINGLE_USER", - "num_workers": 0, - "spark_conf": { - "spark.databricks.cluster.profile": "singleNode", - "spark.master": "local[*]" - }, - "spark_version": "15.4.x-scala2.12" - }, - "run_if": "ALL_SUCCESS", - "task_key": "test_task_dbt" - }, - { - "email_notifications": {}, - "for_each_task": { - "inputs": "[1]", - "task": { - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/task-source/default/files/notebook", - "source": "WORKSPACE" - }, - "task_key": "test_task_foreach_no_source" - } - }, - "run_if": "ALL_SUCCESS", - "task_key": "test_task_foreach_no_source" - }, - { - "email_notifications": {}, - "for_each_task": { - "inputs": "[1]", - "task": { - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/task-source/default/files/notebook", - "source": "WORKSPACE" - }, - "task_key": "test_task_foreach_workspace" - } - }, - "run_if": "ALL_SUCCESS", - "task_key": "test_task_foreach_workspace" - }, - { - "email_notifications": {}, - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/task-source/default/files/notebook", - "source": "WORKSPACE" - }, - "run_if": "ALL_SUCCESS", - "task_key": "test_task_no_source" - }, - { - "email_notifications": {}, - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/task-source/default/files/notebook", - "source": "WORKSPACE" - }, - "run_if": "ALL_SUCCESS", - "task_key": "test_task_source_workspace" - }, - { - "email_notifications": {}, - "run_if": "ALL_SUCCESS", - "sql_task": { - "file": { - "path": "/Workspace/Users/[USERNAME]/.bundle/task-source/default/files/sql.sql", - "source": "WORKSPACE" - }, - "warehouse_id": "cafef00d" - }, - "task_key": "test_task_sql" - } - ], - "webhook_notifications": {} - } -} diff --git a/acceptance/bundle/resources/jobs/task-source/out.git_job.direct.txt b/acceptance/bundle/resources/jobs/task-source/out.git_job.txt similarity index 100% rename from acceptance/bundle/resources/jobs/task-source/out.git_job.direct.txt rename to acceptance/bundle/resources/jobs/task-source/out.git_job.txt diff --git a/acceptance/bundle/resources/jobs/task-source/out.test.toml b/acceptance/bundle/resources/jobs/task-source/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/jobs/task-source/out.test.toml +++ b/acceptance/bundle/resources/jobs/task-source/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/task-source/out.workspace_job.terraform.txt b/acceptance/bundle/resources/jobs/task-source/out.workspace_job.terraform.txt deleted file mode 100644 index de17310de77..00000000000 --- a/acceptance/bundle/resources/jobs/task-source/out.workspace_job.terraform.txt +++ /dev/null @@ -1,35 +0,0 @@ -{ - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/task-source/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "workspace_job", - "queue": { - "enabled": true - }, - "tasks": [ - { - "for_each_task": { - "inputs": "[1]", - "task": { - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/task-source/default/files/notebook", - "source": "WORKSPACE" - }, - "task_key": "test_task_foreach_no_source" - } - }, - "task_key": "test_task_foreach" - }, - { - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/task-source/default/files/notebook", - "source": "WORKSPACE" - }, - "task_key": "test_task_no_source" - } - ] -} diff --git a/acceptance/bundle/resources/jobs/task-source/out.workspace_job.direct.txt b/acceptance/bundle/resources/jobs/task-source/out.workspace_job.txt similarity index 100% rename from acceptance/bundle/resources/jobs/task-source/out.workspace_job.direct.txt rename to acceptance/bundle/resources/jobs/task-source/out.workspace_job.txt diff --git a/acceptance/bundle/resources/jobs/task-source/script b/acceptance/bundle/resources/jobs/task-source/script index 56a1acd6da7..bd249e805aa 100644 --- a/acceptance/bundle/resources/jobs/task-source/script +++ b/acceptance/bundle/resources/jobs/task-source/script @@ -2,8 +2,8 @@ trace $CLI bundle deploy # For terraform we expect the task source to be explicitly set always # For direct we do not expect it to be set unless explicitly specified in the bundle config -trace jq -s '.[] | select(.path=="/api/2.2/jobs/create") | select(.body.name=="git_job") | .body | del(.deployment.deployment_id, .deployment.version_id)' "$OUT_REQUESTS" | jq --sort-keys > out.git_job.$DATABRICKS_BUNDLE_ENGINE.txt -trace jq -s '.[] | select(.path=="/api/2.2/jobs/create") | select(.body.name=="workspace_job") | .body | del(.deployment.deployment_id, .deployment.version_id)' "$OUT_REQUESTS" | jq --sort-keys > out.workspace_job.$DATABRICKS_BUNDLE_ENGINE.txt +trace jq -s '.[] | select(.path=="/api/2.2/jobs/create") | select(.body.name=="git_job") | .body | del(.deployment.deployment_id, .deployment.version_id)' "$OUT_REQUESTS" | jq --sort-keys > out.git_job.txt +trace jq -s '.[] | select(.path=="/api/2.2/jobs/create") | select(.body.name=="workspace_job") | .body | del(.deployment.deployment_id, .deployment.version_id)' "$OUT_REQUESTS" | jq --sort-keys > out.workspace_job.txt rm "$OUT_REQUESTS" # Removing the git_source block and deploying again @@ -13,7 +13,7 @@ trace $CLI bundle deploy # In direct mode update should not contain source unless explicitly specified in the bundle config # In terraform mode update should always contain source field -trace jq -s '.[] | select(.path=="/api/2.2/jobs/reset") | select(.body.new_settings.name=="git_job") | .body | del(.new_settings.deployment.deployment_id, .new_settings.deployment.version_id)' "$OUT_REQUESTS" | jq --sort-keys >> out.git_job.$DATABRICKS_BUNDLE_ENGINE.txt -trace jq -s '.[] | select(.path=="/api/2.2/jobs/reset") | select(.body.new_settings.name=="workspace_job") | .body | del(.new_settings.deployment.deployment_id, .new_settings.deployment.version_id)' "$OUT_REQUESTS" | jq --sort-keys >> out.workspace_job.$DATABRICKS_BUNDLE_ENGINE.txt +trace jq -s '.[] | select(.path=="/api/2.2/jobs/reset") | select(.body.new_settings.name=="git_job") | .body | del(.new_settings.deployment.deployment_id, .new_settings.deployment.version_id)' "$OUT_REQUESTS" | jq --sort-keys >> out.git_job.txt +trace jq -s '.[] | select(.path=="/api/2.2/jobs/reset") | select(.body.new_settings.name=="workspace_job") | .body | del(.new_settings.deployment.deployment_id, .new_settings.deployment.version_id)' "$OUT_REQUESTS" | jq --sort-keys >> out.workspace_job.txt rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/resources/jobs/tasks-reorder-locally/out.test.toml b/acceptance/bundle/resources/jobs/tasks-reorder-locally/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/jobs/tasks-reorder-locally/out.test.toml +++ b/acceptance/bundle/resources/jobs/tasks-reorder-locally/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/unknown-terraform-field/databricks.yml b/acceptance/bundle/resources/jobs/unknown-terraform-field/databricks.yml deleted file mode 100644 index 10120802bd7..00000000000 --- a/acceptance/bundle/resources/jobs/unknown-terraform-field/databricks.yml +++ /dev/null @@ -1,17 +0,0 @@ -bundle: - name: test-bundle - -resources: - jobs: - job: - name: test-job - tasks: - - task_key: test_task - new_cluster: - spark_version: 13.3.x-scala2.12 - num_workers: 2 - # In the SDK jobs schema, but not in the pinned Terraform provider schema. - autotermination_minutes: 60 - python_wheel_task: - package_name: "whl" - entry_point: "run" diff --git a/acceptance/bundle/resources/jobs/unknown-terraform-field/out.test.toml b/acceptance/bundle/resources/jobs/unknown-terraform-field/out.test.toml deleted file mode 100644 index 5d0f3e4aac2..00000000000 --- a/acceptance/bundle/resources/jobs/unknown-terraform-field/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] -EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/unknown-terraform-field/output.txt b/acceptance/bundle/resources/jobs/unknown-terraform-field/output.txt deleted file mode 100644 index 6a6eb192d41..00000000000 --- a/acceptance/bundle/resources/jobs/unknown-terraform-field/output.txt +++ /dev/null @@ -1,10 +0,0 @@ - ->>> [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Warning: unknown field: autotermination_minutes - at task[0].new_cluster - in databricks.yml:14:13 - -Created jobs.job -Files: 3 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged diff --git a/acceptance/bundle/resources/jobs/unknown-terraform-field/script b/acceptance/bundle/resources/jobs/unknown-terraform-field/script deleted file mode 100644 index 68ebb78d775..00000000000 --- a/acceptance/bundle/resources/jobs/unknown-terraform-field/script +++ /dev/null @@ -1 +0,0 @@ -trace $CLI bundle deploy diff --git a/acceptance/bundle/resources/jobs/unknown-terraform-field/test.toml b/acceptance/bundle/resources/jobs/unknown-terraform-field/test.toml deleted file mode 100644 index 4880c144868..00000000000 --- a/acceptance/bundle/resources/jobs/unknown-terraform-field/test.toml +++ /dev/null @@ -1,3 +0,0 @@ -# The dropped-field warning is terraform-only; the direct engine deploys these fields. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] -RecordRequests = false diff --git a/acceptance/bundle/resources/jobs/update/out.plan_create.direct.json b/acceptance/bundle/resources/jobs/update/out.plan_create.json similarity index 100% rename from acceptance/bundle/resources/jobs/update/out.plan_create.direct.json rename to acceptance/bundle/resources/jobs/update/out.plan_create.json diff --git a/acceptance/bundle/resources/jobs/update/out.plan_create.terraform.json b/acceptance/bundle/resources/jobs/update/out.plan_create.terraform.json deleted file mode 100644 index 5a250db78de..00000000000 --- a/acceptance/bundle/resources/jobs/update/out.plan_create.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.foo": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/jobs/update/out.plan_skip.direct.json b/acceptance/bundle/resources/jobs/update/out.plan_skip.json similarity index 100% rename from acceptance/bundle/resources/jobs/update/out.plan_skip.direct.json rename to acceptance/bundle/resources/jobs/update/out.plan_skip.json diff --git a/acceptance/bundle/resources/jobs/update/out.plan_skip.terraform.json b/acceptance/bundle/resources/jobs/update/out.plan_skip.terraform.json deleted file mode 100644 index 7dbc48d7c39..00000000000 --- a/acceptance/bundle/resources/jobs/update/out.plan_skip.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.foo": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/resources/jobs/update/out.plan_update.direct.json b/acceptance/bundle/resources/jobs/update/out.plan_update.json similarity index 100% rename from acceptance/bundle/resources/jobs/update/out.plan_update.direct.json rename to acceptance/bundle/resources/jobs/update/out.plan_update.json diff --git a/acceptance/bundle/resources/jobs/update/out.plan_update.terraform.json b/acceptance/bundle/resources/jobs/update/out.plan_update.terraform.json deleted file mode 100644 index b5415d47a54..00000000000 --- a/acceptance/bundle/resources/jobs/update/out.plan_update.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.foo": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/jobs/update/out.state.direct.json b/acceptance/bundle/resources/jobs/update/out.state.json similarity index 100% rename from acceptance/bundle/resources/jobs/update/out.state.direct.json rename to acceptance/bundle/resources/jobs/update/out.state.json diff --git a/acceptance/bundle/resources/jobs/update/out.state.terraform.json b/acceptance/bundle/resources/jobs/update/out.state.terraform.json deleted file mode 100644 index 750dbd3baa0..00000000000 --- a/acceptance/bundle/resources/jobs/update/out.state.terraform.json +++ /dev/null @@ -1,173 +0,0 @@ -{ - "version": 4, - "terraform_version": "1.5.5", - "serial": 1, - "lineage": "[UUID]", - "outputs": {}, - "resources": [ - { - "mode": "managed", - "type": "databricks_job", - "name": "foo", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 2, - "attributes": { - "always_running": false, - "budget_policy_id": null, - "continuous": [], - "control_run_state": false, - "dbt_task": [], - "deployment": [ - { - "deployment_id": "", - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json", - "version_id": "" - } - ], - "description": null, - "edit_mode": "UI_LOCKED", - "email_notifications": [ - { - "no_alert_for_skipped_runs": false, - "on_duration_warning_threshold_exceeded": [], - "on_failure": [], - "on_start": [], - "on_streaming_backlog_exceeded": [], - "on_success": [] - } - ], - "environment": [], - "existing_cluster_id": null, - "format": "MULTI_TASK", - "git_source": [], - "health": [], - "id": "[FOO_ID]", - "job_cluster": [ - { - "job_cluster_key": "key", - "new_cluster": [ - { - "__apply_policy_default_values_allow_list": null, - "apply_policy_default_values": false, - "autoscale": [], - "aws_attributes": [], - "azure_attributes": [], - "cluster_id": "", - "cluster_log_conf": [], - "cluster_mount_info": [], - "cluster_name": "", - "custom_tags": null, - "data_security_mode": "", - "dependency_mode": "", - "docker_image": [], - "driver_instance_pool_id": "", - "driver_node_type_flexibility": [], - "driver_node_type_id": "", - "enable_elastic_disk": false, - "enable_local_disk_encryption": false, - "gcp_attributes": [], - "idempotency_token": "", - "init_scripts": [], - "instance_pool_id": "", - "is_single_node": false, - "kind": "", - "library": [], - "node_type_id": "", - "num_workers": 0, - "policy_id": "", - "provider_config": [], - "remote_disk_throughput": 0, - "runtime_engine": "", - "single_user_name": "", - "spark_conf": null, - "spark_env_vars": null, - "spark_version": "13.3.x-scala2.12", - "ssh_public_keys": null, - "total_initial_remote_disk_size": 0, - "use_ml_runtime": false, - "worker_node_type_flexibility": [], - "workload_type": [] - } - ], - "serverless_compute_id": "" - } - ], - "library": [], - "max_concurrent_runs": 1, - "max_retries": 0, - "min_retry_interval_millis": 0, - "name": "foo", - "new_cluster": [], - "notebook_task": [], - "notification_settings": [], - "parameter": [], - "parent_path": null, - "performance_target": null, - "pipeline_task": [], - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "python_wheel_task": [], - "queue": [ - { - "enabled": true - } - ], - "retry_on_timeout": false, - "run_as": [ - { - "group_name": "", - "service_principal_name": "", - "user_name": "[USERNAME]" - } - ], - "run_job_task": [], - "schedule": [], - "spark_jar_task": [], - "spark_python_task": [], - "spark_submit_task": [], - "tags": null, - "task": [], - "timeout_seconds": 0, - "timeouts": null, - "trigger": [ - { - "file_arrival": [], - "model": [], - "pause_status": "UNPAUSED", - "periodic": [ - { - "interval": 1, - "unit": "DAYS" - } - ], - "sql_condition": [], - "table_update": [] - } - ], - "triggers": [], - "url": "[DATABRICKS_URL]/#job/[FOO_ID]", - "usage_policy_id": null, - "webhook_notifications": [ - { - "on_duration_warning_threshold_exceeded": [], - "on_failure": [], - "on_start": [], - "on_streaming_backlog_exceeded": [], - "on_success": [] - } - ] - }, - "sensitive_attributes": [], - "private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxODAwMDAwMDAwMDAwLCJ1cGRhdGUiOjE4MDAwMDAwMDAwMDB9LCJzY2hlbWFfdmVyc2lvbiI6IjIifQ==" - } - ] - } - ], - "check_results": null -} diff --git a/acceptance/bundle/resources/jobs/update/out.test.toml b/acceptance/bundle/resources/jobs/update/out.test.toml index bf4f0e7d3c6..f7fafbcc731 100644 --- a/acceptance/bundle/resources/jobs/update/out.test.toml +++ b/acceptance/bundle/resources/jobs/update/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resources/jobs/update/script b/acceptance/bundle/resources/jobs/update/script index f1cded0ae20..3457ac99b25 100644 --- a/acceptance/bundle/resources/jobs/update/script +++ b/acceptance/bundle/resources/jobs/update/script @@ -3,14 +3,14 @@ mkdir -p .databricks trace $CLI bundle plan $CLI bundle plan -o json > .databricks/tmp.plan_create.json -nostamp < .databricks/tmp.plan_create.json > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +nostamp < .databricks/tmp.plan_create.json > out.plan_create.json $CLI bundle deploy $(readplanarg .databricks/tmp.plan_create.json) trace print_requests.py //jobs --nostamp > out.create.requests.json -print_state.py > out.state.$DATABRICKS_BUNDLE_ENGINE.json +print_state.py > out.state.json trace $CLI bundle plan trace $CLI bundle plan -o json > .databricks/tmp.plan_skip.json -nostamp < .databricks/tmp.plan_skip.json > out.plan_skip.$DATABRICKS_BUNDLE_ENGINE.json +nostamp < .databricks/tmp.plan_skip.json > out.plan_skip.json $CLI bundle deploy $(readplanarg .databricks/tmp.plan_skip.json) trace print_requests.py //jobs --nostamp @@ -19,7 +19,7 @@ title "Update trigger.periodic.unit and re-deploy" trace update_file.py databricks.yml DAYS HOURS trace $CLI bundle plan $CLI bundle plan -o json > .databricks/tmp.plan_update.json -nostamp < .databricks/tmp.plan_update.json > out.plan_update.$DATABRICKS_BUNDLE_ENGINE.json +nostamp < .databricks/tmp.plan_update.json > out.plan_update.json $CLI bundle deploy $(readplanarg .databricks/tmp.plan_update.json) trace print_requests.py //jobs --nostamp | jq 'del(.body.new_settings.run_as, .body.new_settings.webhook_notifications, .body.new_settings.email_notifications)' > out.update.requests.json diff --git a/acceptance/bundle/resources/jobs/update_single_node/out.plan_create.direct.json b/acceptance/bundle/resources/jobs/update_single_node/out.plan_create.json similarity index 100% rename from acceptance/bundle/resources/jobs/update_single_node/out.plan_create.direct.json rename to acceptance/bundle/resources/jobs/update_single_node/out.plan_create.json diff --git a/acceptance/bundle/resources/jobs/update_single_node/out.plan_create.terraform.json b/acceptance/bundle/resources/jobs/update_single_node/out.plan_create.terraform.json deleted file mode 100644 index 5a250db78de..00000000000 --- a/acceptance/bundle/resources/jobs/update_single_node/out.plan_create.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.foo": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/jobs/update_single_node/out.plan_skip.direct.json b/acceptance/bundle/resources/jobs/update_single_node/out.plan_skip.json similarity index 100% rename from acceptance/bundle/resources/jobs/update_single_node/out.plan_skip.direct.json rename to acceptance/bundle/resources/jobs/update_single_node/out.plan_skip.json diff --git a/acceptance/bundle/resources/jobs/update_single_node/out.plan_skip.terraform.json b/acceptance/bundle/resources/jobs/update_single_node/out.plan_skip.terraform.json deleted file mode 100644 index 7dbc48d7c39..00000000000 --- a/acceptance/bundle/resources/jobs/update_single_node/out.plan_skip.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.foo": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/resources/jobs/update_single_node/out.plan_update.direct.json b/acceptance/bundle/resources/jobs/update_single_node/out.plan_update.json similarity index 100% rename from acceptance/bundle/resources/jobs/update_single_node/out.plan_update.direct.json rename to acceptance/bundle/resources/jobs/update_single_node/out.plan_update.json diff --git a/acceptance/bundle/resources/jobs/update_single_node/out.plan_update.terraform.json b/acceptance/bundle/resources/jobs/update_single_node/out.plan_update.terraform.json deleted file mode 100644 index b5415d47a54..00000000000 --- a/acceptance/bundle/resources/jobs/update_single_node/out.plan_update.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.foo": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/jobs/update_single_node/out.test.toml b/acceptance/bundle/resources/jobs/update_single_node/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/jobs/update_single_node/out.test.toml +++ b/acceptance/bundle/resources/jobs/update_single_node/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/update_single_node/out.update.requests.direct.json b/acceptance/bundle/resources/jobs/update_single_node/out.update.requests.json similarity index 100% rename from acceptance/bundle/resources/jobs/update_single_node/out.update.requests.direct.json rename to acceptance/bundle/resources/jobs/update_single_node/out.update.requests.json diff --git a/acceptance/bundle/resources/jobs/update_single_node/out.update.requests.terraform.json b/acceptance/bundle/resources/jobs/update_single_node/out.update.requests.terraform.json deleted file mode 100644 index 3728e70da02..00000000000 --- a/acceptance/bundle/resources/jobs/update_single_node/out.update.requests.terraform.json +++ /dev/null @@ -1,48 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.2/jobs/reset", - "body": { - "job_id": [FOO_ID], - "new_settings": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "email_notifications": {}, - "format": "MULTI_TASK", - "job_clusters": [ - { - "job_cluster_key": "key", - "new_cluster": { - "custom_tags": { - "ResourceClass": "SingleNode" - }, - "num_workers": 0, - "spark_conf": { - "spark.databricks.cluster.profile": "singleNode", - "spark.master": "local[*]" - }, - "spark_version": "13.3.x-scala2.12" - } - } - ], - "max_concurrent_runs": 1, - "name": "foo", - "queue": { - "enabled": true - }, - "run_as": { - "user_name": "[USERNAME]" - }, - "trigger": { - "pause_status": "UNPAUSED", - "periodic": { - "interval": 1, - "unit": "HOURS" - } - }, - "webhook_notifications": {} - } - } -} diff --git a/acceptance/bundle/resources/jobs/update_single_node/script b/acceptance/bundle/resources/jobs/update_single_node/script index 3ad154998d2..5f0bb12ee55 100644 --- a/acceptance/bundle/resources/jobs/update_single_node/script +++ b/acceptance/bundle/resources/jobs/update_single_node/script @@ -1,16 +1,16 @@ trace $CLI bundle plan -$CLI bundle plan -o json | nostamp > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan_create.json trace $CLI bundle deploy -$CLI bundle plan -o json | nostamp > out.plan_skip.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan_skip.json trace print_requests.py //jobs > out.create.requests.txt --nostamp title "Update trigger.periodic.unit and re-deploy" trace update_file.py databricks.yml DAYS HOURS trace $CLI bundle plan -$CLI bundle plan -o json | nostamp > out.plan_update.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan_update.json trace $CLI bundle deploy -trace print_requests.py //jobs > out.update.requests.$DATABRICKS_BUNDLE_ENGINE.json --nostamp +trace print_requests.py //jobs > out.update.requests.json --nostamp trace $CLI bundle plan diff --git a/acceptance/bundle/resources/jobs/webhook-reorder-remote/out.plan.direct.json b/acceptance/bundle/resources/jobs/webhook-reorder-remote/out.plan.json similarity index 100% rename from acceptance/bundle/resources/jobs/webhook-reorder-remote/out.plan.direct.json rename to acceptance/bundle/resources/jobs/webhook-reorder-remote/out.plan.json diff --git a/acceptance/bundle/resources/jobs/webhook-reorder-remote/out.test.toml b/acceptance/bundle/resources/jobs/webhook-reorder-remote/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/jobs/webhook-reorder-remote/out.test.toml +++ b/acceptance/bundle/resources/jobs/webhook-reorder-remote/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/webhook-reorder-remote/output.txt b/acceptance/bundle/resources/jobs/webhook-reorder-remote/output.txt index bf3c6bd1e60..50c43c9cc70 100644 --- a/acceptance/bundle/resources/jobs/webhook-reorder-remote/output.txt +++ b/acceptance/bundle/resources/jobs/webhook-reorder-remote/output.txt @@ -5,7 +5,7 @@ create jobs.my_job Plan: 1 to add, 0 to change, 0 to delete, 0 unchanged Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... Created jobs.my_job -Files: 3 uploaded, 0 deleted +Files: 2 uploaded, 0 deleted Resources: 1 created, 0 changed, 0 deleted, 0 unchanged >>> [CLI] bundle plan diff --git a/acceptance/bundle/resources/jobs/webhook-reorder-remote/script b/acceptance/bundle/resources/jobs/webhook-reorder-remote/script index c0257db6330..64e56ce732e 100644 --- a/acceptance/bundle/resources/jobs/webhook-reorder-remote/script +++ b/acceptance/bundle/resources/jobs/webhook-reorder-remote/script @@ -14,6 +14,6 @@ EOF # The reordered remote must not produce a phantom diff: on_* lists are diffed by id. trace $CLI bundle plan -$CLI bundle plan -o json | nostamp | jq '.plan."resources.jobs.my_job".changes' > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp | jq '.plan."resources.jobs.my_job".changes' > out.plan.json trace print_requests.py //jobs --nostamp diff --git a/acceptance/bundle/resources/jobs/webhook-reorder-remote/test.toml b/acceptance/bundle/resources/jobs/webhook-reorder-remote/test.toml deleted file mode 100644 index dfe6b083737..00000000000 --- a/acceptance/bundle/resources/jobs/webhook-reorder-remote/test.toml +++ /dev/null @@ -1,2 +0,0 @@ -# The phantom-diff bug and the KeyedSlices fix are specific to the direct engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ['direct'] diff --git a/acceptance/bundle/resources/jobs/whole-block-overlap/out.plan.direct.json b/acceptance/bundle/resources/jobs/whole-block-overlap/out.plan.json similarity index 100% rename from acceptance/bundle/resources/jobs/whole-block-overlap/out.plan.direct.json rename to acceptance/bundle/resources/jobs/whole-block-overlap/out.plan.json diff --git a/acceptance/bundle/resources/jobs/whole-block-overlap/out.test.toml b/acceptance/bundle/resources/jobs/whole-block-overlap/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/jobs/whole-block-overlap/out.test.toml +++ b/acceptance/bundle/resources/jobs/whole-block-overlap/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/jobs/whole-block-overlap/script b/acceptance/bundle/resources/jobs/whole-block-overlap/script index c9f858bba49..752824f00c8 100644 --- a/acceptance/bundle/resources/jobs/whole-block-overlap/script +++ b/acceptance/bundle/resources/jobs/whole-block-overlap/script @@ -18,4 +18,4 @@ EOF # carries BOTH the whole "schedule" block and the "schedule.timezone_id" leaf # instead of merging them into leaves. trace $CLI bundle plan -$CLI bundle plan -o json | nostamp > out.plan.direct.json +$CLI bundle plan -o json | nostamp > out.plan.json diff --git a/acceptance/bundle/resources/jobs/whole-block-overlap/test.toml b/acceptance/bundle/resources/jobs/whole-block-overlap/test.toml index 4606dbf9d33..e31bf48ee40 100644 --- a/acceptance/bundle/resources/jobs/whole-block-overlap/test.toml +++ b/acceptance/bundle/resources/jobs/whole-block-overlap/test.toml @@ -1,6 +1,5 @@ # Direct-only: the overlapping parent+child entries are a direct-engine changes-map # artifact (terraform emits no per-field changes). -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] RecordRequests = false Ignore = [".databricks"] diff --git a/acceptance/bundle/resources/mcp_services/basic/out.test.toml b/acceptance/bundle/resources/mcp_services/basic/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/mcp_services/basic/out.test.toml +++ b/acceptance/bundle/resources/mcp_services/basic/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/mcp_services/lifecycle/out.test.toml b/acceptance/bundle/resources/mcp_services/lifecycle/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/mcp_services/lifecycle/out.test.toml +++ b/acceptance/bundle/resources/mcp_services/lifecycle/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/mcp_services/remote-delete/out.test.toml b/acceptance/bundle/resources/mcp_services/remote-delete/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/mcp_services/remote-delete/out.test.toml +++ b/acceptance/bundle/resources/mcp_services/remote-delete/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/mcp_services/test.toml b/acceptance/bundle/resources/mcp_services/test.toml index 90109467fba..e2135896127 100644 --- a/acceptance/bundle/resources/mcp_services/test.toml +++ b/acceptance/bundle/resources/mcp_services/test.toml @@ -1,6 +1,5 @@ # AI Gateway securables are only deployable via the direct deployment engine # (there is no Terraform provider path for them in bundles). -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # Lifecycle tests also run against a real workspace. Tests that inspect the # recorded request stream (e.g. basic) can't run on cloud and override this. diff --git a/acceptance/bundle/resources/model_provider_services/basic/out.test.toml b/acceptance/bundle/resources/model_provider_services/basic/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/model_provider_services/basic/out.test.toml +++ b/acceptance/bundle/resources/model_provider_services/basic/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_provider_services/lifecycle/out.test.toml b/acceptance/bundle/resources/model_provider_services/lifecycle/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/model_provider_services/lifecycle/out.test.toml +++ b/acceptance/bundle/resources/model_provider_services/lifecycle/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_provider_services/remote-delete/out.test.toml b/acceptance/bundle/resources/model_provider_services/remote-delete/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/model_provider_services/remote-delete/out.test.toml +++ b/acceptance/bundle/resources/model_provider_services/remote-delete/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_provider_services/test.toml b/acceptance/bundle/resources/model_provider_services/test.toml index 90109467fba..e2135896127 100644 --- a/acceptance/bundle/resources/model_provider_services/test.toml +++ b/acceptance/bundle/resources/model_provider_services/test.toml @@ -1,6 +1,5 @@ # AI Gateway securables are only deployable via the direct deployment engine # (there is no Terraform provider path for them in bundles). -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # Lifecycle tests also run against a real workspace. Tests that inspect the # recorded request stream (e.g. basic) can't run on cloud and override this. diff --git a/acceptance/bundle/resources/model_services/basic/out.test.toml b/acceptance/bundle/resources/model_services/basic/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/model_services/basic/out.test.toml +++ b/acceptance/bundle/resources/model_services/basic/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_services/lifecycle/out.test.toml b/acceptance/bundle/resources/model_services/lifecycle/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/model_services/lifecycle/out.test.toml +++ b/acceptance/bundle/resources/model_services/lifecycle/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_services/remote-delete/out.test.toml b/acceptance/bundle/resources/model_services/remote-delete/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/model_services/remote-delete/out.test.toml +++ b/acceptance/bundle/resources/model_services/remote-delete/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_services/test.toml b/acceptance/bundle/resources/model_services/test.toml index 90109467fba..e2135896127 100644 --- a/acceptance/bundle/resources/model_services/test.toml +++ b/acceptance/bundle/resources/model_services/test.toml @@ -1,6 +1,5 @@ # AI Gateway securables are only deployable via the direct deployment engine # (there is no Terraform provider path for them in bundles). -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # Lifecycle tests also run against a real workspace. Tests that inspect the # recorded request stream (e.g. basic) can't run on cloud and override this. diff --git a/acceptance/bundle/resources/model_serving_endpoints/basic/out.first-plan.terraform.txt b/acceptance/bundle/resources/model_serving_endpoints/basic/out.first-plan.terraform.txt deleted file mode 100644 index 8172d95c5f4..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/basic/out.first-plan.terraform.txt +++ /dev/null @@ -1,3 +0,0 @@ -json.cli_version = "[CLI_VERSION]"; -json.plan.resources.model_serving_endpoints.my_endpoint.action = "create"; -json.plan.resources.model_serving_endpoints.my_endpoint.permissions.action = "create"; diff --git a/acceptance/bundle/resources/model_serving_endpoints/basic/out.first-plan.direct.txt b/acceptance/bundle/resources/model_serving_endpoints/basic/out.first-plan.txt similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/basic/out.first-plan.direct.txt rename to acceptance/bundle/resources/model_serving_endpoints/basic/out.first-plan.txt diff --git a/acceptance/bundle/resources/model_serving_endpoints/basic/out.second-plan.terraform.txt b/acceptance/bundle/resources/model_serving_endpoints/basic/out.second-plan.terraform.txt deleted file mode 100644 index d3cd5fc605b..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/basic/out.second-plan.terraform.txt +++ /dev/null @@ -1,3 +0,0 @@ -json.cli_version = "[CLI_VERSION]"; -json.plan.resources.model_serving_endpoints.my_endpoint.action = "recreate"; -json.plan.resources.model_serving_endpoints.my_endpoint.permissions.action = "recreate"; diff --git a/acceptance/bundle/resources/model_serving_endpoints/basic/out.second-plan.direct.txt b/acceptance/bundle/resources/model_serving_endpoints/basic/out.second-plan.txt similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/basic/out.second-plan.direct.txt rename to acceptance/bundle/resources/model_serving_endpoints/basic/out.second-plan.txt diff --git a/acceptance/bundle/resources/model_serving_endpoints/basic/out.second-requests.terraform.txt b/acceptance/bundle/resources/model_serving_endpoints/basic/out.second-requests.terraform.txt deleted file mode 100644 index aba548c4913..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/basic/out.second-requests.terraform.txt +++ /dev/null @@ -1,15 +0,0 @@ -json[0].method = "PUT"; -json[0].path = "/api/2.0/permissions/serving-endpoints/[ENDPOINT_ID_1]"; -json[0].body.access_control_list[0].permission_level = "CAN_MANAGE"; -json[0].body.access_control_list[0].user_name = "[USERNAME]"; -json[1].method = "DELETE"; -json[1].path = "/api/2.0/serving-endpoints/[ENDPOINT_NAME_1]"; -json[2].method = "POST"; -json[2].path = "/api/2.0/serving-endpoints"; -json[2].body.name = "[ENDPOINT_NAME_2]"; -json[3].method = "PUT"; -json[3].path = "/api/2.0/permissions/serving-endpoints/[ENDPOINT_ID_2]"; -json[3].body.access_control_list[0].permission_level = "CAN_MANAGE"; -json[3].body.access_control_list[0].service_principal_name = "[USERNAME]"; -json[3].body.access_control_list[1].permission_level = "CAN_VIEW"; -json[3].body.access_control_list[1].user_name = "deco-test-user@databricks.com"; diff --git a/acceptance/bundle/resources/model_serving_endpoints/basic/out.second-requests.direct.txt b/acceptance/bundle/resources/model_serving_endpoints/basic/out.second-requests.txt similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/basic/out.second-requests.direct.txt rename to acceptance/bundle/resources/model_serving_endpoints/basic/out.second-requests.txt diff --git a/acceptance/bundle/resources/model_serving_endpoints/basic/out.test.toml b/acceptance/bundle/resources/model_serving_endpoints/basic/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/basic/out.test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/basic/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/basic/script b/acceptance/bundle/resources/model_serving_endpoints/basic/script index 18ccf9f62f6..c12cb1bd8f2 100755 --- a/acceptance/bundle/resources/model_serving_endpoints/basic/script +++ b/acceptance/bundle/resources/model_serving_endpoints/basic/script @@ -14,7 +14,7 @@ trap cleanup EXIT # bundle/direct/dresources/permissions.go), so sorting keeps the plan golden # stable across runs. Same approach as secret_scopes/basic and the requests # sorting below. -trace $CLI bundle plan -o json | nostamp | gron.py --sort-arrays __embed__ > out.first-plan.$DATABRICKS_BUNDLE_ENGINE.txt +trace $CLI bundle plan -o json | nostamp | gron.py --sort-arrays __embed__ > out.first-plan.txt trace $CLI bundle deploy -qq # Sort access_control_list: the terraform engine stores it as a set whose order # depends on the (unmasked) principal value, so it differs between the local fake @@ -33,9 +33,9 @@ echo "$get_output" | jq '{name, creator}' export ENDPOINT_NAME="test-endpoint-$UNIQUE_NAME-2" envsubst < databricks.yml.tmpl > databricks.yml -trace $CLI bundle plan -o json | nostamp | gron.py --sort-arrays __embed__ > out.second-plan.$DATABRICKS_BUNDLE_ENGINE.txt +trace $CLI bundle plan -o json | nostamp | gron.py --sort-arrays __embed__ > out.second-plan.txt trace $CLI bundle deploy -qq -print_requests.py //serving-endpoints | gron.py --sort-arrays access_control_list > out.second-requests.$DATABRICKS_BUNDLE_ENGINE.txt +print_requests.py //serving-endpoints | gron.py --sort-arrays access_control_list > out.second-requests.txt add_repl "$ENDPOINT_NAME" ENDPOINT_NAME_2 diff --git a/acceptance/bundle/resources/model_serving_endpoints/basic/test.toml b/acceptance/bundle/resources/model_serving_endpoints/basic/test.toml index 0cf60ac5ca4..0d8ebd3ecec 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/basic/test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/basic/test.toml @@ -5,5 +5,3 @@ RecordRequests = true # auto-added CAN_MANAGE ACL serializes as service_principal_name. Make the # local fake report the deployer as a service principal to match. IsServicePrincipal = true - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/drift/recreated_same_name/out.test.toml b/acceptance/bundle/resources/model_serving_endpoints/drift/recreated_same_name/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/drift/recreated_same_name/out.test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/drift/recreated_same_name/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/drift/recreated_same_name/test.toml b/acceptance/bundle/resources/model_serving_endpoints/drift/recreated_same_name/test.toml index 75dd2a1a059..0423113d9fa 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/drift/recreated_same_name/test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/drift/recreated_same_name/test.toml @@ -2,5 +2,3 @@ Badness = "After deleting and recreating a model serving endpoint remotely with Cloud = true RecordRequests = false - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/drift/telemetry_config_unmanaged/out.test.toml b/acceptance/bundle/resources/model_serving_endpoints/drift/telemetry_config_unmanaged/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/drift/telemetry_config_unmanaged/out.test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/drift/telemetry_config_unmanaged/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/drift/telemetry_config_unmanaged/test.toml b/acceptance/bundle/resources/model_serving_endpoints/drift/telemetry_config_unmanaged/test.toml index ec0e9c5ca86..d6265602137 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/drift/telemetry_config_unmanaged/test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/drift/telemetry_config_unmanaged/test.toml @@ -1,4 +1,3 @@ RecordRequests = true # Telemetry classification is direct-engine-specific. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/drift/telemetry_config_with_config_update/out.test.toml b/acceptance/bundle/resources/model_serving_endpoints/drift/telemetry_config_with_config_update/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/drift/telemetry_config_with_config_update/out.test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/drift/telemetry_config_with_config_update/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/drift/telemetry_config_with_config_update/test.toml b/acceptance/bundle/resources/model_serving_endpoints/drift/telemetry_config_with_config_update/test.toml index 49a9063424b..ef38bf79289 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/drift/telemetry_config_with_config_update/test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/drift/telemetry_config_with_config_update/test.toml @@ -1,4 +1,3 @@ RecordRequests = true # Telemetry updates are direct-engine-specific. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/drift/write_only/out.test.toml b/acceptance/bundle/resources/model_serving_endpoints/drift/write_only/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/drift/write_only/out.test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/drift/write_only/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/drift/write_only/test.toml b/acceptance/bundle/resources/model_serving_endpoints/drift/write_only/test.toml index ebb5ea78eed..298d28d13a5 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/drift/write_only/test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/drift/write_only/test.toml @@ -2,4 +2,3 @@ RecordRequests = true # Scope this regression to the direct engine where the classification lives; # terraform models these write-only fields differently. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/out.first-plan.direct.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/out.first-plan.json similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/out.first-plan.direct.json rename to acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/out.first-plan.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/out.first-plan.terraform.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/out.first-plan.terraform.json deleted file mode 100644 index 547e8b9d975..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/out.first-plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.model_serving_endpoints.test_endpoint": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/out.second-plan.direct.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/out.second-plan.json similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/out.second-plan.direct.json rename to acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/out.second-plan.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/out.second-plan.terraform.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/out.second-plan.terraform.json deleted file mode 100644 index 63d50954dc3..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/out.second-plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.model_serving_endpoints.test_endpoint": { - "action": "recreate" - } - } -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/out.test.toml b/acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/out.test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/script b/acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/script index d4cc67d38b7..031c7b0bcdb 100755 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/script +++ b/acceptance/bundle/resources/model_serving_endpoints/recreate/catalog-name/script @@ -6,7 +6,7 @@ cleanup() { } trap cleanup EXIT -trace $CLI bundle plan -o json | nostamp > out.first-plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.first-plan.json trace $CLI bundle deploy trace print_requests.py //serving-endpoints @@ -16,7 +16,7 @@ add_repl "$ENDPOINT_ID" ORIGINAL_ENDPOINT_ID trace $CLI serving-endpoints get "${ENDPOINT_ID}" | jq '.config.auto_capture_config.catalog_name' trace update_file.py databricks.yml "catalog_name: main" "catalog_name: other_catalog" -trace $CLI bundle plan -o json | nostamp > out.second-plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.second-plan.json trace $CLI bundle deploy trace print_requests.py //serving-endpoints diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/out.first-plan.direct.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/out.first-plan.json similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/out.first-plan.direct.json rename to acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/out.first-plan.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/out.first-plan.terraform.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/out.first-plan.terraform.json deleted file mode 100644 index 547e8b9d975..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/out.first-plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.model_serving_endpoints.test_endpoint": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/out.second-plan.direct.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/out.second-plan.json similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/out.second-plan.direct.json rename to acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/out.second-plan.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/out.second-plan.terraform.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/out.second-plan.terraform.json deleted file mode 100644 index 63d50954dc3..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/out.second-plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.model_serving_endpoints.test_endpoint": { - "action": "recreate" - } - } -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/out.test.toml b/acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/out.test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/script b/acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/script index d919dd277f4..2d6d8e233a7 100755 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/script +++ b/acceptance/bundle/resources/model_serving_endpoints/recreate/name-change/script @@ -6,7 +6,7 @@ cleanup() { } trap cleanup EXIT -trace $CLI bundle plan -o json | nostamp > out.first-plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.first-plan.json trace $CLI bundle deploy trace print_requests.py //serving-endpoints @@ -16,7 +16,7 @@ add_repl "$ENDPOINT_ID" ORIGINAL_ENDPOINT_ID trace $CLI serving-endpoints get "${ENDPOINT_ID}" | jq '.name' trace update_file.py databricks.yml "name: test-endpoint-$UNIQUE_NAME" "name: test-endpoint-2-$UNIQUE_NAME" -trace $CLI bundle plan -o json | nostamp > out.second-plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.second-plan.json trace $CLI bundle deploy trace print_requests.py //serving-endpoints diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.first-plan.direct.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.first-plan.json similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.first-plan.direct.json rename to acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.first-plan.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.first-plan.terraform.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.first-plan.terraform.json deleted file mode 100644 index 547e8b9d975..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.first-plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.model_serving_endpoints.test_endpoint": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.first-requests.direct.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.first-requests.json similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.first-requests.direct.json rename to acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.first-requests.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.first-requests.terraform.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.first-requests.terraform.json deleted file mode 100644 index 95e359ba4ee..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.first-requests.terraform.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/serving-endpoints", - "body": { - "config": { - "served_entities": [ - { - "entity_name": "system.ai.llama_v3_2_1b_instruct", - "entity_version": "1", - "name": "llama", - "scale_to_zero_enabled": true, - "workload_size": "Small" - } - ] - }, - "name": "[ORIGINAL_ENDPOINT_ID]" - } -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.second-plan.direct.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.second-plan.json similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.second-plan.direct.json rename to acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.second-plan.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.second-plan.terraform.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.second-plan.terraform.json deleted file mode 100644 index 63d50954dc3..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.second-plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.model_serving_endpoints.test_endpoint": { - "action": "recreate" - } - } -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.test.toml b/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/script b/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/script index c8fbf25bd45..ad983a61529 100755 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/script +++ b/acceptance/bundle/resources/model_serving_endpoints/recreate/route-optimized/script @@ -6,17 +6,17 @@ cleanup() { } trap cleanup EXIT -trace $CLI bundle plan -o json | nostamp > out.first-plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.first-plan.json trace $CLI bundle deploy ENDPOINT_ID=$($CLI bundle summary -o json | jq -r '.resources.model_serving_endpoints.test_endpoint.id') add_repl "$ENDPOINT_ID" ORIGINAL_ENDPOINT_ID trace $CLI serving-endpoints get "${ENDPOINT_ID}" | jq '{route_optimized, id}' > out.first-get.json -print_requests.py //serving-endpoints > out.first-requests.$DATABRICKS_BUNDLE_ENGINE.json +print_requests.py //serving-endpoints > out.first-requests.json trace update_file.py databricks.yml "route_optimized: false" "route_optimized: true" -trace $CLI bundle plan -o json | nostamp > out.second-plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.second-plan.json trace $CLI bundle deploy trace print_requests.py //serving-endpoints diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/out.first-plan.direct.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/out.first-plan.json similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/out.first-plan.direct.json rename to acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/out.first-plan.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/out.first-plan.terraform.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/out.first-plan.terraform.json deleted file mode 100644 index 547e8b9d975..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/out.first-plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.model_serving_endpoints.test_endpoint": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/out.second-plan.direct.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/out.second-plan.json similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/out.second-plan.direct.json rename to acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/out.second-plan.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/out.second-plan.terraform.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/out.second-plan.terraform.json deleted file mode 100644 index 63d50954dc3..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/out.second-plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.model_serving_endpoints.test_endpoint": { - "action": "recreate" - } - } -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/out.test.toml b/acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/out.test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/script b/acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/script index e866e95b47c..eee4d6eb83f 100755 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/script +++ b/acceptance/bundle/resources/model_serving_endpoints/recreate/schema-name/script @@ -6,7 +6,7 @@ cleanup() { } trap cleanup EXIT -trace $CLI bundle plan -o json | nostamp > out.first-plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.first-plan.json trace $CLI bundle deploy trace print_requests.py //serving-endpoints @@ -16,7 +16,7 @@ add_repl "$ENDPOINT_ID" ORIGINAL_ENDPOINT_ID trace $CLI serving-endpoints get "${ENDPOINT_ID}" | jq '.config.auto_capture_config.schema_name' trace update_file.py databricks.yml "schema_name: default" "schema_name: other_schema" -trace $CLI bundle plan -o json | nostamp > out.second-plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.second-plan.json trace $CLI bundle deploy trace print_requests.py //serving-endpoints diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/out.first-plan.direct.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/out.first-plan.json similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/out.first-plan.direct.json rename to acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/out.first-plan.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/out.first-plan.terraform.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/out.first-plan.terraform.json deleted file mode 100644 index 547e8b9d975..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/out.first-plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.model_serving_endpoints.test_endpoint": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/out.second-plan.direct.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/out.second-plan.json similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/out.second-plan.direct.json rename to acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/out.second-plan.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/out.second-plan.terraform.json b/acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/out.second-plan.terraform.json deleted file mode 100644 index 63d50954dc3..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/out.second-plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.model_serving_endpoints.test_endpoint": { - "action": "recreate" - } - } -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/out.test.toml b/acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/out.test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/script b/acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/script index fe8455252a1..b2b596802c7 100755 --- a/acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/script +++ b/acceptance/bundle/resources/model_serving_endpoints/recreate/table-prefix/script @@ -6,7 +6,7 @@ cleanup() { } trap cleanup EXIT -trace $CLI bundle plan -o json | nostamp > out.first-plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.first-plan.json trace $CLI bundle deploy trace print_requests.py //serving-endpoints @@ -16,7 +16,7 @@ add_repl "$ENDPOINT_ID" ORIGINAL_ENDPOINT_ID trace $CLI serving-endpoints get "${ENDPOINT_ID}" | jq '.config.auto_capture_config.table_name_prefix' trace update_file.py databricks.yml "table_name_prefix: my_table" "table_name_prefix: other_table" -trace $CLI bundle plan -o json | nostamp > out.second-plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.second-plan.json trace $CLI bundle deploy trace print_requests.py //serving-endpoints diff --git a/acceptance/bundle/resources/model_serving_endpoints/running-endpoint/out.plan.terraform.txt b/acceptance/bundle/resources/model_serving_endpoints/running-endpoint/out.plan.terraform.txt deleted file mode 100644 index d9950b7efb0..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/running-endpoint/out.plan.terraform.txt +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.model_serving_endpoints.my_endpoint": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/running-endpoint/out.plan.direct.txt b/acceptance/bundle/resources/model_serving_endpoints/running-endpoint/out.plan.txt similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/running-endpoint/out.plan.direct.txt rename to acceptance/bundle/resources/model_serving_endpoints/running-endpoint/out.plan.txt diff --git a/acceptance/bundle/resources/model_serving_endpoints/running-endpoint/out.test.toml b/acceptance/bundle/resources/model_serving_endpoints/running-endpoint/out.test.toml index 2dd1ac4d727..7c3dd4f02ef 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/running-endpoint/out.test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/running-endpoint/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudSlow = true CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/running-endpoint/script b/acceptance/bundle/resources/model_serving_endpoints/running-endpoint/script index 170908e58b1..93eb53d69a7 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/running-endpoint/script +++ b/acceptance/bundle/resources/model_serving_endpoints/running-endpoint/script @@ -8,7 +8,7 @@ cleanup() { } trap cleanup EXIT -trace $CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.txt +trace $CLI bundle plan -o json | nostamp > out.plan.txt trace $CLI bundle deploy trace print_requests.py //serving-endpoints diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/ai-gateway/out.plan.direct.json b/acceptance/bundle/resources/model_serving_endpoints/update/ai-gateway/out.plan.json similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/update/ai-gateway/out.plan.direct.json rename to acceptance/bundle/resources/model_serving_endpoints/update/ai-gateway/out.plan.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/ai-gateway/out.plan.terraform.json b/acceptance/bundle/resources/model_serving_endpoints/update/ai-gateway/out.plan.terraform.json deleted file mode 100644 index 4b52e5c5b22..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/update/ai-gateway/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.model_serving_endpoints.test_endpoint": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/ai-gateway/out.test.toml b/acceptance/bundle/resources/model_serving_endpoints/update/ai-gateway/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/update/ai-gateway/out.test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/update/ai-gateway/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/ai-gateway/script b/acceptance/bundle/resources/model_serving_endpoints/update/ai-gateway/script index 8f85f256593..4caa4883ead 100755 --- a/acceptance/bundle/resources/model_serving_endpoints/update/ai-gateway/script +++ b/acceptance/bundle/resources/model_serving_endpoints/update/ai-gateway/script @@ -15,7 +15,7 @@ trace $CLI serving-endpoints get "${ENDPOINT_ID}" | jq '.ai_gateway' trace update_file.py databricks.yml 'catalog_name: "first-inference-catalog"' 'catalog_name: "second-inference-catalog"' -trace $CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan.json trace $CLI bundle deploy trace print_requests.py //serving-endpoints diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/both_gateway_and_tags/out.plan.direct.json b/acceptance/bundle/resources/model_serving_endpoints/update/both_gateway_and_tags/out.plan.json similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/update/both_gateway_and_tags/out.plan.direct.json rename to acceptance/bundle/resources/model_serving_endpoints/update/both_gateway_and_tags/out.plan.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/both_gateway_and_tags/out.plan.terraform.json b/acceptance/bundle/resources/model_serving_endpoints/update/both_gateway_and_tags/out.plan.terraform.json deleted file mode 100644 index 4b52e5c5b22..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/update/both_gateway_and_tags/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.model_serving_endpoints.test_endpoint": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/both_gateway_and_tags/out.test.toml b/acceptance/bundle/resources/model_serving_endpoints/update/both_gateway_and_tags/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/update/both_gateway_and_tags/out.test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/update/both_gateway_and_tags/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/both_gateway_and_tags/script b/acceptance/bundle/resources/model_serving_endpoints/update/both_gateway_and_tags/script index 46fcbbe4dac..cba0af905d5 100755 --- a/acceptance/bundle/resources/model_serving_endpoints/update/both_gateway_and_tags/script +++ b/acceptance/bundle/resources/model_serving_endpoints/update/both_gateway_and_tags/script @@ -17,7 +17,7 @@ trace $CLI serving-endpoints get "${ENDPOINT_ID}" | jq '.config' trace update_file.py databricks.yml "value: my-team-one" "value: my-team-two" trace update_file.py databricks.yml 'catalog_name: "first-inference-catalog"' 'catalog_name: "second-inference-catalog"' -trace $CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan.json trace $CLI bundle deploy trace print_requests.py //serving-endpoints diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/config/out.plan.direct.json b/acceptance/bundle/resources/model_serving_endpoints/update/config/out.plan.json similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/update/config/out.plan.direct.json rename to acceptance/bundle/resources/model_serving_endpoints/update/config/out.plan.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/config/out.plan.terraform.json b/acceptance/bundle/resources/model_serving_endpoints/update/config/out.plan.terraform.json deleted file mode 100644 index 4b52e5c5b22..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/update/config/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.model_serving_endpoints.test_endpoint": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/config/out.test.toml b/acceptance/bundle/resources/model_serving_endpoints/update/config/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/update/config/out.test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/update/config/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/config/script b/acceptance/bundle/resources/model_serving_endpoints/update/config/script index 0a80ec4b0ff..844db16bd7b 100755 --- a/acceptance/bundle/resources/model_serving_endpoints/update/config/script +++ b/acceptance/bundle/resources/model_serving_endpoints/update/config/script @@ -15,7 +15,7 @@ trace $CLI serving-endpoints get "${ENDPOINT_ID}" | jq '.config' trace update_file.py databricks.yml "name: gpt-4o-mini" "name: gpt-5o-mini" -trace $CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan.json trace $CLI bundle deploy trace print_requests.py //serving-endpoints diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.get_email_notifications.direct.json b/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.get_email_notifications.json similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.get_email_notifications.direct.json rename to acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.get_email_notifications.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.get_email_notifications.terraform.json b/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.get_email_notifications.terraform.json deleted file mode 100644 index 76b5ef08c2c..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.get_email_notifications.terraform.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "on_update_success": [ - "user1@example.com" - ] -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.plan.direct.json b/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.plan.json similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.plan.direct.json rename to acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.plan.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.plan.terraform.json b/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.plan.terraform.json deleted file mode 100644 index 4b52e5c5b22..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.model_serving_endpoints.test_endpoint": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.requests.direct.json b/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.requests.json similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.requests.direct.json rename to acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.requests.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.requests.terraform.json b/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.requests.terraform.json deleted file mode 100644 index 01f25716268..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.requests.terraform.json +++ /dev/null @@ -1,27 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/serving-endpoints", - "body": { - "config": { - "served_entities": [ - { - "external_model": { - "name": "gpt-4o-mini", - "openai_config": { - "openai_api_key": "{{secrets/test-scope/openai-key}}" - }, - "provider": "openai", - "task": "llm/v1/chat" - }, - "name": "prod" - } - ] - }, - "email_notifications": { - "on_update_success": [ - "user1@example.com" - ] - }, - "name": "[ENDPOINT_ID]" - } -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.test.toml b/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/script b/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/script index ec9671e3277..1219260f85e 100755 --- a/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/script +++ b/acceptance/bundle/resources/model_serving_endpoints/update/email-notifications/script @@ -16,10 +16,10 @@ trace $CLI serving-endpoints get "${ENDPOINT_ID}" | jq '.email_notifications' # Update email_notifications - change the email address trace update_file.py databricks.yml "user1@example.com" "user2@example.com" -trace $CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan.json trace $CLI bundle deploy title "There a bug in TF where it does not actually update the email notifications for a serving endpoint." -trace print_requests.py //serving-endpoints > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //serving-endpoints > out.requests.json -trace $CLI serving-endpoints get "${ENDPOINT_ID}" | jq '.email_notifications' > out.get_email_notifications.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI serving-endpoints get "${ENDPOINT_ID}" | jq '.email_notifications' > out.get_email_notifications.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/tags/out.plan.direct.json b/acceptance/bundle/resources/model_serving_endpoints/update/tags/out.plan.json similarity index 100% rename from acceptance/bundle/resources/model_serving_endpoints/update/tags/out.plan.direct.json rename to acceptance/bundle/resources/model_serving_endpoints/update/tags/out.plan.json diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/tags/out.plan.terraform.json b/acceptance/bundle/resources/model_serving_endpoints/update/tags/out.plan.terraform.json deleted file mode 100644 index 4b52e5c5b22..00000000000 --- a/acceptance/bundle/resources/model_serving_endpoints/update/tags/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.model_serving_endpoints.test_endpoint": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/tags/out.test.toml b/acceptance/bundle/resources/model_serving_endpoints/update/tags/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/model_serving_endpoints/update/tags/out.test.toml +++ b/acceptance/bundle/resources/model_serving_endpoints/update/tags/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/model_serving_endpoints/update/tags/script b/acceptance/bundle/resources/model_serving_endpoints/update/tags/script index 725f2ef9a5c..62b47ed18e2 100755 --- a/acceptance/bundle/resources/model_serving_endpoints/update/tags/script +++ b/acceptance/bundle/resources/model_serving_endpoints/update/tags/script @@ -15,7 +15,7 @@ trace $CLI serving-endpoints get "${ENDPOINT_ID}" | jq '.tags' trace update_file.py databricks.yml "value: my-team-one" "value: my-team-two" -trace $CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan.json trace $CLI bundle deploy trace print_requests.py //serving-endpoints diff --git a/acceptance/bundle/resources/models/basic/out.plan_update_tag.direct.txt b/acceptance/bundle/resources/models/basic/out.plan_update_tag.direct.txt deleted file mode 100644 index c54c9d511c0..00000000000 --- a/acceptance/bundle/resources/models/basic/out.plan_update_tag.direct.txt +++ /dev/null @@ -1 +0,0 @@ -Plan: 0 to add, 0 to change, 0 to delete, 1 unchanged diff --git a/acceptance/bundle/resources/models/basic/out.plan_update_tag.terraform.txt b/acceptance/bundle/resources/models/basic/out.plan_update_tag.terraform.txt deleted file mode 100644 index 2949936e687..00000000000 --- a/acceptance/bundle/resources/models/basic/out.plan_update_tag.terraform.txt +++ /dev/null @@ -1,3 +0,0 @@ -update models.my_model - -Plan: 0 to add, 1 to change, 0 to delete, 0 unchanged diff --git a/acceptance/bundle/resources/experiments/basic/out.plan.direct.txt b/acceptance/bundle/resources/models/basic/out.plan_update_tag.txt similarity index 100% rename from acceptance/bundle/resources/experiments/basic/out.plan.direct.txt rename to acceptance/bundle/resources/models/basic/out.plan_update_tag.txt diff --git a/acceptance/bundle/resources/models/basic/out.test.toml b/acceptance/bundle/resources/models/basic/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/models/basic/out.test.toml +++ b/acceptance/bundle/resources/models/basic/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/models/basic/script b/acceptance/bundle/resources/models/basic/script index f14cc0a2261..3752a9c2715 100644 --- a/acceptance/bundle/resources/models/basic/script +++ b/acceptance/bundle/resources/models/basic/script @@ -27,6 +27,6 @@ trace $CLI model-registry get-model $MODEL_NAME | jq '.registered_model_databric title "add a new tag, this should be a no-op; terraform does make an update request but since update request has no tags in it, it does nothing; direct skips request completely" envsubst < templates/two_tag.tmpl > databricks.yml -trace $CLI bundle plan > out.plan_update_tag.$DATABRICKS_BUNDLE_ENGINE.txt +trace $CLI bundle plan > out.plan_update_tag.txt trace $CLI bundle deploy -qq trace $CLI model-registry get-model $MODEL_NAME | jq '.registered_model_databricks | {name, description, tags}' diff --git a/acceptance/bundle/resources/models/empty-name/out.deploy.terraform.txt b/acceptance/bundle/resources/models/empty-name/out.deploy.terraform.txt deleted file mode 100644 index 8f8d5d389df..00000000000 --- a/acceptance/bundle/resources/models/empty-name/out.deploy.terraform.txt +++ /dev/null @@ -1,14 +0,0 @@ - ->>> musterr [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/model-empty-name-[UNIQUE_NAME]/default/files... -Error: terraform apply: exit status 1 - -Error: cannot create mlflow model: Got an invalid name ''. Registered Model names cannot be empty strings. - - with databricks_mlflow_model.mymodel, - on bundle.tf.json line 17, in resource.databricks_mlflow_model.mymodel: - 17: } - - - -Files: 5 uploaded, 0 deleted diff --git a/acceptance/bundle/resources/models/empty-name/out.deploy.direct.txt b/acceptance/bundle/resources/models/empty-name/out.deploy.txt similarity index 100% rename from acceptance/bundle/resources/models/empty-name/out.deploy.direct.txt rename to acceptance/bundle/resources/models/empty-name/out.deploy.txt diff --git a/acceptance/bundle/resources/models/empty-name/out.test.toml b/acceptance/bundle/resources/models/empty-name/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/models/empty-name/out.test.toml +++ b/acceptance/bundle/resources/models/empty-name/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/models/empty-name/script b/acceptance/bundle/resources/models/empty-name/script index 0336c9c6ca0..aae85b29c38 100644 --- a/acceptance/bundle/resources/models/empty-name/script +++ b/acceptance/bundle/resources/models/empty-name/script @@ -4,4 +4,4 @@ envsubst < databricks.yml.tmpl > databricks.yml # Both engines reach the create call, but terraform wraps the message in its own # output, so the goldens are per-engine. -trace musterr $CLI bundle deploy &> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt +trace musterr $CLI bundle deploy &> out.deploy.txt diff --git a/acceptance/bundle/resources/models/readplan-permissions/out.test.toml b/acceptance/bundle/resources/models/readplan-permissions/out.test.toml index dd03baaabb6..f7fafbcc731 100644 --- a/acceptance/bundle/resources/models/readplan-permissions/out.test.toml +++ b/acceptance/bundle/resources/models/readplan-permissions/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resources/models/readplan-permissions/test.toml b/acceptance/bundle/resources/models/readplan-permissions/test.toml index 6a843fa06d4..454cb9038c2 100644 --- a/acceptance/bundle/resources/models/readplan-permissions/test.toml +++ b/acceptance/bundle/resources/models/readplan-permissions/test.toml @@ -1,5 +1,4 @@ Cloud = false Ignore = [".databricks", "tmp.plan.json"] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/resources/permissions/_script b/acceptance/bundle/resources/permissions/_script index 13d76538a40..7ef1a088d24 100644 --- a/acceptance/bundle/resources/permissions/_script +++ b/acceptance/bundle/resources/permissions/_script @@ -1,7 +1,7 @@ trace $CLI bundle validate -o json | nostamp.py | jq .resources.$RESOURCE.foo.permissions rm "$OUT_REQUESTS" -$CLI bundle plan -o json | nostamp.py > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp.py > out.plan.json print_requests() { jq -c < "$OUT_REQUESTS" | jq 'select(.method != "GET" and (.path | contains("permissions")) and (.path | contains("/api/2.0/bundle") | not))' @@ -10,7 +10,7 @@ print_requests() { rm "$OUT_REQUESTS" trace $CLI bundle deploy -print_requests > out.requests.deploy.$DATABRICKS_BUNDLE_ENGINE.json +print_requests > out.requests.deploy.json trace $CLI bundle destroy --auto-approve -print_requests > out.requests.destroy.$DATABRICKS_BUNDLE_ENGINE.json +print_requests > out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/analyze_requests.py b/acceptance/bundle/resources/permissions/analyze_requests.py deleted file mode 100755 index 68bc0dadea9..00000000000 --- a/acceptance/bundle/resources/permissions/analyze_requests.py +++ /dev/null @@ -1,134 +0,0 @@ -#!/usr/bin/env python3 -""" -Analyze all requests recorded in subtests to highlight differences between direct and terraform. -""" - -import json -import re -import sys -from difflib import unified_diff -from pathlib import Path - -import tomllib - - -def read_json_many(file): - with open(file) as fobj: - s = fobj.read() - - # fix invalid json due to replacement: x: [NUMID] --> x: "[NUMID]" - s = re.sub(r": \[(.*?)\]", r': "[\1]"', s) - - result = [] - - try: - dec = json.JSONDecoder() - pos = 0 - n = len(s) - while True: - # skip whitespace between objects - while pos < n and s[pos].isspace(): - pos += 1 - if pos >= n: - break - obj, idx = dec.raw_decode(s, pos) - result.append(obj) - pos = idx - - except Exception as ex: - sys.exit(f"Failed to parse {file}: {ex}") - - return result - - -def normalize_acls(data): - """Recursively normalize ACLs in the data structure by sorting them.""" - if isinstance(data, dict): - result = {} - for key, value in data.items(): - if key == "access_control_list" and isinstance(value, list): - # Sort ACLs by all fields to normalize order - result[key] = sorted(value, key=lambda x: json.dumps(x, sort_keys=True)) - else: - result[key] = normalize_acls(value) - return result - elif isinstance(data, list): - return [normalize_acls(item) for item in data] - else: - return data - - -def compare_files(file1, file2): - """Compare two JSON files and return comparison result.""" - data1 = read_json_many(file1) - data2 = read_json_many(file2) - - if data1 == data2: - return "EXACT", "" - - normalized1 = normalize_acls(data1) - normalized2 = normalize_acls(data2) - - if normalized1 == normalized2: - return "MATCH", "" - - json1_str = json.dumps(normalized1, indent=2, sort_keys=True) - json2_str = json.dumps(normalized2, indent=2, sort_keys=True) - - diff_lines = list( - unified_diff( - json1_str.splitlines(keepends=True), - json2_str.splitlines(keepends=True), - fromfile=str(file1), - tofile=str(file2), - n=3, - ) - ) - - return "DIFF ", "\n" + to_slash("".join(diff_lines).rstrip()) - - -def to_slash(x): - return str(x).replace("\\", "/") - - -def load_supported_engines(path): - current = path - while True: - for name in ("out.test.toml", "test.toml"): - config_file = current / name - if config_file.exists(): - with config_file.open("rb") as fobj: - config = tomllib.load(fobj) - return set(config.get("EnvMatrix", {}).get("DATABRICKS_BUNDLE_ENGINE", [])) - if current == Path("."): - return set() - current = current.parent - - -def main(): - current_dir = Path(".") - - direct_files = list(current_dir.glob("**/*.direct.json")) - - for direct_file in sorted(direct_files): - if direct_file.name.startswith("out.plan"): - # expected difference - continue - - terraform_file = direct_file.parent / direct_file.name.replace(".direct.", ".terraform.") - - fname = to_slash(direct_file) - supported_engines = load_supported_engines(direct_file.parent) - - if terraform_file.exists(): - result, diff = compare_files(direct_file, terraform_file) - print(result + " " + fname + diff) - elif "terraform" not in supported_engines: - print(f"DIRECT_ONLY {fname}") - else: - print(f"ERROR {fname}: Missing terraform file {to_slash(terraform_file)}") - - -if __name__ == "__main__": - main() diff --git a/acceptance/bundle/resources/permissions/apps/current_can_manage/out.plan.direct.json b/acceptance/bundle/resources/permissions/apps/current_can_manage/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/apps/current_can_manage/out.plan.direct.json rename to acceptance/bundle/resources/permissions/apps/current_can_manage/out.plan.json diff --git a/acceptance/bundle/resources/permissions/apps/current_can_manage/out.plan.terraform.json b/acceptance/bundle/resources/permissions/apps/current_can_manage/out.plan.terraform.json deleted file mode 100644 index 23033f02637..00000000000 --- a/acceptance/bundle/resources/permissions/apps/current_can_manage/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.apps.foo": { - "action": "create" - }, - "resources.apps.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/apps/current_can_manage/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/apps/current_can_manage/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/apps/current_can_manage/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/apps/current_can_manage/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/apps/current_can_manage/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/apps/current_can_manage/out.requests.deploy.terraform.json deleted file mode 100644 index d8596961bb9..00000000000 --- a/acceptance/bundle/resources/permissions/apps/current_can_manage/out.requests.deploy.terraform.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/apps/foo", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_USE", - "user_name": "viewer@example.com" - }, - { - "permission_level": "CAN_MANAGE", - "service_principal_name": "[UUID]" - }, - { - "group_name": "data-team", - "permission_level": "CAN_MANAGE" - }, - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/grants/schemas/change_privilege/out.destroy.requests.direct.json b/acceptance/bundle/resources/permissions/apps/current_can_manage/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/grants/schemas/change_privilege/out.destroy.requests.direct.json rename to acceptance/bundle/resources/permissions/apps/current_can_manage/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/apps/current_can_manage/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/apps/current_can_manage/out.requests.destroy.terraform.json deleted file mode 100644 index 93342c3b91e..00000000000 --- a/acceptance/bundle/resources/permissions/apps/current_can_manage/out.requests.destroy.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/apps/foo", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/apps/current_can_manage/out.test.toml b/acceptance/bundle/resources/permissions/apps/current_can_manage/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/apps/current_can_manage/out.test.toml +++ b/acceptance/bundle/resources/permissions/apps/current_can_manage/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/apps/other_can_manage/out.plan.direct.json b/acceptance/bundle/resources/permissions/apps/other_can_manage/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/apps/other_can_manage/out.plan.direct.json rename to acceptance/bundle/resources/permissions/apps/other_can_manage/out.plan.json diff --git a/acceptance/bundle/resources/permissions/apps/other_can_manage/out.plan.terraform.json b/acceptance/bundle/resources/permissions/apps/other_can_manage/out.plan.terraform.json deleted file mode 100644 index 23033f02637..00000000000 --- a/acceptance/bundle/resources/permissions/apps/other_can_manage/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.apps.foo": { - "action": "create" - }, - "resources.apps.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/apps/other_can_manage/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/apps/other_can_manage/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/apps/other_can_manage/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/apps/other_can_manage/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/apps/other_can_manage/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/apps/other_can_manage/out.requests.deploy.terraform.json deleted file mode 100644 index d8596961bb9..00000000000 --- a/acceptance/bundle/resources/permissions/apps/other_can_manage/out.requests.deploy.terraform.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/apps/foo", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_USE", - "user_name": "viewer@example.com" - }, - { - "permission_level": "CAN_MANAGE", - "service_principal_name": "[UUID]" - }, - { - "group_name": "data-team", - "permission_level": "CAN_MANAGE" - }, - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/grants/volumes/out.destroy.requests.direct.json b/acceptance/bundle/resources/permissions/apps/other_can_manage/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/grants/volumes/out.destroy.requests.direct.json rename to acceptance/bundle/resources/permissions/apps/other_can_manage/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/apps/other_can_manage/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/apps/other_can_manage/out.requests.destroy.terraform.json deleted file mode 100644 index 93342c3b91e..00000000000 --- a/acceptance/bundle/resources/permissions/apps/other_can_manage/out.requests.destroy.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/apps/foo", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/apps/other_can_manage/out.test.toml b/acceptance/bundle/resources/permissions/apps/other_can_manage/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/apps/other_can_manage/out.test.toml +++ b/acceptance/bundle/resources/permissions/apps/other_can_manage/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.plan.direct.json b/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/clusters/current_can_manage/out.plan.direct.json rename to acceptance/bundle/resources/permissions/clusters/current_can_manage/out.plan.json diff --git a/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.plan.terraform.json b/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.plan.terraform.json deleted file mode 100644 index 568bfa5c382..00000000000 --- a/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.clusters.foo": { - "action": "create" - }, - "resources.clusters.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/clusters/current_can_manage/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/clusters/current_can_manage/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.requests.deploy.terraform.json deleted file mode 100644 index 0dcab25d2fc..00000000000 --- a/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.requests.deploy.terraform.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/clusters/[UUID]", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_MANAGE", - "service_principal_name": "[UUID]" - }, - { - "group_name": "data-team", - "permission_level": "CAN_MANAGE" - }, - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - }, - { - "permission_level": "CAN_ATTACH_TO", - "user_name": "viewer@example.com" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/apps/current_can_manage/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/apps/current_can_manage/out.requests.destroy.direct.json rename to acceptance/bundle/resources/permissions/clusters/current_can_manage/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.requests.destroy.terraform.json deleted file mode 100644 index ef3b016e1d9..00000000000 --- a/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.requests.destroy.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/clusters/[UUID]", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.test.toml b/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.test.toml +++ b/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/clusters/target/out.requests.direct.json b/acceptance/bundle/resources/permissions/clusters/target/out.requests.json similarity index 100% rename from acceptance/bundle/resources/permissions/clusters/target/out.requests.direct.json rename to acceptance/bundle/resources/permissions/clusters/target/out.requests.json diff --git a/acceptance/bundle/resources/permissions/clusters/target/out.requests.terraform.json b/acceptance/bundle/resources/permissions/clusters/target/out.requests.terraform.json deleted file mode 100644 index 776f05d2710..00000000000 --- a/acceptance/bundle/resources/permissions/clusters/target/out.requests.terraform.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.1/clusters/create", - "body": { - "autotermination_minutes": 60, - "cluster_name": "[dev [USERNAME]] test-cluster", - "custom_tags": { - "dev": "[USERNAME]" - }, - "node_type_id": "[NODE_TYPE_ID]", - "num_workers": 1, - "spark_version": "15.4.x-scala2.12" - } -} -{ - "method": "PUT", - "path": "/api/2.0/permissions/clusters/[UUID]", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_MANAGE", - "service_principal_name": "[UUID]" - }, - { - "permission_level": "CAN_ATTACH_TO", - "service_principal_name": "[UUID]" - }, - { - "permission_level": "CAN_RESTART", - "service_principal_name": "[UUID]" - }, - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/clusters/target/out.test.toml b/acceptance/bundle/resources/permissions/clusters/target/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/clusters/target/out.test.toml +++ b/acceptance/bundle/resources/permissions/clusters/target/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/clusters/target/script b/acceptance/bundle/resources/permissions/clusters/target/script index fbc59d852aa..821436b578a 100644 --- a/acceptance/bundle/resources/permissions/clusters/target/script +++ b/acceptance/bundle/resources/permissions/clusters/target/script @@ -1,3 +1,3 @@ trace $CLI bundle validate -o json | jq .resources trace $CLI bundle deploy -trace print_requests.py //clusters > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //clusters > out.requests.json diff --git a/acceptance/bundle/resources/permissions/dashboards/create/out.plan.direct.json b/acceptance/bundle/resources/permissions/dashboards/create/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/dashboards/create/out.plan.direct.json rename to acceptance/bundle/resources/permissions/dashboards/create/out.plan.json diff --git a/acceptance/bundle/resources/permissions/dashboards/create/out.plan.terraform.json b/acceptance/bundle/resources/permissions/dashboards/create/out.plan.terraform.json deleted file mode 100644 index ef418c77d85..00000000000 --- a/acceptance/bundle/resources/permissions/dashboards/create/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.dashboards.foo": { - "action": "create" - }, - "resources.dashboards.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/dashboards/create/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/dashboards/create/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/dashboards/create/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/dashboards/create/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/dashboards/create/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/dashboards/create/out.requests.deploy.terraform.json deleted file mode 100644 index 262567c1be8..00000000000 --- a/acceptance/bundle/resources/permissions/dashboards/create/out.requests.deploy.terraform.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/dashboards/[FOO_ID]", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_MANAGE", - "service_principal_name": "[USERNAME]" - }, - { - "permission_level": "CAN_READ", - "user_name": "deco-test-user@databricks.com" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/apps/other_can_manage/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/dashboards/create/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/apps/other_can_manage/out.requests.destroy.direct.json rename to acceptance/bundle/resources/permissions/dashboards/create/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/dashboards/create/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/dashboards/create/out.requests.destroy.terraform.json deleted file mode 100644 index 75bac408916..00000000000 --- a/acceptance/bundle/resources/permissions/dashboards/create/out.requests.destroy.terraform.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/dashboards/[FOO_ID]", - "body": {} -} diff --git a/acceptance/bundle/resources/permissions/dashboards/create/out.test.toml b/acceptance/bundle/resources/permissions/dashboards/create/out.test.toml index 7ba23274224..669a6b593c4 100644 --- a/acceptance/bundle/resources/permissions/dashboards/create/out.test.toml +++ b/acceptance/bundle/resources/permissions/dashboards/create/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/dashboards/create/script b/acceptance/bundle/resources/permissions/dashboards/create/script index aca0f41e099..e8d458ad200 100644 --- a/acceptance/bundle/resources/permissions/dashboards/create/script +++ b/acceptance/bundle/resources/permissions/dashboards/create/script @@ -7,7 +7,7 @@ envsubst < databricks.yml.tmpl > databricks.yml trace $CLI bundle validate -o json | jq .resources.dashboards.foo.permissions rm "$OUT_REQUESTS" -$CLI bundle plan --output json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan --output json | nostamp > out.plan.json rm "$OUT_REQUESTS" trace $CLI bundle deploy @@ -15,7 +15,7 @@ trace $CLI bundle deploy # Add all resource IDs to runtime replacements to avoid pattern matching ambiguity replace_ids.py -print_requests.py //permissions > out.requests.deploy.$DATABRICKS_BUNDLE_ENGINE.json +print_requests.py //permissions > out.requests.deploy.json trace $CLI bundle destroy --auto-approve -print_requests.py //permissions > out.requests.destroy.$DATABRICKS_BUNDLE_ENGINE.json +print_requests.py //permissions > out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.plan.direct.json b/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.plan.direct.json rename to acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.plan.json diff --git a/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.plan.terraform.json b/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.plan.terraform.json deleted file mode 100644 index 96c49267ccd..00000000000 --- a/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.database_instances.foo": { - "action": "create" - }, - "resources.database_instances.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.requests.deploy.terraform.json deleted file mode 100644 index 102dd25bdce..00000000000 --- a/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.requests.deploy.terraform.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/database-instances/test-db-instance", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_USE", - "user_name": "viewer@example.com" - }, - { - "permission_level": "CAN_MANAGE", - "service_principal_name": "[UUID]" - }, - { - "group_name": "data-team", - "permission_level": "CAN_MANAGE" - }, - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/clusters/current_can_manage/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/clusters/current_can_manage/out.requests.destroy.direct.json rename to acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.requests.destroy.terraform.json deleted file mode 100644 index fb2955430a0..00000000000 --- a/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.requests.destroy.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/database-instances/test-db-instance", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.test.toml b/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.test.toml +++ b/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.plan.direct.json b/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/experiments/current_can_manage/out.plan.direct.json rename to acceptance/bundle/resources/permissions/experiments/current_can_manage/out.plan.json diff --git a/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.plan.terraform.json b/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.plan.terraform.json deleted file mode 100644 index 7a958d7b38a..00000000000 --- a/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.experiments.foo": { - "action": "create" - }, - "resources.experiments.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/experiments/current_can_manage/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/experiments/current_can_manage/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.requests.deploy.terraform.json deleted file mode 100644 index e0c5cfe5a91..00000000000 --- a/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.requests.deploy.terraform.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/experiments/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_READ", - "user_name": "viewer@example.com" - }, - { - "permission_level": "CAN_MANAGE", - "service_principal_name": "[UUID]" - }, - { - "group_name": "data-team", - "permission_level": "CAN_MANAGE" - }, - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/dashboards/create/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/dashboards/create/out.requests.destroy.direct.json rename to acceptance/bundle/resources/permissions/experiments/current_can_manage/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.requests.destroy.terraform.json deleted file mode 100644 index d1d042a2978..00000000000 --- a/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.requests.destroy.terraform.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/experiments/[NUMID]", - "body": {} -} diff --git a/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.test.toml b/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.test.toml +++ b/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/factcheck/out.test.toml b/acceptance/bundle/resources/permissions/factcheck/out.test.toml index f6514a8cd9d..7ce718742f8 100644 --- a/acceptance/bundle/resources/permissions/factcheck/out.test.toml +++ b/acceptance/bundle/resources/permissions/factcheck/out.test.toml @@ -2,5 +2,4 @@ Cloud = true CloudSlow = true RunsOnDbr = true CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/out.plan.direct.json b/acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/out.plan.direct.json rename to acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/out.plan.json diff --git a/acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/database_instances/current_can_manage/out.requests.destroy.direct.json rename to acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/out.test.toml b/acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/out.test.toml +++ b/acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/script b/acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/script index b63c7b26aa0..d865fd5c6a8 100644 --- a/acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/script +++ b/acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/script @@ -1,13 +1,13 @@ trace $CLI bundle validate -o json | jq .resources.genie_spaces.foo.permissions rm "$OUT_REQUESTS" -$CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan.json rm "$OUT_REQUESTS" trace $CLI bundle deploy # Genie space IDs are random; normalize them in the recorded requests. replace_ids.py -print_requests.py //permissions > out.requests.deploy.$DATABRICKS_BUNDLE_ENGINE.json +print_requests.py //permissions > out.requests.deploy.json trace $CLI bundle destroy --auto-approve -print_requests.py //permissions > out.requests.destroy.$DATABRICKS_BUNDLE_ENGINE.json +print_requests.py //permissions > out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/genie_spaces/out_of_band_deletion/out.test.toml b/acceptance/bundle/resources/permissions/genie_spaces/out_of_band_deletion/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/genie_spaces/out_of_band_deletion/out.test.toml +++ b/acceptance/bundle/resources/permissions/genie_spaces/out_of_band_deletion/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/genie_spaces/test.toml b/acceptance/bundle/resources/permissions/genie_spaces/test.toml index 390388f04aa..4e698fcab7a 100644 --- a/acceptance/bundle/resources/permissions/genie_spaces/test.toml +++ b/acceptance/bundle/resources/permissions/genie_spaces/test.toml @@ -1,4 +1,3 @@ Env.RESOURCE = "genie_spaces" # for ../_script # Genie spaces only support the direct deployment engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/permissions/jobs/added_remotely/out.plan.direct.json b/acceptance/bundle/resources/permissions/jobs/added_remotely/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/added_remotely/out.plan.direct.json rename to acceptance/bundle/resources/permissions/jobs/added_remotely/out.plan.json diff --git a/acceptance/bundle/resources/permissions/jobs/added_remotely/out.plan.terraform.json b/acceptance/bundle/resources/permissions/jobs/added_remotely/out.plan.terraform.json deleted file mode 100644 index cc4ceee2774..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/added_remotely/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.job_with_permissions": { - "action": "skip" - }, - "resources.jobs.job_with_permissions.permissions": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/added_remotely/out.test.toml b/acceptance/bundle/resources/permissions/jobs/added_remotely/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/jobs/added_remotely/out.test.toml +++ b/acceptance/bundle/resources/permissions/jobs/added_remotely/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/jobs/added_remotely/script b/acceptance/bundle/resources/permissions/jobs/added_remotely/script index e85bcde5379..da4a85ca455 100644 --- a/acceptance/bundle/resources/permissions/jobs/added_remotely/script +++ b/acceptance/bundle/resources/permissions/jobs/added_remotely/script @@ -10,7 +10,7 @@ title "Add permissions out of band" trace $CLI permissions set jobs "$job_id" --json @remote_add.json trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan.json trace $CLI bundle deploy trace $CLI bundle plan diff --git a/acceptance/bundle/resources/permissions/jobs/current_can_manage/out.plan.direct.json b/acceptance/bundle/resources/permissions/jobs/current_can_manage/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/current_can_manage/out.plan.direct.json rename to acceptance/bundle/resources/permissions/jobs/current_can_manage/out.plan.json diff --git a/acceptance/bundle/resources/permissions/jobs/current_can_manage/out.plan.terraform.json b/acceptance/bundle/resources/permissions/jobs/current_can_manage/out.plan.terraform.json deleted file mode 100644 index 0db00e350f8..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/current_can_manage/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.foo": { - "action": "create" - }, - "resources.jobs.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/current_can_manage/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/jobs/current_can_manage/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/current_can_manage/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/jobs/current_can_manage/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/jobs/current_can_manage/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/jobs/current_can_manage/out.requests.deploy.terraform.json deleted file mode 100644 index 8c15422e36c..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/current_can_manage/out.requests.deploy.terraform.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_VIEW", - "user_name": "viewer@example.com" - }, - { - "permission_level": "CAN_MANAGE", - "service_principal_name": "[UUID]" - }, - { - "group_name": "data-team", - "permission_level": "CAN_MANAGE" - }, - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/experiments/current_can_manage/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/jobs/current_can_manage/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/experiments/current_can_manage/out.requests.destroy.direct.json rename to acceptance/bundle/resources/permissions/jobs/current_can_manage/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/jobs/current_can_manage/out.test.toml b/acceptance/bundle/resources/permissions/jobs/current_can_manage/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/jobs/current_can_manage/out.test.toml +++ b/acceptance/bundle/resources/permissions/jobs/current_can_manage/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/jobs/current_can_manage_run/out.destroy.requests.direct.json b/acceptance/bundle/resources/permissions/jobs/current_can_manage_run/out.destroy.requests.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/current_can_manage_run/out.destroy.requests.direct.json rename to acceptance/bundle/resources/permissions/jobs/current_can_manage_run/out.destroy.requests.json diff --git a/acceptance/bundle/resources/permissions/jobs/current_can_manage_run/out.destroy.requests.terraform.json b/acceptance/bundle/resources/permissions/jobs/current_can_manage_run/out.destroy.requests.terraform.json deleted file mode 100644 index cd29de0d552..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/current_can_manage_run/out.destroy.requests.terraform.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} -{ - "method": "POST", - "path": "/api/2.2/jobs/delete", - "body": { - "job_id": [NUMID] - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/current_can_manage_run/out.plan.terraform.txt b/acceptance/bundle/resources/permissions/jobs/current_can_manage_run/out.plan.terraform.txt deleted file mode 100644 index e77fc0f36bd..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/current_can_manage_run/out.plan.terraform.txt +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.interim_gold_layer_job": { - "action": "skip" - }, - "resources.jobs.interim_gold_layer_job.permissions": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/current_can_manage_run/out.plan.direct.txt b/acceptance/bundle/resources/permissions/jobs/current_can_manage_run/out.plan.txt similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/current_can_manage_run/out.plan.direct.txt rename to acceptance/bundle/resources/permissions/jobs/current_can_manage_run/out.plan.txt diff --git a/acceptance/bundle/resources/permissions/jobs/current_can_manage_run/out.test.toml b/acceptance/bundle/resources/permissions/jobs/current_can_manage_run/out.test.toml index 7ba23274224..669a6b593c4 100644 --- a/acceptance/bundle/resources/permissions/jobs/current_can_manage_run/out.test.toml +++ b/acceptance/bundle/resources/permissions/jobs/current_can_manage_run/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/jobs/current_can_manage_run/script b/acceptance/bundle/resources/permissions/jobs/current_can_manage_run/script index 3c8217c195c..2c310df73fb 100644 --- a/acceptance/bundle/resources/permissions/jobs/current_can_manage_run/script +++ b/acceptance/bundle/resources/permissions/jobs/current_can_manage_run/script @@ -5,7 +5,7 @@ trace errcode $CLI bundle deploy -t green print_requests.py //jobs --nostamp &> out.deploy.requests.json # check plan to ensure there is not drift -trace $CLI bundle plan -o json -t green | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.txt +trace $CLI bundle plan -o json -t green | nostamp > out.plan.txt trace errcode $CLI bundle destroy -t green --auto-approve -print_requests.py //jobs --nostamp &> out.destroy.requests.$DATABRICKS_BUNDLE_ENGINE.json +print_requests.py //jobs --nostamp &> out.destroy.requests.json diff --git a/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.plan.direct.json b/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/current_is_owner/out.plan.direct.json rename to acceptance/bundle/resources/permissions/jobs/current_is_owner/out.plan.json diff --git a/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.plan.terraform.json b/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.plan.terraform.json deleted file mode 100644 index 0db00e350f8..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.foo": { - "action": "create" - }, - "resources.jobs.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.requests.deploy.direct.json deleted file mode 100644 index f7aa2dbaa0d..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.requests.deploy.direct.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/current_can_manage/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/current_can_manage/out.requests.destroy.terraform.json rename to acceptance/bundle/resources/permissions/jobs/current_is_owner/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.requests.deploy.terraform.json deleted file mode 100644 index f7aa2dbaa0d..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.requests.deploy.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/genie_spaces/current_can_manage/out.requests.destroy.direct.json rename to acceptance/bundle/resources/permissions/jobs/current_is_owner/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.requests.destroy.terraform.json deleted file mode 100644 index f7aa2dbaa0d..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.requests.destroy.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.test.toml b/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.test.toml +++ b/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/jobs/delete_one/out.plan_create.direct.json b/acceptance/bundle/resources/permissions/jobs/delete_one/out.plan_create.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/delete_one/out.plan_create.direct.json rename to acceptance/bundle/resources/permissions/jobs/delete_one/out.plan_create.json diff --git a/acceptance/bundle/resources/permissions/jobs/delete_one/out.plan_create.terraform.json b/acceptance/bundle/resources/permissions/jobs/delete_one/out.plan_create.terraform.json deleted file mode 100644 index 90329220ea0..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/delete_one/out.plan_create.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.job_with_permissions": { - "action": "create" - }, - "resources.jobs.job_with_permissions.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/delete_one/out.requests_destroy.direct.json b/acceptance/bundle/resources/permissions/jobs/delete_one/out.requests_destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/delete_one/out.requests_destroy.direct.json rename to acceptance/bundle/resources/permissions/jobs/delete_one/out.requests_destroy.json diff --git a/acceptance/bundle/resources/permissions/jobs/delete_one/out.requests_destroy.terraform.json b/acceptance/bundle/resources/permissions/jobs/delete_one/out.requests_destroy.terraform.json deleted file mode 100644 index f66a05564c6..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/delete_one/out.requests_destroy.terraform.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[JOB_WITH_PERMISSIONS_ID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} -{ - "method": "POST", - "path": "/api/2.2/jobs/delete", - "body": { - "job_id": [JOB_WITH_PERMISSIONS_ID] - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/delete_one/out.test.toml b/acceptance/bundle/resources/permissions/jobs/delete_one/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/permissions/jobs/delete_one/out.test.toml +++ b/acceptance/bundle/resources/permissions/jobs/delete_one/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/jobs/delete_one/script b/acceptance/bundle/resources/permissions/jobs/delete_one/script index 06e81a6129c..ef6e2142e07 100644 --- a/acceptance/bundle/resources/permissions/jobs/delete_one/script +++ b/acceptance/bundle/resources/permissions/jobs/delete_one/script @@ -8,11 +8,11 @@ if [ -n "$CLOUD_ENV" ]; then fi rm -f "$OUT_REQUESTS" -trace $CLI bundle plan -o json | nostamp > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_create.json cleanup() { trace errcode $CLI bundle destroy --auto-approve - print_requests.py --nostamp //jobs/ > out.requests_destroy.$DATABRICKS_BUNDLE_ENGINE.json + print_requests.py --nostamp //jobs/ > out.requests_destroy.json } trap cleanup EXIT diff --git a/acceptance/bundle/resources/permissions/jobs/deleted_remotely/out.plan_create.direct.json b/acceptance/bundle/resources/permissions/jobs/deleted_remotely/out.plan_create.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/deleted_remotely/out.plan_create.direct.json rename to acceptance/bundle/resources/permissions/jobs/deleted_remotely/out.plan_create.json diff --git a/acceptance/bundle/resources/permissions/jobs/deleted_remotely/out.plan_create.terraform.json b/acceptance/bundle/resources/permissions/jobs/deleted_remotely/out.plan_create.terraform.json deleted file mode 100644 index 90329220ea0..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/deleted_remotely/out.plan_create.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.job_with_permissions": { - "action": "create" - }, - "resources.jobs.job_with_permissions.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/deleted_remotely/out.plan_restore.direct.json b/acceptance/bundle/resources/permissions/jobs/deleted_remotely/out.plan_restore.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/deleted_remotely/out.plan_restore.direct.json rename to acceptance/bundle/resources/permissions/jobs/deleted_remotely/out.plan_restore.json diff --git a/acceptance/bundle/resources/permissions/jobs/deleted_remotely/out.plan_restore.terraform.json b/acceptance/bundle/resources/permissions/jobs/deleted_remotely/out.plan_restore.terraform.json deleted file mode 100644 index cc4ceee2774..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/deleted_remotely/out.plan_restore.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.job_with_permissions": { - "action": "skip" - }, - "resources.jobs.job_with_permissions.permissions": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/deleted_remotely/out.test.toml b/acceptance/bundle/resources/permissions/jobs/deleted_remotely/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/jobs/deleted_remotely/out.test.toml +++ b/acceptance/bundle/resources/permissions/jobs/deleted_remotely/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/jobs/deleted_remotely/script b/acceptance/bundle/resources/permissions/jobs/deleted_remotely/script index 02eddde0ccc..cd9293b8f19 100644 --- a/acceptance/bundle/resources/permissions/jobs/deleted_remotely/script +++ b/acceptance/bundle/resources/permissions/jobs/deleted_remotely/script @@ -1,4 +1,4 @@ -trace $CLI bundle plan -o json | nostamp > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_create.json trace $CLI bundle deploy trace print_requests.py --nostamp //jobs/ > out.requests_create.json @@ -11,7 +11,7 @@ title "Delete permissions remotely" trace $CLI permissions set jobs "$job_id" --json @remote_delete.json trace print_requests.py --nostamp //jobs/ -trace $CLI bundle plan -o json | nostamp > out.plan_restore.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_restore.json trace $CLI bundle deploy trace print_requests.py --nostamp //jobs/ > out.requests_restore.json diff --git a/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/out.destroy.terraform.txt b/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/out.destroy.terraform.txt deleted file mode 100644 index 170bffc3cb8..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/out.destroy.terraform.txt +++ /dev/null @@ -1,14 +0,0 @@ - ->>> errcode as-test-sp [CLI] bundle destroy --auto-approve -Error: exit status 1 - -Error: cannot read job: User [TEST_SP_APPLICATION_ID] does not have View or Admin or Manage Run or Owner permissions on job [NUMID] - - with databricks_job.foo, - on bundle.tf.json line 27, in resource.databricks_job.foo: - 27: } - - - - -Exit code: 1 diff --git a/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/out.destroy.direct.txt b/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/out.destroy.txt similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/out.destroy.direct.txt rename to acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/out.destroy.txt diff --git a/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/out.test.toml b/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/out.test.toml index 3220a0c8e19..5f2da118288 100644 --- a/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/out.test.toml +++ b/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/out.test.toml @@ -2,5 +2,4 @@ Cloud = true RunsOnDbr = false CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/script b/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/script index f3bd0d9c85a..4f5531d9f6d 100644 --- a/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/script +++ b/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/script @@ -32,4 +32,4 @@ trace $CLI jobs delete $job_id trace musterr $CLI jobs get $job_id # This shows that even if job is deleted, you still get permission error when trying to delete it. -trace errcode as-test-sp $CLI bundle destroy --auto-approve &> out.destroy.$DATABRICKS_BUNDLE_ENGINE.txt +trace errcode as-test-sp $CLI bundle destroy --auto-approve &> out.destroy.txt diff --git a/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/out.destroy.terraform.txt b/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/out.destroy.terraform.txt deleted file mode 100644 index 170bffc3cb8..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/out.destroy.terraform.txt +++ /dev/null @@ -1,14 +0,0 @@ - ->>> errcode as-test-sp [CLI] bundle destroy --auto-approve -Error: exit status 1 - -Error: cannot read job: User [TEST_SP_APPLICATION_ID] does not have View or Admin or Manage Run or Owner permissions on job [NUMID] - - with databricks_job.foo, - on bundle.tf.json line 27, in resource.databricks_job.foo: - 27: } - - - - -Exit code: 1 diff --git a/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/out.destroy.direct.txt b/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/out.destroy.txt similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/out.destroy.direct.txt rename to acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/out.destroy.txt diff --git a/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/out.test.toml b/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/out.test.toml index 3220a0c8e19..5f2da118288 100644 --- a/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/out.test.toml +++ b/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/out.test.toml @@ -2,5 +2,4 @@ Cloud = true RunsOnDbr = false CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/script b/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/script index f3bd0d9c85a..4f5531d9f6d 100644 --- a/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/script +++ b/acceptance/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/script @@ -32,4 +32,4 @@ trace $CLI jobs delete $job_id trace musterr $CLI jobs get $job_id # This shows that even if job is deleted, you still get permission error when trying to delete it. -trace errcode as-test-sp $CLI bundle destroy --auto-approve &> out.destroy.$DATABRICKS_BUNDLE_ENGINE.txt +trace errcode as-test-sp $CLI bundle destroy --auto-approve &> out.destroy.txt diff --git a/acceptance/bundle/resources/permissions/jobs/empty_list/out.plan.direct.json b/acceptance/bundle/resources/permissions/jobs/empty_list/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/empty_list/out.plan.direct.json rename to acceptance/bundle/resources/permissions/jobs/empty_list/out.plan.json diff --git a/acceptance/bundle/resources/permissions/jobs/empty_list/out.plan.terraform.json b/acceptance/bundle/resources/permissions/jobs/empty_list/out.plan.terraform.json deleted file mode 100644 index 5a250db78de..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/empty_list/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.foo": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/current_can_manage/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/jobs/empty_list/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/current_can_manage/out.requests.destroy.direct.json rename to acceptance/bundle/resources/permissions/jobs/empty_list/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/jobs/current_is_owner/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/jobs/empty_list/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/current_is_owner/out.requests.destroy.direct.json rename to acceptance/bundle/resources/permissions/jobs/empty_list/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/jobs/empty_list/out.test.toml b/acceptance/bundle/resources/permissions/jobs/empty_list/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/jobs/empty_list/out.test.toml +++ b/acceptance/bundle/resources/permissions/jobs/empty_list/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.plan.direct.json b/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/other_can_manage/out.plan.direct.json rename to acceptance/bundle/resources/permissions/jobs/other_can_manage/out.plan.json diff --git a/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.plan.terraform.json b/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.plan.terraform.json deleted file mode 100644 index 0db00e350f8..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.foo": { - "action": "create" - }, - "resources.jobs.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/other_can_manage/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/jobs/other_can_manage/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.requests.deploy.terraform.json deleted file mode 100644 index 8c15422e36c..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.requests.deploy.terraform.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_VIEW", - "user_name": "viewer@example.com" - }, - { - "permission_level": "CAN_MANAGE", - "service_principal_name": "[UUID]" - }, - { - "group_name": "data-team", - "permission_level": "CAN_MANAGE" - }, - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/empty_list/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/empty_list/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/jobs/other_can_manage/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.requests.destroy.terraform.json deleted file mode 100644 index f7aa2dbaa0d..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.requests.destroy.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.test.toml b/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.test.toml +++ b/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/jobs/other_can_manage_run/out.destroy.requests.direct.json b/acceptance/bundle/resources/permissions/jobs/other_can_manage_run/out.destroy.requests.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/other_can_manage_run/out.destroy.requests.direct.json rename to acceptance/bundle/resources/permissions/jobs/other_can_manage_run/out.destroy.requests.json diff --git a/acceptance/bundle/resources/permissions/jobs/other_can_manage_run/out.destroy.requests.terraform.json b/acceptance/bundle/resources/permissions/jobs/other_can_manage_run/out.destroy.requests.terraform.json deleted file mode 100644 index cd29de0d552..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/other_can_manage_run/out.destroy.requests.terraform.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} -{ - "method": "POST", - "path": "/api/2.2/jobs/delete", - "body": { - "job_id": [NUMID] - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/other_can_manage_run/out.test.toml b/acceptance/bundle/resources/permissions/jobs/other_can_manage_run/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/jobs/other_can_manage_run/out.test.toml +++ b/acceptance/bundle/resources/permissions/jobs/other_can_manage_run/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/jobs/other_can_manage_run/script b/acceptance/bundle/resources/permissions/jobs/other_can_manage_run/script index 3e8d8d7c69c..c063be4b8d3 100644 --- a/acceptance/bundle/resources/permissions/jobs/other_can_manage_run/script +++ b/acceptance/bundle/resources/permissions/jobs/other_can_manage_run/script @@ -5,4 +5,4 @@ trace errcode $CLI bundle deploy -t green print_requests.py //jobs --nostamp &> out.deploy.requests.json trace errcode $CLI bundle destroy -t green --auto-approve -print_requests.py //jobs --nostamp &> out.destroy.requests.$DATABRICKS_BUNDLE_ENGINE.json +print_requests.py //jobs --nostamp &> out.destroy.requests.json diff --git a/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.plan.direct.json b/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/other_is_owner/out.plan.direct.json rename to acceptance/bundle/resources/permissions/jobs/other_is_owner/out.plan.json diff --git a/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.plan.terraform.json b/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.plan.terraform.json deleted file mode 100644 index 0db00e350f8..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.foo": { - "action": "create" - }, - "resources.jobs.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/other_is_owner/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/jobs/other_is_owner/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.requests.deploy.terraform.json deleted file mode 100644 index b1eb1519e87..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.requests.deploy.terraform.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "other_user@databricks.com" - }, - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/empty_list/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/empty_list/out.requests.deploy.terraform.json rename to acceptance/bundle/resources/permissions/jobs/other_is_owner/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.requests.destroy.terraform.json deleted file mode 100644 index f7aa2dbaa0d..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.requests.destroy.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.test.toml b/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.test.toml +++ b/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/jobs/reorder_locally/out.test.toml b/acceptance/bundle/resources/permissions/jobs/reorder_locally/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/jobs/reorder_locally/out.test.toml +++ b/acceptance/bundle/resources/permissions/jobs/reorder_locally/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/jobs/reorder_remotely/out.test.toml b/acceptance/bundle/resources/permissions/jobs/reorder_remotely/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/jobs/reorder_remotely/out.test.toml +++ b/acceptance/bundle/resources/permissions/jobs/reorder_remotely/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.plan_create.direct.json b/acceptance/bundle/resources/permissions/jobs/update/out.plan_create.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/update/out.plan_create.direct.json rename to acceptance/bundle/resources/permissions/jobs/update/out.plan_create.json diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.plan_create.terraform.json b/acceptance/bundle/resources/permissions/jobs/update/out.plan_create.terraform.json deleted file mode 100644 index 90329220ea0..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/update/out.plan_create.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.job_with_permissions": { - "action": "create" - }, - "resources.jobs.job_with_permissions.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.plan_delete_all.direct.json b/acceptance/bundle/resources/permissions/jobs/update/out.plan_delete_all.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/update/out.plan_delete_all.direct.json rename to acceptance/bundle/resources/permissions/jobs/update/out.plan_delete_all.json diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.plan_delete_all.terraform.json b/acceptance/bundle/resources/permissions/jobs/update/out.plan_delete_all.terraform.json deleted file mode 100644 index 4910a177337..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/update/out.plan_delete_all.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.job_with_permissions": { - "action": "skip" - }, - "resources.jobs.job_with_permissions.permissions": { - "action": "delete", - "state_only": true - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.plan_delete_one.direct.json b/acceptance/bundle/resources/permissions/jobs/update/out.plan_delete_one.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/update/out.plan_delete_one.direct.json rename to acceptance/bundle/resources/permissions/jobs/update/out.plan_delete_one.json diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.plan_delete_one.terraform.json b/acceptance/bundle/resources/permissions/jobs/update/out.plan_delete_one.terraform.json deleted file mode 100644 index cc4ceee2774..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/update/out.plan_delete_one.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.job_with_permissions": { - "action": "skip" - }, - "resources.jobs.job_with_permissions.permissions": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.plan_post_create.direct.json b/acceptance/bundle/resources/permissions/jobs/update/out.plan_post_create.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/update/out.plan_post_create.direct.json rename to acceptance/bundle/resources/permissions/jobs/update/out.plan_post_create.json diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.plan_post_create.terraform.json b/acceptance/bundle/resources/permissions/jobs/update/out.plan_post_create.terraform.json deleted file mode 100644 index 08d1d1cf5ef..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/update/out.plan_post_create.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.job_with_permissions": { - "action": "skip" - }, - "resources.jobs.job_with_permissions.permissions": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.plan_restore.direct.json b/acceptance/bundle/resources/permissions/jobs/update/out.plan_restore.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/update/out.plan_restore.direct.json rename to acceptance/bundle/resources/permissions/jobs/update/out.plan_restore.json diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.plan_restore.terraform.json b/acceptance/bundle/resources/permissions/jobs/update/out.plan_restore.terraform.json deleted file mode 100644 index 19fb9d40a1a..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/update/out.plan_restore.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.job_with_permissions": { - "action": "skip" - }, - "resources.jobs.job_with_permissions.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.plan_set_empty.direct.json b/acceptance/bundle/resources/permissions/jobs/update/out.plan_set_empty.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/update/out.plan_set_empty.direct.json rename to acceptance/bundle/resources/permissions/jobs/update/out.plan_set_empty.json diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.plan_set_empty.terraform.json b/acceptance/bundle/resources/permissions/jobs/update/out.plan_set_empty.terraform.json deleted file mode 100644 index 4910a177337..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/update/out.plan_set_empty.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.job_with_permissions": { - "action": "skip" - }, - "resources.jobs.job_with_permissions.permissions": { - "action": "delete", - "state_only": true - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.plan_update.direct.json b/acceptance/bundle/resources/permissions/jobs/update/out.plan_update.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/update/out.plan_update.direct.json rename to acceptance/bundle/resources/permissions/jobs/update/out.plan_update.json diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.plan_update.terraform.json b/acceptance/bundle/resources/permissions/jobs/update/out.plan_update.terraform.json deleted file mode 100644 index cc4ceee2774..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/update/out.plan_update.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.job_with_permissions": { - "action": "skip" - }, - "resources.jobs.job_with_permissions.permissions": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/empty_list/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/jobs/update/out.requests_delete_all.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/empty_list/out.requests.destroy.direct.json rename to acceptance/bundle/resources/permissions/jobs/update/out.requests_delete_all.json diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.requests_delete_all.terraform.json b/acceptance/bundle/resources/permissions/jobs/update/out.requests_delete_all.terraform.json deleted file mode 100644 index 95d354f99a4..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/update/out.requests_delete_all.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[JOB_WITH_PERMISSIONS_ID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.requests_destroy.direct.json b/acceptance/bundle/resources/permissions/jobs/update/out.requests_destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/update/out.requests_destroy.direct.json rename to acceptance/bundle/resources/permissions/jobs/update/out.requests_destroy.json diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.requests_destroy.terraform.json b/acceptance/bundle/resources/permissions/jobs/update/out.requests_destroy.terraform.json deleted file mode 100644 index 73495bdc38f..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/update/out.requests_destroy.terraform.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.2/jobs/delete", - "body": { - "job_id": [JOB_WITH_PERMISSIONS_ID] - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/empty_list/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/jobs/update/out.requests_set_empty.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/empty_list/out.requests.destroy.terraform.json rename to acceptance/bundle/resources/permissions/jobs/update/out.requests_set_empty.json diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.requests_set_empty.terraform.json b/acceptance/bundle/resources/permissions/jobs/update/out.requests_set_empty.terraform.json deleted file mode 100644 index 95d354f99a4..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/update/out.requests_set_empty.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[JOB_WITH_PERMISSIONS_ID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.test.toml b/acceptance/bundle/resources/permissions/jobs/update/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/jobs/update/out.test.toml +++ b/acceptance/bundle/resources/permissions/jobs/update/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/jobs/update/script b/acceptance/bundle/resources/permissions/jobs/update/script index 944f85722a3..0396e6b68e4 100644 --- a/acceptance/bundle/resources/permissions/jobs/update/script +++ b/acceptance/bundle/resources/permissions/jobs/update/script @@ -1,10 +1,10 @@ cp databricks.yml databricks.yml.saved trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_create.json trace $CLI bundle deploy trace print_requests.py --nostamp //jobs/ > out.requests_create.json trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp > out.plan_post_create.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_post_create.json job_id="$(read_id.py job_with_permissions)" @@ -13,30 +13,30 @@ rm -f "$OUT_REQUESTS" title "Update one permission and deploy again\n" update_file.py databricks.yml CAN_VIEW CAN_MANAGE -trace $CLI bundle plan -o json | nostamp > out.plan_update.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_update.json trace $CLI bundle deploy trace print_requests.py --nostamp //jobs/ > out.requests_update.json trace $CLI bundle plan title "Delete one permission and deploy again\n" grep -v DELETE_ONE databricks.yml > tmp.yml && mv tmp.yml databricks.yml -trace $CLI bundle plan -o json | nostamp > out.plan_delete_one.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_delete_one.json trace $CLI bundle deploy trace print_requests.py --nostamp //jobs/ > out.requests_delete_one.json trace $CLI bundle plan title "Delete the whole block and deploy again\n" grep -v PERMISSIONS databricks.yml > tmp.yml && mv tmp.yml databricks.yml -trace $CLI bundle plan -o json | nostamp > out.plan_delete_all.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_delete_all.json trace $CLI bundle deploy -trace print_requests.py --nostamp //jobs/ > out.requests_delete_all.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --nostamp //jobs/ > out.requests_delete_all.json trace $CLI bundle plan title "Restore original config\n" trace diff.py databricks.yml.saved databricks.yml mv databricks.yml.saved databricks.yml -trace $CLI bundle plan -o json | nostamp > out.plan_restore.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_restore.json trace $CLI bundle deploy trace print_requests.py --nostamp //jobs/ > out.requests_restore_original.json trace $CLI bundle plan @@ -44,10 +44,10 @@ trace $CLI bundle plan title "Set permissions: []\n" grep -vE '(PERMISSIONS|DELETE_ONE)' databricks.yml > tmp.yml && mv tmp.yml databricks.yml update_file.py databricks.yml '# permissions: [] # EXPLICIT_EMPTY' 'permissions: [] # EXPLICIT_EMPTY' -trace $CLI bundle plan -o json | nostamp > out.plan_set_empty.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_set_empty.json trace $CLI bundle deploy -trace print_requests.py --nostamp //jobs/ > out.requests_set_empty.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --nostamp //jobs/ > out.requests_set_empty.json trace $CLI bundle destroy --auto-approve -trace print_requests.py --nostamp //jobs/ > out.requests_destroy.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --nostamp //jobs/ > out.requests_destroy.json #rm -fr .databricks diff --git a/acceptance/bundle/resources/permissions/jobs/viewers/out.plan.direct.json b/acceptance/bundle/resources/permissions/jobs/viewers/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/viewers/out.plan.direct.json rename to acceptance/bundle/resources/permissions/jobs/viewers/out.plan.json diff --git a/acceptance/bundle/resources/permissions/jobs/viewers/out.plan.terraform.json b/acceptance/bundle/resources/permissions/jobs/viewers/out.plan.terraform.json deleted file mode 100644 index 0db00e350f8..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/viewers/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.foo": { - "action": "create" - }, - "resources.jobs.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/viewers/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/jobs/viewers/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/viewers/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/jobs/viewers/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/jobs/viewers/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/jobs/viewers/out.requests.deploy.terraform.json deleted file mode 100644 index a4e11d7fb60..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/viewers/out.requests.deploy.terraform.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_VIEW", - "service_principal_name": "[UUID]" - }, - { - "permission_level": "CAN_VIEW", - "user_name": "viewer@example.com" - }, - { - "group_name": "data-team", - "permission_level": "CAN_VIEW" - }, - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/other_can_manage/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/jobs/viewers/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/other_can_manage/out.requests.destroy.direct.json rename to acceptance/bundle/resources/permissions/jobs/viewers/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/jobs/viewers/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/jobs/viewers/out.requests.destroy.terraform.json deleted file mode 100644 index f7aa2dbaa0d..00000000000 --- a/acceptance/bundle/resources/permissions/jobs/viewers/out.requests.destroy.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/viewers/out.test.toml b/acceptance/bundle/resources/permissions/jobs/viewers/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/jobs/viewers/out.test.toml +++ b/acceptance/bundle/resources/permissions/jobs/viewers/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/models/current_can_manage/out.plan.direct.json b/acceptance/bundle/resources/permissions/models/current_can_manage/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/models/current_can_manage/out.plan.direct.json rename to acceptance/bundle/resources/permissions/models/current_can_manage/out.plan.json diff --git a/acceptance/bundle/resources/permissions/models/current_can_manage/out.plan.terraform.json b/acceptance/bundle/resources/permissions/models/current_can_manage/out.plan.terraform.json deleted file mode 100644 index 3b12c9c05df..00000000000 --- a/acceptance/bundle/resources/permissions/models/current_can_manage/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.models.foo": { - "action": "create" - }, - "resources.models.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/models/current_can_manage/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/models/current_can_manage/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/models/current_can_manage/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/models/current_can_manage/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/models/current_can_manage/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/models/current_can_manage/out.requests.deploy.terraform.json deleted file mode 100644 index 06c635ad4ad..00000000000 --- a/acceptance/bundle/resources/permissions/models/current_can_manage/out.requests.deploy.terraform.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/registered-models/[FOO_MODEL_ID]", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_READ", - "user_name": "viewer@example.com" - }, - { - "permission_level": "CAN_MANAGE", - "service_principal_name": "[UUID]" - }, - { - "group_name": "data-team", - "permission_level": "CAN_MANAGE" - }, - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/other_is_owner/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/models/current_can_manage/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/other_is_owner/out.requests.destroy.direct.json rename to acceptance/bundle/resources/permissions/models/current_can_manage/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/models/current_can_manage/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/models/current_can_manage/out.requests.destroy.terraform.json deleted file mode 100644 index 62901b29fba..00000000000 --- a/acceptance/bundle/resources/permissions/models/current_can_manage/out.requests.destroy.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/registered-models/[FOO_MODEL_ID]", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/models/current_can_manage/out.test.toml b/acceptance/bundle/resources/permissions/models/current_can_manage/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/models/current_can_manage/out.test.toml +++ b/acceptance/bundle/resources/permissions/models/current_can_manage/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/models/current_can_manage/script b/acceptance/bundle/resources/permissions/models/current_can_manage/script index 5f2fa0c32cd..e1f594d80ee 100644 --- a/acceptance/bundle/resources/permissions/models/current_can_manage/script +++ b/acceptance/bundle/resources/permissions/models/current_can_manage/script @@ -1,7 +1,7 @@ trace $CLI bundle validate -o json | jq .resources.$RESOURCE.foo.permissions rm "$OUT_REQUESTS" -$CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan.json rm "$OUT_REQUESTS" trace errcode $CLI bundle deploy &> out.deploy.txt @@ -11,7 +11,7 @@ trace errcode $CLI bundle deploy &> out.deploy.txt MODEL_ID=$($CLI model-registry get-model test-model | jq -r '.registered_model_databricks.id') add_repl "$MODEL_ID" "FOO_MODEL_ID" -print_requests.py //permissions > out.requests.deploy.$DATABRICKS_BUNDLE_ENGINE.json +print_requests.py //permissions > out.requests.deploy.json trace $CLI bundle destroy --auto-approve -print_requests.py //permissions > out.requests.destroy.$DATABRICKS_BUNDLE_ENGINE.json +print_requests.py //permissions > out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/models/test.toml b/acceptance/bundle/resources/permissions/models/test.toml index d545b1b896d..2669d8b2b4f 100644 --- a/acceptance/bundle/resources/permissions/models/test.toml +++ b/acceptance/bundle/resources/permissions/models/test.toml @@ -1,2 +1 @@ Env.RESOURCE = "models" # for ../_script -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/bundle/resources/permissions/out.test.toml b/acceptance/bundle/resources/permissions/out.test.toml deleted file mode 100644 index 3311ac099b3..00000000000 --- a/acceptance/bundle/resources/permissions/out.test.toml +++ /dev/null @@ -1,4 +0,0 @@ -Cloud = false -Phase = 1 -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] -EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/output.txt b/acceptance/bundle/resources/permissions/output.txt deleted file mode 100644 index 85a16ad6a38..00000000000 --- a/acceptance/bundle/resources/permissions/output.txt +++ /dev/null @@ -1,391 +0,0 @@ -MATCH apps/current_can_manage/out.requests.deploy.direct.json -DIFF apps/current_can_manage/out.requests.destroy.direct.json ---- apps/current_can_manage/out.requests.destroy.direct.json -+++ apps/current_can_manage/out.requests.destroy.terraform.json -@@ -1 +1,14 @@ --[]+[ -+ { -+ "body": { -+ "access_control_list": [ -+ { -+ "permission_level": "CAN_MANAGE", -+ "user_name": "[USERNAME]" -+ } -+ ] -+ }, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/apps/foo" -+ } -+] -MATCH apps/other_can_manage/out.requests.deploy.direct.json -DIFF apps/other_can_manage/out.requests.destroy.direct.json ---- apps/other_can_manage/out.requests.destroy.direct.json -+++ apps/other_can_manage/out.requests.destroy.terraform.json -@@ -1 +1,14 @@ --[]+[ -+ { -+ "body": { -+ "access_control_list": [ -+ { -+ "permission_level": "CAN_MANAGE", -+ "user_name": "[USERNAME]" -+ } -+ ] -+ }, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/apps/foo" -+ } -+] -MATCH clusters/current_can_manage/out.requests.deploy.direct.json -DIFF clusters/current_can_manage/out.requests.destroy.direct.json ---- clusters/current_can_manage/out.requests.destroy.direct.json -+++ clusters/current_can_manage/out.requests.destroy.terraform.json -@@ -1 +1,14 @@ --[]+[ -+ { -+ "body": { -+ "access_control_list": [ -+ { -+ "permission_level": "CAN_MANAGE", -+ "user_name": "[USERNAME]" -+ } -+ ] -+ }, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/clusters/[UUID]" -+ } -+] -MATCH clusters/target/out.requests.direct.json -MATCH dashboards/create/out.requests.deploy.direct.json -DIFF dashboards/create/out.requests.destroy.direct.json ---- dashboards/create/out.requests.destroy.direct.json -+++ dashboards/create/out.requests.destroy.terraform.json -@@ -1 +1,7 @@ --[]+[ -+ { -+ "body": {}, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/dashboards/[FOO_ID]" -+ } -+] -MATCH database_instances/current_can_manage/out.requests.deploy.direct.json -DIFF database_instances/current_can_manage/out.requests.destroy.direct.json ---- database_instances/current_can_manage/out.requests.destroy.direct.json -+++ database_instances/current_can_manage/out.requests.destroy.terraform.json -@@ -1 +1,14 @@ --[]+[ -+ { -+ "body": { -+ "access_control_list": [ -+ { -+ "permission_level": "CAN_MANAGE", -+ "user_name": "[USERNAME]" -+ } -+ ] -+ }, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/database-instances/test-db-instance" -+ } -+] -MATCH experiments/current_can_manage/out.requests.deploy.direct.json -DIFF experiments/current_can_manage/out.requests.destroy.direct.json ---- experiments/current_can_manage/out.requests.destroy.direct.json -+++ experiments/current_can_manage/out.requests.destroy.terraform.json -@@ -1 +1,7 @@ --[]+[ -+ { -+ "body": {}, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/experiments/[NUMID]" -+ } -+] -DIRECT_ONLY genie_spaces/current_can_manage/out.requests.deploy.direct.json -DIRECT_ONLY genie_spaces/current_can_manage/out.requests.destroy.direct.json -MATCH jobs/current_can_manage/out.requests.deploy.direct.json -DIFF jobs/current_can_manage/out.requests.destroy.direct.json ---- jobs/current_can_manage/out.requests.destroy.direct.json -+++ jobs/current_can_manage/out.requests.destroy.terraform.json -@@ -1 +1,14 @@ --[]+[ -+ { -+ "body": { -+ "access_control_list": [ -+ { -+ "permission_level": "IS_OWNER", -+ "user_name": "[USERNAME]" -+ } -+ ] -+ }, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/jobs/[NUMID]" -+ } -+] -DIFF jobs/current_can_manage_run/out.destroy.requests.direct.json ---- jobs/current_can_manage_run/out.destroy.requests.direct.json -+++ jobs/current_can_manage_run/out.destroy.requests.terraform.json -@@ -1,4 +1,16 @@ - [ -+ { -+ "body": { -+ "access_control_list": [ -+ { -+ "permission_level": "IS_OWNER", -+ "user_name": "[USERNAME]" -+ } -+ ] -+ }, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/jobs/[NUMID]" -+ }, - { - "body": { - "job_id": "[NUMID]" -EXACT jobs/current_is_owner/out.requests.deploy.direct.json -DIFF jobs/current_is_owner/out.requests.destroy.direct.json ---- jobs/current_is_owner/out.requests.destroy.direct.json -+++ jobs/current_is_owner/out.requests.destroy.terraform.json -@@ -1 +1,14 @@ --[]+[ -+ { -+ "body": { -+ "access_control_list": [ -+ { -+ "permission_level": "IS_OWNER", -+ "user_name": "[USERNAME]" -+ } -+ ] -+ }, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/jobs/[NUMID]" -+ } -+] -DIFF jobs/delete_one/out.requests_destroy.direct.json ---- jobs/delete_one/out.requests_destroy.direct.json -+++ jobs/delete_one/out.requests_destroy.terraform.json -@@ -1,4 +1,16 @@ - [ -+ { -+ "body": { -+ "access_control_list": [ -+ { -+ "permission_level": "IS_OWNER", -+ "user_name": "[USERNAME]" -+ } -+ ] -+ }, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/jobs/[JOB_WITH_PERMISSIONS_ID]" -+ }, - { - "body": { - "job_id": "[JOB_WITH_PERMISSIONS_ID]" -EXACT jobs/empty_list/out.requests.deploy.direct.json -EXACT jobs/empty_list/out.requests.destroy.direct.json -MATCH jobs/other_can_manage/out.requests.deploy.direct.json -DIFF jobs/other_can_manage/out.requests.destroy.direct.json ---- jobs/other_can_manage/out.requests.destroy.direct.json -+++ jobs/other_can_manage/out.requests.destroy.terraform.json -@@ -1 +1,14 @@ --[]+[ -+ { -+ "body": { -+ "access_control_list": [ -+ { -+ "permission_level": "IS_OWNER", -+ "user_name": "[USERNAME]" -+ } -+ ] -+ }, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/jobs/[NUMID]" -+ } -+] -DIFF jobs/other_can_manage_run/out.destroy.requests.direct.json ---- jobs/other_can_manage_run/out.destroy.requests.direct.json -+++ jobs/other_can_manage_run/out.destroy.requests.terraform.json -@@ -1,4 +1,16 @@ - [ -+ { -+ "body": { -+ "access_control_list": [ -+ { -+ "permission_level": "IS_OWNER", -+ "user_name": "[USERNAME]" -+ } -+ ] -+ }, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/jobs/[NUMID]" -+ }, - { - "body": { - "job_id": "[NUMID]" -EXACT jobs/other_is_owner/out.requests.deploy.direct.json -DIFF jobs/other_is_owner/out.requests.destroy.direct.json ---- jobs/other_is_owner/out.requests.destroy.direct.json -+++ jobs/other_is_owner/out.requests.destroy.terraform.json -@@ -1 +1,14 @@ --[]+[ -+ { -+ "body": { -+ "access_control_list": [ -+ { -+ "permission_level": "IS_OWNER", -+ "user_name": "[USERNAME]" -+ } -+ ] -+ }, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/jobs/[NUMID]" -+ } -+] -DIFF jobs/update/out.requests_delete_all.direct.json ---- jobs/update/out.requests_delete_all.direct.json -+++ jobs/update/out.requests_delete_all.terraform.json -@@ -1 +1,14 @@ --[]+[ -+ { -+ "body": { -+ "access_control_list": [ -+ { -+ "permission_level": "IS_OWNER", -+ "user_name": "[USERNAME]" -+ } -+ ] -+ }, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/jobs/[JOB_WITH_PERMISSIONS_ID]" -+ } -+] -EXACT jobs/update/out.requests_destroy.direct.json -DIFF jobs/update/out.requests_set_empty.direct.json ---- jobs/update/out.requests_set_empty.direct.json -+++ jobs/update/out.requests_set_empty.terraform.json -@@ -1 +1,14 @@ --[]+[ -+ { -+ "body": { -+ "access_control_list": [ -+ { -+ "permission_level": "IS_OWNER", -+ "user_name": "[USERNAME]" -+ } -+ ] -+ }, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/jobs/[JOB_WITH_PERMISSIONS_ID]" -+ } -+] -MATCH jobs/viewers/out.requests.deploy.direct.json -DIFF jobs/viewers/out.requests.destroy.direct.json ---- jobs/viewers/out.requests.destroy.direct.json -+++ jobs/viewers/out.requests.destroy.terraform.json -@@ -1 +1,14 @@ --[]+[ -+ { -+ "body": { -+ "access_control_list": [ -+ { -+ "permission_level": "IS_OWNER", -+ "user_name": "[USERNAME]" -+ } -+ ] -+ }, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/jobs/[NUMID]" -+ } -+] -MATCH models/current_can_manage/out.requests.deploy.direct.json -DIFF models/current_can_manage/out.requests.destroy.direct.json ---- models/current_can_manage/out.requests.destroy.direct.json -+++ models/current_can_manage/out.requests.destroy.terraform.json -@@ -1 +1,14 @@ --[]+[ -+ { -+ "body": { -+ "access_control_list": [ -+ { -+ "permission_level": "CAN_MANAGE", -+ "user_name": "[USERNAME]" -+ } -+ ] -+ }, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/registered-models/[FOO_MODEL_ID]" -+ } -+] -MATCH pipelines/current_can_manage/out.requests.deploy.direct.json -EXACT pipelines/current_can_manage/out.requests.destroy.direct.json -EXACT pipelines/current_is_owner/out.requests.deploy.direct.json -EXACT pipelines/current_is_owner/out.requests.destroy.direct.json -EXACT pipelines/empty_list/out.requests.deploy.direct.json -EXACT pipelines/empty_list/out.requests.destroy.direct.json -MATCH pipelines/other_can_manage/out.requests.deploy.direct.json -EXACT pipelines/other_can_manage/out.requests.destroy.direct.json -EXACT pipelines/other_is_owner/out.requests.deploy.direct.json -EXACT pipelines/other_is_owner/out.requests.destroy.direct.json -MATCH postgres_projects/current_can_manage/out.requests.deploy.direct.json -DIFF postgres_projects/current_can_manage/out.requests.destroy.direct.json ---- postgres_projects/current_can_manage/out.requests.destroy.direct.json -+++ postgres_projects/current_can_manage/out.requests.destroy.terraform.json -@@ -1 +1,14 @@ --[]+[ -+ { -+ "body": { -+ "access_control_list": [ -+ { -+ "permission_level": "CAN_MANAGE", -+ "user_name": "[USERNAME]" -+ } -+ ] -+ }, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/database-projects/test-project" -+ } -+] -MATCH sql_warehouses/current_can_manage/out.requests.deploy.direct.json -DIFF sql_warehouses/current_can_manage/out.requests.destroy.direct.json ---- sql_warehouses/current_can_manage/out.requests.destroy.direct.json -+++ sql_warehouses/current_can_manage/out.requests.destroy.terraform.json -@@ -1 +1,18 @@ --[]+[ -+ { -+ "body": { -+ "access_control_list": [ -+ { -+ "permission_level": "CAN_MANAGE", -+ "user_name": "[USERNAME]" -+ }, -+ { -+ "permission_level": "IS_OWNER", -+ "user_name": "[USERNAME]" -+ } -+ ] -+ }, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/sql/warehouses/[UUID]" -+ } -+] -EXACT target_permissions/out.requests_create.direct.json -DIFF target_permissions/out.requests_delete.direct.json ---- target_permissions/out.requests_delete.direct.json -+++ target_permissions/out.requests_delete.terraform.json -@@ -1,4 +1,16 @@ - [ -+ { -+ "body": { -+ "access_control_list": [ -+ { -+ "permission_level": "IS_OWNER", -+ "user_name": "[USERNAME]" -+ } -+ ] -+ }, -+ "method": "PUT", -+ "path": "/api/2.0/permissions/jobs/[NUMID]" -+ }, - { - "body": { - "job_id": "[NUMID]" -DIRECT_ONLY vector_search_endpoints/current_can_manage/out.requests.deploy.direct.json -DIRECT_ONLY vector_search_endpoints/current_can_manage/out.requests.destroy.direct.json diff --git a/acceptance/bundle/resources/permissions/pipelines/504/create/out.test.toml b/acceptance/bundle/resources/permissions/pipelines/504/create/out.test.toml index 4f26abefa0f..15c32f324ac 100644 --- a/acceptance/bundle/resources/permissions/pipelines/504/create/out.test.toml +++ b/acceptance/bundle/resources/permissions/pipelines/504/create/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = [] diff --git a/acceptance/bundle/resources/permissions/pipelines/504/plan/out.test.toml b/acceptance/bundle/resources/permissions/pipelines/504/plan/out.test.toml index 4f26abefa0f..15c32f324ac 100644 --- a/acceptance/bundle/resources/permissions/pipelines/504/plan/out.test.toml +++ b/acceptance/bundle/resources/permissions/pipelines/504/plan/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = [] diff --git a/acceptance/bundle/resources/permissions/pipelines/504/test.toml b/acceptance/bundle/resources/permissions/pipelines/504/test.toml index f08b1b09e8e..16937c434a8 100644 --- a/acceptance/bundle/resources/permissions/pipelines/504/test.toml +++ b/acceptance/bundle/resources/permissions/pipelines/504/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.READPLAN = [] RecordRequests = true Env.DATABRICKS_BUNDLE_RETRY_INTERVAL_MS = "100" diff --git a/acceptance/bundle/resources/permissions/pipelines/504/update/out.test.toml b/acceptance/bundle/resources/permissions/pipelines/504/update/out.test.toml index 4f26abefa0f..15c32f324ac 100644 --- a/acceptance/bundle/resources/permissions/pipelines/504/update/out.test.toml +++ b/acceptance/bundle/resources/permissions/pipelines/504/update/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = [] diff --git a/acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.plan.direct.json b/acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.plan.direct.json rename to acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.plan.json diff --git a/acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.plan.terraform.json b/acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.plan.terraform.json deleted file mode 100644 index 58cb00a270d..00000000000 --- a/acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.foo": { - "action": "create" - }, - "resources.pipelines.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.requests.deploy.terraform.json deleted file mode 100644 index 336c18a3ad9..00000000000 --- a/acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.requests.deploy.terraform.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/pipelines/[UUID]", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_VIEW", - "user_name": "viewer@example.com" - }, - { - "permission_level": "CAN_MANAGE", - "service_principal_name": "[UUID]" - }, - { - "group_name": "data-team", - "permission_level": "CAN_MANAGE" - }, - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.requests_delete_all.direct.json b/acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/update/out.requests_delete_all.direct.json rename to acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.test.toml b/acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.test.toml +++ b/acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.plan.direct.json b/acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.plan.direct.json rename to acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.plan.json diff --git a/acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.plan.terraform.json b/acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.plan.terraform.json deleted file mode 100644 index 58cb00a270d..00000000000 --- a/acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.foo": { - "action": "create" - }, - "resources.pipelines.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.requests.deploy.terraform.json deleted file mode 100644 index 578163835c1..00000000000 --- a/acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.requests.deploy.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/pipelines/[UUID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/update/out.requests_set_empty.direct.json b/acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/update/out.requests_set_empty.direct.json rename to acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.test.toml b/acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.test.toml +++ b/acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/pipelines/empty_list/out.plan.direct.json b/acceptance/bundle/resources/permissions/pipelines/empty_list/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/empty_list/out.plan.direct.json rename to acceptance/bundle/resources/permissions/pipelines/empty_list/out.plan.json diff --git a/acceptance/bundle/resources/permissions/pipelines/empty_list/out.plan.terraform.json b/acceptance/bundle/resources/permissions/pipelines/empty_list/out.plan.terraform.json deleted file mode 100644 index 4305cb583e4..00000000000 --- a/acceptance/bundle/resources/permissions/pipelines/empty_list/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.foo": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/jobs/viewers/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/pipelines/empty_list/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/jobs/viewers/out.requests.destroy.direct.json rename to acceptance/bundle/resources/permissions/pipelines/empty_list/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/models/current_can_manage/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/pipelines/empty_list/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/models/current_can_manage/out.requests.destroy.direct.json rename to acceptance/bundle/resources/permissions/pipelines/empty_list/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/pipelines/empty_list/out.test.toml b/acceptance/bundle/resources/permissions/pipelines/empty_list/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/pipelines/empty_list/out.test.toml +++ b/acceptance/bundle/resources/permissions/pipelines/empty_list/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.plan.direct.json b/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.plan.direct.json rename to acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.plan.json diff --git a/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.plan.terraform.json b/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.plan.terraform.json deleted file mode 100644 index 58cb00a270d..00000000000 --- a/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.foo": { - "action": "create" - }, - "resources.pipelines.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.requests.deploy.terraform.json deleted file mode 100644 index 336c18a3ad9..00000000000 --- a/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.requests.deploy.terraform.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/pipelines/[UUID]", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_VIEW", - "user_name": "viewer@example.com" - }, - { - "permission_level": "CAN_MANAGE", - "service_principal_name": "[UUID]" - }, - { - "group_name": "data-team", - "permission_level": "CAN_MANAGE" - }, - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.requests.destroy.direct.json deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.requests.destroy.direct.json rename to acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.requests.destroy.terraform.json deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.test.toml b/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.test.toml +++ b/acceptance/bundle/resources/permissions/pipelines/other_can_manage/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.plan.direct.json b/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.plan.direct.json rename to acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.plan.json diff --git a/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.plan.terraform.json b/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.plan.terraform.json deleted file mode 100644 index 58cb00a270d..00000000000 --- a/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.foo": { - "action": "create" - }, - "resources.pipelines.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.requests.deploy.terraform.json deleted file mode 100644 index 8925d4f66d4..00000000000 --- a/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.requests.deploy.terraform.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/pipelines/[UUID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "other_user@databricks.com" - }, - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.requests.destroy.direct.json deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/current_can_manage/out.requests.destroy.terraform.json rename to acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.requests.destroy.terraform.json deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.test.toml b/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.test.toml +++ b/acceptance/bundle/resources/permissions/pipelines/other_is_owner/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/pipelines/update/out.plan_create.direct.json b/acceptance/bundle/resources/permissions/pipelines/update/out.plan_create.json similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/update/out.plan_create.direct.json rename to acceptance/bundle/resources/permissions/pipelines/update/out.plan_create.json diff --git a/acceptance/bundle/resources/permissions/pipelines/update/out.plan_create.terraform.json b/acceptance/bundle/resources/permissions/pipelines/update/out.plan_create.terraform.json deleted file mode 100644 index 58cb00a270d..00000000000 --- a/acceptance/bundle/resources/permissions/pipelines/update/out.plan_create.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.foo": { - "action": "create" - }, - "resources.pipelines.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/pipelines/update/out.plan_delete_all.direct.json b/acceptance/bundle/resources/permissions/pipelines/update/out.plan_delete_all.json similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/update/out.plan_delete_all.direct.json rename to acceptance/bundle/resources/permissions/pipelines/update/out.plan_delete_all.json diff --git a/acceptance/bundle/resources/permissions/pipelines/update/out.plan_delete_all.terraform.json b/acceptance/bundle/resources/permissions/pipelines/update/out.plan_delete_all.terraform.json deleted file mode 100644 index fec4ffef802..00000000000 --- a/acceptance/bundle/resources/permissions/pipelines/update/out.plan_delete_all.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.foo": { - "action": "skip" - }, - "resources.pipelines.foo.permissions": { - "action": "delete", - "state_only": true - } - } -} diff --git a/acceptance/bundle/resources/permissions/pipelines/update/out.plan_delete_one.direct.json b/acceptance/bundle/resources/permissions/pipelines/update/out.plan_delete_one.json similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/update/out.plan_delete_one.direct.json rename to acceptance/bundle/resources/permissions/pipelines/update/out.plan_delete_one.json diff --git a/acceptance/bundle/resources/permissions/pipelines/update/out.plan_delete_one.terraform.json b/acceptance/bundle/resources/permissions/pipelines/update/out.plan_delete_one.terraform.json deleted file mode 100644 index 40c278f83ab..00000000000 --- a/acceptance/bundle/resources/permissions/pipelines/update/out.plan_delete_one.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.foo": { - "action": "skip" - }, - "resources.pipelines.foo.permissions": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/permissions/pipelines/update/out.plan_restore.direct.json b/acceptance/bundle/resources/permissions/pipelines/update/out.plan_restore.json similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/update/out.plan_restore.direct.json rename to acceptance/bundle/resources/permissions/pipelines/update/out.plan_restore.json diff --git a/acceptance/bundle/resources/permissions/pipelines/update/out.plan_restore.terraform.json b/acceptance/bundle/resources/permissions/pipelines/update/out.plan_restore.terraform.json deleted file mode 100644 index d5bd3d3bf88..00000000000 --- a/acceptance/bundle/resources/permissions/pipelines/update/out.plan_restore.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.foo": { - "action": "skip" - }, - "resources.pipelines.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/pipelines/update/out.plan_update.direct.json b/acceptance/bundle/resources/permissions/pipelines/update/out.plan_update.json similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/update/out.plan_update.direct.json rename to acceptance/bundle/resources/permissions/pipelines/update/out.plan_update.json diff --git a/acceptance/bundle/resources/permissions/pipelines/update/out.plan_update.terraform.json b/acceptance/bundle/resources/permissions/pipelines/update/out.plan_update.terraform.json deleted file mode 100644 index 40c278f83ab..00000000000 --- a/acceptance/bundle/resources/permissions/pipelines/update/out.plan_update.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.foo": { - "action": "skip" - }, - "resources.pipelines.foo.permissions": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/permissions/pipelines/update/out.test.toml b/acceptance/bundle/resources/permissions/pipelines/update/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/pipelines/update/out.test.toml +++ b/acceptance/bundle/resources/permissions/pipelines/update/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/pipelines/update/script b/acceptance/bundle/resources/permissions/pipelines/update/script index 6cd4b2993cf..3be2be37147 100644 --- a/acceptance/bundle/resources/permissions/pipelines/update/script +++ b/acceptance/bundle/resources/permissions/pipelines/update/script @@ -1,5 +1,5 @@ cp databricks.yml databricks.yml.saved -trace $CLI bundle plan -o json | nostamp > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_create.json trace $CLI bundle deploy trace print_requests.py --nostamp //pipeline '^//api/2.0/bundle' > out.requests_create.json trace $CLI bundle plan @@ -11,14 +11,14 @@ rm -f "$OUT_REQUESTS" title "Update one permission and deploy again\n" update_file.py databricks.yml CAN_VIEW CAN_MANAGE -trace $CLI bundle plan -o json | nostamp > out.plan_update.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_update.json trace $CLI bundle deploy trace print_requests.py --nostamp //pipeline '^//api/2.0/bundle' > out.requests_update.json trace $CLI bundle plan title "Delete one permission and deploy again\n" grep -v DELETE_ONE databricks.yml > tmp.yml && mv tmp.yml databricks.yml -trace $CLI bundle plan -o json | nostamp > out.plan_delete_one.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_delete_one.json trace $CLI bundle deploy trace print_requests.py --nostamp //pipeline '^//api/2.0/bundle' > out.requests_delete_one.json trace $CLI bundle plan @@ -26,14 +26,14 @@ trace $CLI bundle plan title "Delete the whole block and deploy again\n" grep -v PERMISSIONS databricks.yml > tmp.yml && mv tmp.yml databricks.yml trace cat databricks.yml -trace $CLI bundle plan -o json | nostamp > out.plan_delete_all.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_delete_all.json trace $CLI bundle deploy trace print_requests.py --nostamp //pipeline '^//api/2.0/bundle' --sort > out.requests_delete_all.json trace $CLI bundle plan title "Restore original config\n" mv databricks.yml.saved databricks.yml -trace $CLI bundle plan -o json | nostamp > out.plan_restore.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_restore.json trace $CLI bundle deploy trace print_requests.py --nostamp //pipeline '^//api/2.0/bundle' > out.requests_restore_original.json trace $CLI bundle plan diff --git a/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.plan.direct.json b/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.plan.direct.json rename to acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.plan.json diff --git a/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.plan.terraform.json b/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.plan.terraform.json deleted file mode 100644 index 6e230f7e0e1..00000000000 --- a/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.postgres_projects.foo": { - "action": "create" - }, - "resources.postgres_projects.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.requests.deploy.terraform.json deleted file mode 100644 index f554e966ccc..00000000000 --- a/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.requests.deploy.terraform.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/database-projects/test-project", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_USE", - "user_name": "viewer@example.com" - }, - { - "permission_level": "CAN_MANAGE", - "service_principal_name": "[UUID]" - }, - { - "group_name": "data-team", - "permission_level": "CAN_MANAGE" - }, - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.requests.destroy.direct.json deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.requests.destroy.direct.json rename to acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.requests.destroy.terraform.json deleted file mode 100644 index 1df0a7fbeb0..00000000000 --- a/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.requests.destroy.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/database-projects/test-project", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.test.toml b/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.test.toml +++ b/acceptance/bundle/resources/permissions/postgres_projects/current_can_manage/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/script b/acceptance/bundle/resources/permissions/script deleted file mode 100644 index 6f7ce5fd609..00000000000 --- a/acceptance/bundle/resources/permissions/script +++ /dev/null @@ -1 +0,0 @@ -./analyze_requests.py diff --git a/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.plan.direct.json b/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.plan.direct.json rename to acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.plan.json diff --git a/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.plan.terraform.json b/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.plan.terraform.json deleted file mode 100644 index 385344340e8..00000000000 --- a/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.sql_warehouses.foo": { - "action": "create" - }, - "resources.sql_warehouses.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.requests.deploy.terraform.json b/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.requests.deploy.terraform.json deleted file mode 100644 index 6a598e5f14c..00000000000 --- a/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.requests.deploy.terraform.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/sql/warehouses/[UUID]", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_VIEW", - "user_name": "viewer@example.com" - }, - { - "permission_level": "CAN_MANAGE", - "service_principal_name": "[UUID]" - }, - { - "group_name": "data-team", - "permission_level": "CAN_MANAGE" - }, - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.requests.destroy.direct.json deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/current_is_owner/out.requests.destroy.terraform.json rename to acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.requests.destroy.terraform.json b/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.requests.destroy.terraform.json deleted file mode 100644 index 2abb177cb6c..00000000000 --- a/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.requests.destroy.terraform.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/sql/warehouses/[UUID]", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - }, - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.test.toml b/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.test.toml +++ b/acceptance/bundle/resources/permissions/sql_warehouses/current_can_manage/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/target_permissions/out.plan.direct.json b/acceptance/bundle/resources/permissions/target_permissions/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/target_permissions/out.plan.direct.json rename to acceptance/bundle/resources/permissions/target_permissions/out.plan.json diff --git a/acceptance/bundle/resources/permissions/target_permissions/out.plan.terraform.json b/acceptance/bundle/resources/permissions/target_permissions/out.plan.terraform.json deleted file mode 100644 index 0db00e350f8..00000000000 --- a/acceptance/bundle/resources/permissions/target_permissions/out.plan.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.foo": { - "action": "create" - }, - "resources.jobs.foo.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/permissions/target_permissions/out.requests_create.direct.json b/acceptance/bundle/resources/permissions/target_permissions/out.requests_create.json similarity index 100% rename from acceptance/bundle/resources/permissions/target_permissions/out.requests_create.direct.json rename to acceptance/bundle/resources/permissions/target_permissions/out.requests_create.json diff --git a/acceptance/bundle/resources/permissions/target_permissions/out.requests_create.terraform.json b/acceptance/bundle/resources/permissions/target_permissions/out.requests_create.terraform.json deleted file mode 100644 index 3c028edebe1..00000000000 --- a/acceptance/bundle/resources/permissions/target_permissions/out.requests_create.terraform.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.2/jobs/create", - "body": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/test-bundle/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "foo", - "queue": { - "enabled": true - }, - "tasks": [ - { - "notebook_task": { - "notebook_path": "/Workspace/Users/user@example.com/notebook", - "source": "WORKSPACE" - }, - "task_key": "main" - } - ] - } -} -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/resources/permissions/target_permissions/out.requests_delete.direct.json b/acceptance/bundle/resources/permissions/target_permissions/out.requests_delete.json similarity index 100% rename from acceptance/bundle/resources/permissions/target_permissions/out.requests_delete.direct.json rename to acceptance/bundle/resources/permissions/target_permissions/out.requests_delete.json diff --git a/acceptance/bundle/resources/permissions/target_permissions/out.requests_delete.terraform.json b/acceptance/bundle/resources/permissions/target_permissions/out.requests_delete.terraform.json deleted file mode 100644 index cd29de0d552..00000000000 --- a/acceptance/bundle/resources/permissions/target_permissions/out.requests_delete.terraform.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} -{ - "method": "POST", - "path": "/api/2.2/jobs/delete", - "body": { - "job_id": [NUMID] - } -} diff --git a/acceptance/bundle/resources/permissions/target_permissions/out.test.toml b/acceptance/bundle/resources/permissions/target_permissions/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/target_permissions/out.test.toml +++ b/acceptance/bundle/resources/permissions/target_permissions/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/target_permissions/script b/acceptance/bundle/resources/permissions/target_permissions/script index 7a443d8cc2d..b6190da18d1 100644 --- a/acceptance/bundle/resources/permissions/target_permissions/script +++ b/acceptance/bundle/resources/permissions/target_permissions/script @@ -1,7 +1,7 @@ trace $CLI bundle plan -$CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan.json trace $CLI bundle deploy -print_requests.py --nostamp //jobs/ > out.requests_create.$DATABRICKS_BUNDLE_ENGINE.json +print_requests.py --nostamp //jobs/ > out.requests_create.json trace $CLI bundle destroy --auto-approve -print_requests.py --nostamp //jobs/ > out.requests_delete.$DATABRICKS_BUNDLE_ENGINE.json +print_requests.py --nostamp //jobs/ > out.requests_delete.json diff --git a/acceptance/bundle/resources/permissions/vector_search_endpoints/current_can_manage/out.plan.direct.json b/acceptance/bundle/resources/permissions/vector_search_endpoints/current_can_manage/out.plan.json similarity index 100% rename from acceptance/bundle/resources/permissions/vector_search_endpoints/current_can_manage/out.plan.direct.json rename to acceptance/bundle/resources/permissions/vector_search_endpoints/current_can_manage/out.plan.json diff --git a/acceptance/bundle/resources/permissions/vector_search_endpoints/current_can_manage/out.requests.deploy.direct.json b/acceptance/bundle/resources/permissions/vector_search_endpoints/current_can_manage/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/permissions/vector_search_endpoints/current_can_manage/out.requests.deploy.direct.json rename to acceptance/bundle/resources/permissions/vector_search_endpoints/current_can_manage/out.requests.deploy.json diff --git a/acceptance/bundle/resources/permissions/vector_search_endpoints/current_can_manage/out.requests.destroy.direct.json b/acceptance/bundle/resources/permissions/vector_search_endpoints/current_can_manage/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/permissions/vector_search_endpoints/current_can_manage/out.requests.destroy.direct.json rename to acceptance/bundle/resources/permissions/vector_search_endpoints/current_can_manage/out.requests.destroy.json diff --git a/acceptance/bundle/resources/permissions/vector_search_endpoints/current_can_manage/out.test.toml b/acceptance/bundle/resources/permissions/vector_search_endpoints/current_can_manage/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/permissions/vector_search_endpoints/current_can_manage/out.test.toml +++ b/acceptance/bundle/resources/permissions/vector_search_endpoints/current_can_manage/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/permissions/vector_search_endpoints/test.toml b/acceptance/bundle/resources/permissions/vector_search_endpoints/test.toml index 1217a2ec963..4883bba5cd4 100644 --- a/acceptance/bundle/resources/permissions/vector_search_endpoints/test.toml +++ b/acceptance/bundle/resources/permissions/vector_search_endpoints/test.toml @@ -1,2 +1 @@ Env.RESOURCE = "vector_search_endpoints" # for ../_script -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/pipelines/allow-duplicate-names/out.test.toml b/acceptance/bundle/resources/pipelines/allow-duplicate-names/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/pipelines/allow-duplicate-names/out.test.toml +++ b/acceptance/bundle/resources/pipelines/allow-duplicate-names/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/pipelines/auto-approve/out.test.toml b/acceptance/bundle/resources/pipelines/auto-approve/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/pipelines/auto-approve/out.test.toml +++ b/acceptance/bundle/resources/pipelines/auto-approve/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/pipelines/cluster_policy/out.test.toml b/acceptance/bundle/resources/pipelines/cluster_policy/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/pipelines/cluster_policy/out.test.toml +++ b/acceptance/bundle/resources/pipelines/cluster_policy/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/pipelines/cluster_policy/test.toml b/acceptance/bundle/resources/pipelines/cluster_policy/test.toml index 6131aeaf3a2..02a953b2373 100644 --- a/acceptance/bundle/resources/pipelines/cluster_policy/test.toml +++ b/acceptance/bundle/resources/pipelines/cluster_policy/test.toml @@ -1,5 +1,4 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] RecordRequests = false diff --git a/acceptance/bundle/resources/pipelines/drift/parameters/out.test.toml b/acceptance/bundle/resources/pipelines/drift/parameters/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/pipelines/drift/parameters/out.test.toml +++ b/acceptance/bundle/resources/pipelines/drift/parameters/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/pipelines/drift/parameters/test.toml b/acceptance/bundle/resources/pipelines/drift/parameters/test.toml index 90122785fcf..db3c3dd039d 100644 --- a/acceptance/bundle/resources/pipelines/drift/parameters/test.toml +++ b/acceptance/bundle/resources/pipelines/drift/parameters/test.toml @@ -2,4 +2,3 @@ RecordRequests = true # Direct engine only: the gap is in its read-back path (GetPipelineResponse.Parameters). # Terraform tracks parameters in its own state. Mirrors catalogs/drift/managed_properties. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/pipelines/lakeflow-pipeline/out.test.toml b/acceptance/bundle/resources/pipelines/lakeflow-pipeline/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/pipelines/lakeflow-pipeline/out.test.toml +++ b/acceptance/bundle/resources/pipelines/lakeflow-pipeline/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/pipelines/num-workers-zero/out.requests.terraform.txt b/acceptance/bundle/resources/pipelines/num-workers-zero/out.requests.terraform.txt deleted file mode 100644 index e1ec34db0bb..00000000000 --- a/acceptance/bundle/resources/pipelines/num-workers-zero/out.requests.terraform.txt +++ /dev/null @@ -1,34 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/pipelines", - "body": { - "channel": "CURRENT", - "clusters": [ - { - "custom_tags": { - "ResourceClass": "SingleNode" - }, - "label": "default", - "node_type_id": "[NODE_TYPE_ID]", - "num_workers": 0, - "spark_conf": { - "spark.databricks.cluster.profile": "singleNode", - "spark.master": "local[*]" - } - } - ], - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/num-workers-zero/default/state/metadata.json" - }, - "edition": "ADVANCED", - "libraries": [ - { - "file": { - "path": "/Workspace/Users/[USERNAME]/.bundle/num-workers-zero/default/files/foo.py" - } - } - ], - "name": "test-pipeline" - } -} diff --git a/acceptance/bundle/resources/pipelines/num-workers-zero/out.requests.direct.txt b/acceptance/bundle/resources/pipelines/num-workers-zero/out.requests.txt similarity index 100% rename from acceptance/bundle/resources/pipelines/num-workers-zero/out.requests.direct.txt rename to acceptance/bundle/resources/pipelines/num-workers-zero/out.requests.txt diff --git a/acceptance/bundle/resources/pipelines/num-workers-zero/out.test.toml b/acceptance/bundle/resources/pipelines/num-workers-zero/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/pipelines/num-workers-zero/out.test.toml +++ b/acceptance/bundle/resources/pipelines/num-workers-zero/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/pipelines/num-workers-zero/script b/acceptance/bundle/resources/pipelines/num-workers-zero/script index c6b80aea392..f7167174881 100644 --- a/acceptance/bundle/resources/pipelines/num-workers-zero/script +++ b/acceptance/bundle/resources/pipelines/num-workers-zero/script @@ -1,3 +1,3 @@ trace $CLI bundle deploy > out.deploy.txt 2>&1 -trace errcode jq -s '.[] | select(.method == "POST" and (.path | contains("/pipelines")))' "$OUT_REQUESTS" | nostamp > out.requests.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 +trace errcode jq -s '.[] | select(.method == "POST" and (.path | contains("/pipelines")))' "$OUT_REQUESTS" | nostamp > out.requests.txt 2>&1 rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/resources/pipelines/num-workers-zero/test.toml b/acceptance/bundle/resources/pipelines/num-workers-zero/test.toml index deed8f1f1e6..76325e19857 100644 --- a/acceptance/bundle/resources/pipelines/num-workers-zero/test.toml +++ b/acceptance/bundle/resources/pipelines/num-workers-zero/test.toml @@ -1,5 +1,3 @@ Badness = "num_workers value 0 is not sent in the direct deployment" Cloud = false RecordRequests = true - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/bundle/resources/pipelines/photon-true/out.test.toml b/acceptance/bundle/resources/pipelines/photon-true/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/pipelines/photon-true/out.test.toml +++ b/acceptance/bundle/resources/pipelines/photon-true/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/pipelines/photon-true/test.toml b/acceptance/bundle/resources/pipelines/photon-true/test.toml index cd6d347f601..7061886de47 100644 --- a/acceptance/bundle/resources/pipelines/photon-true/test.toml +++ b/acceptance/bundle/resources/pipelines/photon-true/test.toml @@ -1,4 +1,2 @@ Cloud = false RecordRequests = true - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/bundle/resources/pipelines/recreate-add-whole-block/out.plan.direct.json b/acceptance/bundle/resources/pipelines/recreate-add-whole-block/out.plan.json similarity index 100% rename from acceptance/bundle/resources/pipelines/recreate-add-whole-block/out.plan.direct.json rename to acceptance/bundle/resources/pipelines/recreate-add-whole-block/out.plan.json diff --git a/acceptance/bundle/resources/pipelines/recreate-add-whole-block/out.plan.terraform.json b/acceptance/bundle/resources/pipelines/recreate-add-whole-block/out.plan.terraform.json deleted file mode 100644 index 46f00cab517..00000000000 --- a/acceptance/bundle/resources/pipelines/recreate-add-whole-block/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.my": { - "action": "recreate" - } - } -} diff --git a/acceptance/bundle/resources/pipelines/recreate-add-whole-block/out.test.toml b/acceptance/bundle/resources/pipelines/recreate-add-whole-block/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/pipelines/recreate-add-whole-block/out.test.toml +++ b/acceptance/bundle/resources/pipelines/recreate-add-whole-block/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/pipelines/recreate-add-whole-block/script b/acceptance/bundle/resources/pipelines/recreate-add-whole-block/script index 9d56b42744f..a9d77523018 100644 --- a/acceptance/bundle/resources/pipelines/recreate-add-whole-block/script +++ b/acceptance/bundle/resources/pipelines/recreate-add-whole-block/script @@ -12,6 +12,6 @@ trace update_file.py databricks.yml "#TO_ADD: " "" # Both engines recreate. structdiff records the added block as one change at # "ingestion_definition"; bidirectional rule matching relates that to the recreate # rule on the connection_name leaf. See the per-engine "changes"/"action" in the JSON. -$CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan.json rm -f "$OUT_REQUESTS" diff --git a/acceptance/bundle/resources/pipelines/recreate-add-whole-block/test.toml b/acceptance/bundle/resources/pipelines/recreate-add-whole-block/test.toml index 86f874c8578..9b05d63bc36 100644 --- a/acceptance/bundle/resources/pipelines/recreate-add-whole-block/test.toml +++ b/acceptance/bundle/resources/pipelines/recreate-add-whole-block/test.toml @@ -1,5 +1,5 @@ # Runs on both engines: both recreate (connection_name is immutable). The direct -# plan's per-engine "changes" map (out.plan.direct.json) shows the recreate keyed on +# plan's per-engine "changes" map (out.plan.json) shows the recreate keyed on # the ingestion_definition block via bidirectional rule matching; terraform's plan # JSON just carries the action. Ignore = ["foo.py", ".databricks"] diff --git a/acceptance/bundle/resources/pipelines/recreate-keys/_script b/acceptance/bundle/resources/pipelines/recreate-keys/_script index 00be2fd3e53..c0c25bfafb9 100644 --- a/acceptance/bundle/resources/pipelines/recreate-keys/_script +++ b/acceptance/bundle/resources/pipelines/recreate-keys/_script @@ -2,7 +2,7 @@ trace cat databricks.yml touch foo.py touch bar.py trace $CLI bundle plan # should show 'create' -$CLI bundle plan -o json | nostamp.py > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp.py > out.plan_create.json trace $CLI bundle deploy ppid1=`read_id.py my` @@ -18,7 +18,7 @@ trace print_requests trace update_file.py databricks.yml $CONFIG_UPDATE trace $CLI bundle plan # should show 'recreate' -$CLI bundle plan -o json | nostamp.py > out.plan_recreate.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp.py > out.plan_recreate.json trace $CLI bundle deploy --auto-approve trace print_requests diff --git a/acceptance/bundle/resources/pipelines/recreate-keys/change-ingestion-definition/out.plan_create.direct.json b/acceptance/bundle/resources/pipelines/recreate-keys/change-ingestion-definition/out.plan_create.json similarity index 100% rename from acceptance/bundle/resources/pipelines/recreate-keys/change-ingestion-definition/out.plan_create.direct.json rename to acceptance/bundle/resources/pipelines/recreate-keys/change-ingestion-definition/out.plan_create.json diff --git a/acceptance/bundle/resources/pipelines/recreate-keys/change-ingestion-definition/out.plan_create.terraform.json b/acceptance/bundle/resources/pipelines/recreate-keys/change-ingestion-definition/out.plan_create.terraform.json deleted file mode 100644 index 7f67dd1d8e2..00000000000 --- a/acceptance/bundle/resources/pipelines/recreate-keys/change-ingestion-definition/out.plan_create.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.my": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/pipelines/recreate-keys/change-ingestion-definition/out.plan_recreate.direct.json b/acceptance/bundle/resources/pipelines/recreate-keys/change-ingestion-definition/out.plan_recreate.json similarity index 100% rename from acceptance/bundle/resources/pipelines/recreate-keys/change-ingestion-definition/out.plan_recreate.direct.json rename to acceptance/bundle/resources/pipelines/recreate-keys/change-ingestion-definition/out.plan_recreate.json diff --git a/acceptance/bundle/resources/pipelines/recreate-keys/change-ingestion-definition/out.plan_recreate.terraform.json b/acceptance/bundle/resources/pipelines/recreate-keys/change-ingestion-definition/out.plan_recreate.terraform.json deleted file mode 100644 index 46f00cab517..00000000000 --- a/acceptance/bundle/resources/pipelines/recreate-keys/change-ingestion-definition/out.plan_recreate.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.my": { - "action": "recreate" - } - } -} diff --git a/acceptance/bundle/resources/pipelines/recreate-keys/change-ingestion-definition/out.test.toml b/acceptance/bundle/resources/pipelines/recreate-keys/change-ingestion-definition/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/pipelines/recreate-keys/change-ingestion-definition/out.test.toml +++ b/acceptance/bundle/resources/pipelines/recreate-keys/change-ingestion-definition/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/pipelines/recreate-keys/change-storage/out.plan_create.direct.json b/acceptance/bundle/resources/pipelines/recreate-keys/change-storage/out.plan_create.json similarity index 100% rename from acceptance/bundle/resources/pipelines/recreate-keys/change-storage/out.plan_create.direct.json rename to acceptance/bundle/resources/pipelines/recreate-keys/change-storage/out.plan_create.json diff --git a/acceptance/bundle/resources/pipelines/recreate-keys/change-storage/out.plan_create.terraform.json b/acceptance/bundle/resources/pipelines/recreate-keys/change-storage/out.plan_create.terraform.json deleted file mode 100644 index 7f67dd1d8e2..00000000000 --- a/acceptance/bundle/resources/pipelines/recreate-keys/change-storage/out.plan_create.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.my": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/pipelines/recreate-keys/change-storage/out.plan_recreate.direct.json b/acceptance/bundle/resources/pipelines/recreate-keys/change-storage/out.plan_recreate.json similarity index 100% rename from acceptance/bundle/resources/pipelines/recreate-keys/change-storage/out.plan_recreate.direct.json rename to acceptance/bundle/resources/pipelines/recreate-keys/change-storage/out.plan_recreate.json diff --git a/acceptance/bundle/resources/pipelines/recreate-keys/change-storage/out.plan_recreate.terraform.json b/acceptance/bundle/resources/pipelines/recreate-keys/change-storage/out.plan_recreate.terraform.json deleted file mode 100644 index 46f00cab517..00000000000 --- a/acceptance/bundle/resources/pipelines/recreate-keys/change-storage/out.plan_recreate.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.my": { - "action": "recreate" - } - } -} diff --git a/acceptance/bundle/resources/pipelines/recreate-keys/change-storage/out.test.toml b/acceptance/bundle/resources/pipelines/recreate-keys/change-storage/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/pipelines/recreate-keys/change-storage/out.test.toml +++ b/acceptance/bundle/resources/pipelines/recreate-keys/change-storage/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/pipelines/recreate-remove-whole-block/out.plan.direct.json b/acceptance/bundle/resources/pipelines/recreate-remove-whole-block/out.plan.json similarity index 100% rename from acceptance/bundle/resources/pipelines/recreate-remove-whole-block/out.plan.direct.json rename to acceptance/bundle/resources/pipelines/recreate-remove-whole-block/out.plan.json diff --git a/acceptance/bundle/resources/pipelines/recreate-remove-whole-block/out.plan.terraform.json b/acceptance/bundle/resources/pipelines/recreate-remove-whole-block/out.plan.terraform.json deleted file mode 100644 index 46f00cab517..00000000000 --- a/acceptance/bundle/resources/pipelines/recreate-remove-whole-block/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.my": { - "action": "recreate" - } - } -} diff --git a/acceptance/bundle/resources/pipelines/recreate-remove-whole-block/out.test.toml b/acceptance/bundle/resources/pipelines/recreate-remove-whole-block/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/pipelines/recreate-remove-whole-block/out.test.toml +++ b/acceptance/bundle/resources/pipelines/recreate-remove-whole-block/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/pipelines/recreate-remove-whole-block/script b/acceptance/bundle/resources/pipelines/recreate-remove-whole-block/script index edc3801d5ca..b35805ec5b6 100644 --- a/acceptance/bundle/resources/pipelines/recreate-remove-whole-block/script +++ b/acceptance/bundle/resources/pipelines/recreate-remove-whole-block/script @@ -12,6 +12,6 @@ grep -v '# TO_DELETE' databricks.yml > databricks.yml.tmp && mv databricks.yml.t # Both engines recreate. structdiff records the removed block as one change at # "ingestion_definition"; bidirectional rule matching relates that to the recreate # rule on the connection_name leaf. See the per-engine "changes"/"action" in the JSON. -$CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan.json rm -f "$OUT_REQUESTS" diff --git a/acceptance/bundle/resources/pipelines/recreate-remove-whole-block/test.toml b/acceptance/bundle/resources/pipelines/recreate-remove-whole-block/test.toml index 86f874c8578..9b05d63bc36 100644 --- a/acceptance/bundle/resources/pipelines/recreate-remove-whole-block/test.toml +++ b/acceptance/bundle/resources/pipelines/recreate-remove-whole-block/test.toml @@ -1,5 +1,5 @@ # Runs on both engines: both recreate (connection_name is immutable). The direct -# plan's per-engine "changes" map (out.plan.direct.json) shows the recreate keyed on +# plan's per-engine "changes" map (out.plan.json) shows the recreate keyed on # the ingestion_definition block via bidirectional rule matching; terraform's plan # JSON just carries the action. Ignore = ["foo.py", ".databricks"] diff --git a/acceptance/bundle/resources/pipelines/recreate/out.test.toml b/acceptance/bundle/resources/pipelines/recreate/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/pipelines/recreate/out.test.toml +++ b/acceptance/bundle/resources/pipelines/recreate/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/pipelines/remote_matches_config/out.plan.direct.json b/acceptance/bundle/resources/pipelines/remote_matches_config/out.plan.json similarity index 100% rename from acceptance/bundle/resources/pipelines/remote_matches_config/out.plan.direct.json rename to acceptance/bundle/resources/pipelines/remote_matches_config/out.plan.json diff --git a/acceptance/bundle/resources/pipelines/remote_matches_config/out.plan.terraform.json b/acceptance/bundle/resources/pipelines/remote_matches_config/out.plan.terraform.json deleted file mode 100644 index ae88ec10c4d..00000000000 --- a/acceptance/bundle/resources/pipelines/remote_matches_config/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.my_pipeline": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/pipelines/remote_matches_config/out.test.toml b/acceptance/bundle/resources/pipelines/remote_matches_config/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/pipelines/remote_matches_config/out.test.toml +++ b/acceptance/bundle/resources/pipelines/remote_matches_config/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/pipelines/remote_matches_config/script b/acceptance/bundle/resources/pipelines/remote_matches_config/script index a7a8ad692aa..ae9f48c53bc 100644 --- a/acceptance/bundle/resources/pipelines/remote_matches_config/script +++ b/acceptance/bundle/resources/pipelines/remote_matches_config/script @@ -15,6 +15,6 @@ r["run_as"] = {"user_name": "changed@example.test"} EOF trace $CLI bundle plan -$CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan.json rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/resources/pipelines/update/out.test.toml b/acceptance/bundle/resources/pipelines/update/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/pipelines/update/out.test.toml +++ b/acceptance/bundle/resources/pipelines/update/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/pipelines/zero-value-fields/out.requests.terraform.txt b/acceptance/bundle/resources/pipelines/zero-value-fields/out.requests.terraform.txt deleted file mode 100644 index 2975d5a1958..00000000000 --- a/acceptance/bundle/resources/pipelines/zero-value-fields/out.requests.terraform.txt +++ /dev/null @@ -1,20 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/pipelines", - "body": { - "channel": "CURRENT", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/zero-value-fields/default/state/metadata.json" - }, - "edition": "ADVANCED", - "libraries": [ - { - "file": { - "path": "/Workspace/Users/[USERNAME]/.bundle/zero-value-fields/default/files/foo.py" - } - } - ], - "name": "test-pipeline" - } -} diff --git a/acceptance/bundle/resources/pipelines/zero-value-fields/out.requests.direct.txt b/acceptance/bundle/resources/pipelines/zero-value-fields/out.requests.txt similarity index 100% rename from acceptance/bundle/resources/pipelines/zero-value-fields/out.requests.direct.txt rename to acceptance/bundle/resources/pipelines/zero-value-fields/out.requests.txt diff --git a/acceptance/bundle/resources/pipelines/zero-value-fields/out.test.toml b/acceptance/bundle/resources/pipelines/zero-value-fields/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/pipelines/zero-value-fields/out.test.toml +++ b/acceptance/bundle/resources/pipelines/zero-value-fields/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/pipelines/zero-value-fields/out.tf.terraform.json b/acceptance/bundle/resources/pipelines/zero-value-fields/out.tf.terraform.json deleted file mode 100644 index 26a43c316f6..00000000000 --- a/acceptance/bundle/resources/pipelines/zero-value-fields/out.tf.terraform.json +++ /dev/null @@ -1,22 +0,0 @@ -{ - "my": { - "channel": "CURRENT", - "continuous": false, - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/zero-value-fields/default/state/metadata.json" - }, - "development": false, - "edition": "ADVANCED", - "library": [ - { - "file": { - "path": "/Workspace/Users/[USERNAME]/.bundle/zero-value-fields/default/files/foo.py" - } - } - ], - "name": "test-pipeline", - "photon": false, - "serverless": false - } -} diff --git a/acceptance/bundle/resources/pipelines/zero-value-fields/script b/acceptance/bundle/resources/pipelines/zero-value-fields/script index ef7e886ea01..4e434e92bf9 100644 --- a/acceptance/bundle/resources/pipelines/zero-value-fields/script +++ b/acceptance/bundle/resources/pipelines/zero-value-fields/script @@ -1,6 +1,6 @@ trace $CLI bundle deploy -print_requests.py --nostamp //api/2.0/pipelines > out.requests.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 +print_requests.py --nostamp //api/2.0/pipelines > out.requests.txt 2>&1 if [ -f .databricks/bundle/default/terraform/bundle.tf.json ]; then - jq .resource.databricks_pipeline .databricks/bundle/default/terraform/bundle.tf.json > out.tf.$DATABRICKS_BUNDLE_ENGINE.json + jq .resource.databricks_pipeline .databricks/bundle/default/terraform/bundle.tf.json > out.tf.json fi diff --git a/acceptance/bundle/resources/pipelines/zero-value-fields/test.toml b/acceptance/bundle/resources/pipelines/zero-value-fields/test.toml index f08ec564fc9..a6860e07879 100644 --- a/acceptance/bundle/resources/pipelines/zero-value-fields/test.toml +++ b/acceptance/bundle/resources/pipelines/zero-value-fields/test.toml @@ -1,5 +1,3 @@ Badness = "zero-value bool fields (photon, serverless, continuous, development) are not sent in the terraform deployment" Cloud = false RecordRequests = true - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/bundle/resources/postgres_branches/basic/out.requests.direct.json b/acceptance/bundle/resources/postgres_branches/basic/out.requests.json similarity index 100% rename from acceptance/bundle/resources/postgres_branches/basic/out.requests.direct.json rename to acceptance/bundle/resources/postgres_branches/basic/out.requests.json diff --git a/acceptance/bundle/resources/postgres_branches/basic/out.requests.terraform.json b/acceptance/bundle/resources/postgres_branches/basic/out.requests.terraform.json deleted file mode 100644 index ae5f9bab209..00000000000 --- a/acceptance/bundle/resources/postgres_branches/basic/out.requests.terraform.json +++ /dev/null @@ -1,36 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/postgres/projects", - "q": { - "project_id": "test-pg-proj-[UNIQUE_NAME]" - }, - "body": { - "spec": { - "default_endpoint_settings": { - "autoscaling_limit_max_cu": 4, - "autoscaling_limit_min_cu": 0.5, - "suspend_timeout_duration": "300s" - }, - "display_name": "Test Project for Branch", - "history_retention_duration": "604800s", - "pg_version": 16 - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches", - "q": { - "branch_id": "main" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "no_expiry": true - } - } -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main" -} diff --git a/acceptance/bundle/resources/postgres_branches/basic/out.test.toml b/acceptance/bundle/resources/postgres_branches/basic/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_branches/basic/out.test.toml +++ b/acceptance/bundle/resources/postgres_branches/basic/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_branches/basic/script b/acceptance/bundle/resources/postgres_branches/basic/script index 62f1e62c390..5e498ea738e 100644 --- a/acceptance/bundle/resources/postgres_branches/basic/script +++ b/acceptance/bundle/resources/postgres_branches/basic/script @@ -21,4 +21,4 @@ trace $CLI postgres get-branch "${branch_name}" | branch_fields trace $CLI bundle summary # Filter requests to only show postgres operations (exclude workspace, telemetry, and operation polling) -trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.json diff --git a/acceptance/bundle/resources/postgres_branches/purge_on_delete/out.requests.deploy.direct.json b/acceptance/bundle/resources/postgres_branches/purge_on_delete/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/postgres_branches/purge_on_delete/out.requests.deploy.direct.json rename to acceptance/bundle/resources/postgres_branches/purge_on_delete/out.requests.deploy.json diff --git a/acceptance/bundle/resources/postgres_branches/purge_on_delete/out.requests.deploy.terraform.json b/acceptance/bundle/resources/postgres_branches/purge_on_delete/out.requests.deploy.terraform.json deleted file mode 100644 index 01ff62d44c0..00000000000 --- a/acceptance/bundle/resources/postgres_branches/purge_on_delete/out.requests.deploy.terraform.json +++ /dev/null @@ -1,47 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/test-pg-branch-hard-[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/test-pg-branch-soft-[UNIQUE_NAME]" -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects", - "q": { - "project_id": "test-pg-proj-[UNIQUE_NAME]" - }, - "body": { - "spec": { - "display_name": "Test Project for Branch purge_on_delete", - "pg_version": 16 - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches", - "q": { - "branch_id": "test-pg-branch-hard-[UNIQUE_NAME]" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "no_expiry": true - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches", - "q": { - "branch_id": "test-pg-branch-soft-[UNIQUE_NAME]" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "no_expiry": true - } - } -} diff --git a/acceptance/bundle/resources/postgres_branches/purge_on_delete/out.test.toml b/acceptance/bundle/resources/postgres_branches/purge_on_delete/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_branches/purge_on_delete/out.test.toml +++ b/acceptance/bundle/resources/postgres_branches/purge_on_delete/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_branches/purge_on_delete/script b/acceptance/bundle/resources/postgres_branches/purge_on_delete/script index 1b45f3f0d55..0a0b9b67823 100644 --- a/acceptance/bundle/resources/postgres_branches/purge_on_delete/script +++ b/acceptance/bundle/resources/postgres_branches/purge_on_delete/script @@ -24,7 +24,7 @@ trace $CLI postgres get-branch "${soft_branch}" | branch_fields # Deploy requests are split per-engine: Terraform sends "parent" in the branch # create body, the direct engine sends it only as a query parameter. -trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --sort --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.deploy.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --sort --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.deploy.json # bundle destroy should send ?purge=true on the hard_delete branch and no # purge query on the soft_delete branch. Both DELETEs land in the recorded diff --git a/acceptance/bundle/resources/postgres_branches/purge_on_delete_transitions/out.test.toml b/acceptance/bundle/resources/postgres_branches/purge_on_delete_transitions/out.test.toml index 7ad46517eca..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_branches/purge_on_delete_transitions/out.test.toml +++ b/acceptance/bundle/resources/postgres_branches/purge_on_delete_transitions/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_branches/purge_on_delete_transitions/test.toml b/acceptance/bundle/resources/postgres_branches/purge_on_delete_transitions/test.toml deleted file mode 100644 index 797a2d57508..00000000000 --- a/acceptance/bundle/resources/postgres_branches/purge_on_delete_transitions/test.toml +++ /dev/null @@ -1,4 +0,0 @@ -# Direct engine only: this test exercises the FSF preservation in -# PrepareState and direct's plan/diff classification when the user flips -# purge_on_delete. Terraform has its own provider-managed state lifecycle. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/postgres_branches/recreate/out.test.toml b/acceptance/bundle/resources/postgres_branches/recreate/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_branches/recreate/out.test.toml +++ b/acceptance/bundle/resources/postgres_branches/recreate/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/out.plan.direct.json b/acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/out.plan.json similarity index 100% rename from acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/out.plan.direct.json rename to acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/out.plan.json diff --git a/acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/out.plan.terraform.json b/acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/out.plan.terraform.json deleted file mode 100644 index 254ce155a8f..00000000000 --- a/acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/out.plan.terraform.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "action": "recreate", - "changes": null -} diff --git a/acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/out.requests.direct.json b/acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/out.requests.json similarity index 100% rename from acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/out.requests.direct.json rename to acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/out.requests.json diff --git a/acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/out.requests.terraform.json b/acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/out.requests.terraform.json deleted file mode 100644 index e989d9e6b8f..00000000000 --- a/acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/out.requests.terraform.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "method": "DELETE", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/dev-branch" -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches", - "q": { - "branch_id": "dev-branch" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "no_expiry": true, - "source_branch": "projects/test-pg-proj-[UNIQUE_NAME]/branches/production", - "source_branch_time": "[FORK_TIME_AFTER]" - } - } -} diff --git a/acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/out.test.toml b/acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/out.test.toml index 7c3e0eb2e42..0faf51e59a4 100644 --- a/acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/out.test.toml +++ b/acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/out.test.toml @@ -1,5 +1,4 @@ Cloud = false CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/script b/acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/script index 9226792166d..77aa4e0319b 100644 --- a/acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/script +++ b/acceptance/bundle/resources/postgres_branches/recreate_source_branch_time/script @@ -13,7 +13,7 @@ rm -f "$OUT_REQUESTS" title "Change the fork point: source_branch_time is immutable, so this recreates" trace update_file.py databricks.yml "2026-01-01T00:00:00Z" "2026-02-01T00:00:00Z" trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_branches.dev_branch" | {action, changes}' > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_branches.dev_branch" | {action, changes}' > out.plan.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy --auto-approve -trace print_requests.py --del-body project_id,branch_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id,branch_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.json diff --git a/acceptance/bundle/resources/postgres_branches/replace_existing/out.requests.deploy.direct.json b/acceptance/bundle/resources/postgres_branches/replace_existing/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/postgres_branches/replace_existing/out.requests.deploy.direct.json rename to acceptance/bundle/resources/postgres_branches/replace_existing/out.requests.deploy.json diff --git a/acceptance/bundle/resources/postgres_branches/replace_existing/out.requests.deploy.terraform.json b/acceptance/bundle/resources/postgres_branches/replace_existing/out.requests.deploy.terraform.json deleted file mode 100644 index f70714acb2b..00000000000 --- a/acceptance/bundle/resources/postgres_branches/replace_existing/out.requests.deploy.terraform.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/postgres/projects", - "q": { - "project_id": "test-pg-proj-[UNIQUE_NAME]" - }, - "body": { - "spec": { - "display_name": "Replace existing branch test", - "history_retention_duration": "604800s", - "pg_version": 16 - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches", - "q": { - "branch_id": "production", - "replace_existing": "true" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "no_expiry": true - } - } -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/production" -} diff --git a/acceptance/bundle/resources/postgres_branches/replace_existing/out.requests.destroy.direct.json b/acceptance/bundle/resources/postgres_branches/replace_existing/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/postgres_branches/replace_existing/out.requests.destroy.direct.json rename to acceptance/bundle/resources/postgres_branches/replace_existing/out.requests.destroy.json diff --git a/acceptance/bundle/resources/postgres_branches/replace_existing/out.requests.destroy.terraform.json b/acceptance/bundle/resources/postgres_branches/replace_existing/out.requests.destroy.terraform.json deleted file mode 100644 index ad6e8580927..00000000000 --- a/acceptance/bundle/resources/postgres_branches/replace_existing/out.requests.destroy.terraform.json +++ /dev/null @@ -1,48 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/postgres/projects", - "q": { - "project_id": "test-pg-proj-[UNIQUE_NAME]" - }, - "body": { - "spec": { - "display_name": "Replace existing branch test", - "history_retention_duration": "604800s", - "pg_version": 16 - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches", - "q": { - "branch_id": "production", - "replace_existing": "true" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "no_expiry": true - } - } -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/production" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/production" -} -{ - "method": "DELETE", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/production" -} -{ - "method": "DELETE", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]" -} diff --git a/acceptance/bundle/resources/postgres_branches/replace_existing/out.test.toml b/acceptance/bundle/resources/postgres_branches/replace_existing/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_branches/replace_existing/out.test.toml +++ b/acceptance/bundle/resources/postgres_branches/replace_existing/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_branches/replace_existing/script b/acceptance/bundle/resources/postgres_branches/replace_existing/script index c2e891fc326..e6e017e634e 100644 --- a/acceptance/bundle/resources/postgres_branches/replace_existing/script +++ b/acceptance/bundle/resources/postgres_branches/replace_existing/script @@ -15,7 +15,7 @@ trace $CLI bundle deploy # Confirm the implicit production branch is now under management. trace $CLI postgres get-branch "projects/test-pg-proj-${UNIQUE_NAME}/branches/production" | branch_fields -trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.deploy.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.deploy.json # bundle destroy: the backend rejects independent deletion of the root # branch with a MANAGED_BY_PARENT marker; both engines disregard that @@ -25,4 +25,4 @@ trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id, title "bundle destroy" $CLI bundle destroy --auto-approve > out.destroy.txt 2>&1 || true -trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.destroy.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.destroy.json diff --git a/acceptance/bundle/resources/postgres_branches/test.toml b/acceptance/bundle/resources/postgres_branches/test.toml index 6a939ff9d33..c6e54bc122a 100644 --- a/acceptance/bundle/resources/postgres_branches/test.toml +++ b/acceptance/bundle/resources/postgres_branches/test.toml @@ -5,7 +5,6 @@ CloudEnvs.gcp = false CloudEnvs.azure = false # Run on both direct and Terraform modes -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] Ignore = [ "databricks.yml", diff --git a/acceptance/bundle/resources/postgres_branches/update_expire_time/out.plan.direct.json b/acceptance/bundle/resources/postgres_branches/update_expire_time/out.plan.json similarity index 100% rename from acceptance/bundle/resources/postgres_branches/update_expire_time/out.plan.direct.json rename to acceptance/bundle/resources/postgres_branches/update_expire_time/out.plan.json diff --git a/acceptance/bundle/resources/postgres_branches/update_expire_time/out.plan.terraform.json b/acceptance/bundle/resources/postgres_branches/update_expire_time/out.plan.terraform.json deleted file mode 100644 index fb09ecaf88a..00000000000 --- a/acceptance/bundle/resources/postgres_branches/update_expire_time/out.plan.terraform.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "action": "update", - "changes": null -} diff --git a/acceptance/bundle/resources/postgres_branches/update_expire_time/out.requests.direct.json b/acceptance/bundle/resources/postgres_branches/update_expire_time/out.requests.json similarity index 100% rename from acceptance/bundle/resources/postgres_branches/update_expire_time/out.requests.direct.json rename to acceptance/bundle/resources/postgres_branches/update_expire_time/out.requests.json diff --git a/acceptance/bundle/resources/postgres_branches/update_expire_time/out.requests.terraform.json b/acceptance/bundle/resources/postgres_branches/update_expire_time/out.requests.terraform.json deleted file mode 100644 index 3ae000136b7..00000000000 --- a/acceptance/bundle/resources/postgres_branches/update_expire_time/out.requests.terraform.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/dev-branch", - "q": { - "update_mask": "spec" - }, - "body": { - "name": "projects/test-pg-proj-[UNIQUE_NAME]/branches/dev-branch", - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "expire_time": "[EXPIRE_TIME_AFTER]" - } - } -} diff --git a/acceptance/bundle/resources/postgres_branches/update_expire_time/out.test.toml b/acceptance/bundle/resources/postgres_branches/update_expire_time/out.test.toml index 7c3e0eb2e42..0faf51e59a4 100644 --- a/acceptance/bundle/resources/postgres_branches/update_expire_time/out.test.toml +++ b/acceptance/bundle/resources/postgres_branches/update_expire_time/out.test.toml @@ -1,5 +1,4 @@ Cloud = false CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_branches/update_expire_time/script b/acceptance/bundle/resources/postgres_branches/update_expire_time/script index 7a91ddb441b..efca002df59 100644 --- a/acceptance/bundle/resources/postgres_branches/update_expire_time/script +++ b/acceptance/bundle/resources/postgres_branches/update_expire_time/script @@ -19,8 +19,8 @@ trace update_file.py databricks.yml "2030-01-01T00:00:00Z" "2031-06-15T12:00:00Z # Only terraform applies it: expire_time is a member of the # expiration oneof, and the direct engine masks it under its own name. See test.toml. trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_branches.dev_branch" | {action, changes}' > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_branches.dev_branch" | {action, changes}' > out.plan.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy -trace print_requests.py --del-body project_id,branch_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id,branch_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.json trace $CLI postgres get-branch "${branch_name}" | branch_fields diff --git a/acceptance/bundle/resources/postgres_branches/update_expire_time/test.toml b/acceptance/bundle/resources/postgres_branches/update_expire_time/test.toml index b9330252d52..63fbbab85da 100644 --- a/acceptance/bundle/resources/postgres_branches/update_expire_time/test.toml +++ b/acceptance/bundle/resources/postgres_branches/update_expire_time/test.toml @@ -1,6 +1,6 @@ # expire_time, ttl and no_expiry are three sides of one oneof, and the API accepts them # in update_mask only under the group name spec.expiration. Both engines apply the change; -# out.requests.direct.json records the group mask the direct engine now sends. +# out.requests.json records the group mask the direct engine now sends. # Local only: a real workspace caps how far ahead a branch may expire and answers diff --git a/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.create.direct.json b/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.create.json similarity index 100% rename from acceptance/bundle/resources/postgres_branches/update_protected/out.plan.create.direct.json rename to acceptance/bundle/resources/postgres_branches/update_protected/out.plan.create.json diff --git a/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.create.terraform.json b/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.create.terraform.json deleted file mode 100644 index b4425b9687c..00000000000 --- a/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.create.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "create" -} diff --git a/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.no_change.direct.json b/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.no_change.json similarity index 100% rename from acceptance/bundle/resources/postgres_branches/update_protected/out.plan.no_change.direct.json rename to acceptance/bundle/resources/postgres_branches/update_protected/out.plan.no_change.json diff --git a/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.no_change.terraform.json b/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.no_change.terraform.json deleted file mode 100644 index b2f23a5015f..00000000000 --- a/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.no_change.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "skip" -} diff --git a/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.restore.direct.json b/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.restore.json similarity index 100% rename from acceptance/bundle/resources/postgres_branches/update_protected/out.plan.restore.direct.json rename to acceptance/bundle/resources/postgres_branches/update_protected/out.plan.restore.json diff --git a/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.restore.terraform.json b/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.restore.terraform.json deleted file mode 100644 index 375b496fef0..00000000000 --- a/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.restore.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "update" -} diff --git a/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.update.direct.json b/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.update.json similarity index 100% rename from acceptance/bundle/resources/postgres_branches/update_protected/out.plan.update.direct.json rename to acceptance/bundle/resources/postgres_branches/update_protected/out.plan.update.json diff --git a/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.update.terraform.json b/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.update.terraform.json deleted file mode 100644 index 375b496fef0..00000000000 --- a/acceptance/bundle/resources/postgres_branches/update_protected/out.plan.update.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "update" -} diff --git a/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.create.direct.json b/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.create.json similarity index 100% rename from acceptance/bundle/resources/postgres_branches/update_protected/out.requests.create.direct.json rename to acceptance/bundle/resources/postgres_branches/update_protected/out.requests.create.json diff --git a/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.create.terraform.json b/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.create.terraform.json deleted file mode 100644 index 26aee6e3936..00000000000 --- a/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.create.terraform.json +++ /dev/null @@ -1,33 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/postgres/projects", - "q": { - "project_id": "test-pg-proj-[UNIQUE_NAME]" - }, - "body": { - "spec": { - "default_endpoint_settings": { - "autoscaling_limit_max_cu": 4, - "autoscaling_limit_min_cu": 0.5, - "suspend_timeout_duration": "300s" - }, - "display_name": "Test Project for Branch Update", - "history_retention_duration": "604800s", - "pg_version": 16 - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches", - "q": { - "branch_id": "dev-branch" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "is_protected": false, - "no_expiry": true - } - } -} diff --git a/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.no_change.direct.json b/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.no_change.json similarity index 100% rename from acceptance/bundle/resources/postgres_branches/update_protected/out.requests.no_change.direct.json rename to acceptance/bundle/resources/postgres_branches/update_protected/out.requests.no_change.json diff --git a/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.no_change.terraform.json b/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.no_change.terraform.json deleted file mode 100644 index 23a3ae77747..00000000000 --- a/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.no_change.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/[DEV_BRANCH_ID]" -} diff --git a/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.restore.direct.json b/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.restore.json similarity index 100% rename from acceptance/bundle/resources/postgres_branches/update_protected/out.requests.restore.direct.json rename to acceptance/bundle/resources/postgres_branches/update_protected/out.requests.restore.json diff --git a/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.restore.terraform.json b/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.restore.terraform.json deleted file mode 100644 index 14a6068d6b3..00000000000 --- a/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.restore.terraform.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/[DEV_BRANCH_ID]" -} -{ - "method": "PATCH", - "path": "/api/2.0/postgres/[DEV_BRANCH_ID]", - "q": { - "update_mask": "spec" - }, - "body": { - "name": "[DEV_BRANCH_ID]", - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "is_protected": false, - "no_expiry": true - } - } -} diff --git a/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.update.direct.json b/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.update.json similarity index 100% rename from acceptance/bundle/resources/postgres_branches/update_protected/out.requests.update.direct.json rename to acceptance/bundle/resources/postgres_branches/update_protected/out.requests.update.json diff --git a/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.update.terraform.json b/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.update.terraform.json deleted file mode 100644 index 1fbae288953..00000000000 --- a/acceptance/bundle/resources/postgres_branches/update_protected/out.requests.update.terraform.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/[DEV_BRANCH_ID]" -} -{ - "method": "PATCH", - "path": "/api/2.0/postgres/[DEV_BRANCH_ID]", - "q": { - "update_mask": "spec" - }, - "body": { - "name": "[DEV_BRANCH_ID]", - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "is_protected": true, - "no_expiry": true - } - } -} diff --git a/acceptance/bundle/resources/postgres_branches/update_protected/out.test.toml b/acceptance/bundle/resources/postgres_branches/update_protected/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_branches/update_protected/out.test.toml +++ b/acceptance/bundle/resources/postgres_branches/update_protected/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_branches/update_protected/script b/acceptance/bundle/resources/postgres_branches/update_protected/script index 03cb63d3501..a773aef576b 100755 --- a/acceptance/bundle/resources/postgres_branches/update_protected/script +++ b/acceptance/bundle/resources/postgres_branches/update_protected/script @@ -8,14 +8,14 @@ trap cleanup EXIT print_requests() { local name=$1 - trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.${name}.$DATABRICKS_BUNDLE_ENGINE.json + trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.${name}.json rm -f "$OUT_REQUESTS" } title "Initial deployment" trace $CLI bundle validate trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_branches.dev_branch" // .' > out.plan.create.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_branches.dev_branch" // .' > out.plan.create.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy @@ -28,7 +28,7 @@ trace $CLI postgres get-branch "${branch_name}" | branch_fields title "Verify no_change (no changes)" trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '(.plan."resources.postgres_branches.dev_branch" // .) | del(.remote_state.status.logical_size_bytes)' > out.plan.no_change.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '(.plan."resources.postgres_branches.dev_branch" // .) | del(.remote_state.status.logical_size_bytes)' > out.plan.no_change.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy @@ -39,7 +39,7 @@ trace update_file.py databricks.yml "is_protected: false" "is_protected: true" trace cat databricks.yml trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '(.plan."resources.postgres_branches.dev_branch" // .) | del(.remote_state.status.logical_size_bytes)' > out.plan.update.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '(.plan."resources.postgres_branches.dev_branch" // .) | del(.remote_state.status.logical_size_bytes)' > out.plan.update.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy @@ -51,7 +51,7 @@ trace $CLI postgres get-branch "${branch_name}" | branch_fields title "Restore is_protected to false" trace update_file.py databricks.yml "is_protected: true" "is_protected: false" trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '(.plan."resources.postgres_branches.dev_branch" // .) | del(.remote_state.status.logical_size_bytes)' > out.plan.restore.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '(.plan."resources.postgres_branches.dev_branch" // .) | del(.remote_state.status.logical_size_bytes)' > out.plan.restore.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy diff --git a/acceptance/bundle/resources/postgres_branches/update_ttl/out.plan.direct.json b/acceptance/bundle/resources/postgres_branches/update_ttl/out.plan.json similarity index 100% rename from acceptance/bundle/resources/postgres_branches/update_ttl/out.plan.direct.json rename to acceptance/bundle/resources/postgres_branches/update_ttl/out.plan.json diff --git a/acceptance/bundle/resources/postgres_branches/update_ttl/out.plan.terraform.json b/acceptance/bundle/resources/postgres_branches/update_ttl/out.plan.terraform.json deleted file mode 100644 index fb09ecaf88a..00000000000 --- a/acceptance/bundle/resources/postgres_branches/update_ttl/out.plan.terraform.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "action": "update", - "changes": null -} diff --git a/acceptance/bundle/resources/postgres_branches/update_ttl/out.requests.direct.json b/acceptance/bundle/resources/postgres_branches/update_ttl/out.requests.json similarity index 100% rename from acceptance/bundle/resources/postgres_branches/update_ttl/out.requests.direct.json rename to acceptance/bundle/resources/postgres_branches/update_ttl/out.requests.json diff --git a/acceptance/bundle/resources/postgres_branches/update_ttl/out.requests.terraform.json b/acceptance/bundle/resources/postgres_branches/update_ttl/out.requests.terraform.json deleted file mode 100644 index f03f2b75777..00000000000 --- a/acceptance/bundle/resources/postgres_branches/update_ttl/out.requests.terraform.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/dev-branch", - "q": { - "update_mask": "spec" - }, - "body": { - "name": "projects/test-pg-proj-[UNIQUE_NAME]/branches/dev-branch", - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "ttl": "259200s" - } - } -} diff --git a/acceptance/bundle/resources/postgres_branches/update_ttl/out.test.toml b/acceptance/bundle/resources/postgres_branches/update_ttl/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_branches/update_ttl/out.test.toml +++ b/acceptance/bundle/resources/postgres_branches/update_ttl/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_branches/update_ttl/script b/acceptance/bundle/resources/postgres_branches/update_ttl/script index dc8f09e67b1..b73330e31c9 100644 --- a/acceptance/bundle/resources/postgres_branches/update_ttl/script +++ b/acceptance/bundle/resources/postgres_branches/update_ttl/script @@ -24,7 +24,7 @@ trace update_file.py databricks.yml "ttl: 604800s" "ttl: 259200s" # creation_time + ttl and never echoes ttl, which the testserver does not model. # The update_mask each engine sends is what this test is about. trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_branches.dev_branch" | {action, changes}' > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_branches.dev_branch" | {action, changes}' > out.plan.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy -trace print_requests.py --del-body project_id,branch_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id,branch_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.json diff --git a/acceptance/bundle/resources/postgres_branches/without_branch_id/out.deploy.terraform.txt b/acceptance/bundle/resources/postgres_branches/without_branch_id/out.deploy.terraform.txt deleted file mode 100644 index 169f720c9eb..00000000000 --- a/acceptance/bundle/resources/postgres_branches/without_branch_id/out.deploy.terraform.txt +++ /dev/null @@ -1,16 +0,0 @@ -Warning: required field "branch_id" is not set - at resources.postgres_branches.main - in databricks.yml:21:7 - -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/deploy-postgres-branch-no-id-[UNIQUE_NAME]/default/files... -Error: exit status 1 - -Error: Missing required argument - - on bundle.tf.json line 20, in resource.databricks_postgres_branch.main: - 20: } - -The argument "branch_id" is required, but no definition was found. - - -Files: 0 uploaded, 0 deleted diff --git a/acceptance/bundle/resources/postgres_branches/without_branch_id/out.deploy.direct.txt b/acceptance/bundle/resources/postgres_branches/without_branch_id/out.deploy.txt similarity index 100% rename from acceptance/bundle/resources/postgres_branches/without_branch_id/out.deploy.direct.txt rename to acceptance/bundle/resources/postgres_branches/without_branch_id/out.deploy.txt diff --git a/acceptance/bundle/resources/postgres_branches/without_branch_id/out.test.toml b/acceptance/bundle/resources/postgres_branches/without_branch_id/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_branches/without_branch_id/out.test.toml +++ b/acceptance/bundle/resources/postgres_branches/without_branch_id/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_branches/without_branch_id/script b/acceptance/bundle/resources/postgres_branches/without_branch_id/script index 6b718a8f22f..b707a1e7760 100755 --- a/acceptance/bundle/resources/postgres_branches/without_branch_id/script +++ b/acceptance/bundle/resources/postgres_branches/without_branch_id/script @@ -9,4 +9,4 @@ trap cleanup EXIT trace $CLI bundle validate # Deploy output differs between engines, so capture to per-engine file only -$CLI bundle deploy > out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 || true +$CLI bundle deploy > out.deploy.txt 2>&1 || true diff --git a/acceptance/bundle/resources/postgres_catalogs/basic/out.test.toml b/acceptance/bundle/resources/postgres_catalogs/basic/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_catalogs/basic/out.test.toml +++ b/acceptance/bundle/resources/postgres_catalogs/basic/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_catalogs/recreate/out.test.toml b/acceptance/bundle/resources/postgres_catalogs/recreate/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_catalogs/recreate/out.test.toml +++ b/acceptance/bundle/resources/postgres_catalogs/recreate/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_catalogs/test.toml b/acceptance/bundle/resources/postgres_catalogs/test.toml index d890a3a23db..5367e26ddd2 100644 --- a/acceptance/bundle/resources/postgres_catalogs/test.toml +++ b/acceptance/bundle/resources/postgres_catalogs/test.toml @@ -4,7 +4,6 @@ Cloud = true CloudEnvs.gcp = false CloudEnvs.azure = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] Ignore = [ "databricks.yml", diff --git a/acceptance/bundle/resources/postgres_databases/basic/out.requests.direct.json b/acceptance/bundle/resources/postgres_databases/basic/out.requests.json similarity index 100% rename from acceptance/bundle/resources/postgres_databases/basic/out.requests.direct.json rename to acceptance/bundle/resources/postgres_databases/basic/out.requests.json diff --git a/acceptance/bundle/resources/postgres_databases/basic/out.requests.terraform.json b/acceptance/bundle/resources/postgres_databases/basic/out.requests.terraform.json deleted file mode 100644 index 4ddff90db2b..00000000000 --- a/acceptance/bundle/resources/postgres_databases/basic/out.requests.terraform.json +++ /dev/null @@ -1,58 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/postgres/projects", - "q": { - "project_id": "test-pg-proj-[UNIQUE_NAME]" - }, - "body": { - "spec": { - "display_name": "Test Project for Database", - "history_retention_duration": "604800s", - "pg_version": 16 - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches", - "q": { - "branch_id": "main" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "no_expiry": true - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles", - "q": { - "role_id": "app-owner" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "postgres_role": "app_owner" - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/databases", - "q": { - "database_id": "my-database" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "postgres_database": "app_db", - "role": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles/app-owner" - } - } -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/databases/my-database" -} diff --git a/acceptance/bundle/resources/postgres_databases/basic/out.test.toml b/acceptance/bundle/resources/postgres_databases/basic/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_databases/basic/out.test.toml +++ b/acceptance/bundle/resources/postgres_databases/basic/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_databases/basic/script b/acceptance/bundle/resources/postgres_databases/basic/script index 03877c7260b..0be4dc9f3db 100644 --- a/acceptance/bundle/resources/postgres_databases/basic/script +++ b/acceptance/bundle/resources/postgres_databases/basic/script @@ -22,4 +22,4 @@ trace $CLI postgres get-database "${database_name}" | database_fields trace $CLI bundle summary # Filter requests to only show postgres operations (exclude workspace, telemetry, and operation polling) -trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.json diff --git a/acceptance/bundle/resources/postgres_databases/live_errors/bad_database_id/out.test.toml b/acceptance/bundle/resources/postgres_databases/live_errors/bad_database_id/out.test.toml index 7ad46517eca..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_databases/live_errors/bad_database_id/out.test.toml +++ b/acceptance/bundle/resources/postgres_databases/live_errors/bad_database_id/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_databases/live_errors/bad_role_ref/out.test.toml b/acceptance/bundle/resources/postgres_databases/live_errors/bad_role_ref/out.test.toml index 7ad46517eca..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_databases/live_errors/bad_role_ref/out.test.toml +++ b/acceptance/bundle/resources/postgres_databases/live_errors/bad_role_ref/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_databases/live_errors/test.toml b/acceptance/bundle/resources/postgres_databases/live_errors/test.toml index 64a78520ac4..ee9c9b421ee 100644 --- a/acceptance/bundle/resources/postgres_databases/live_errors/test.toml +++ b/acceptance/bundle/resources/postgres_databases/live_errors/test.toml @@ -12,7 +12,6 @@ CloudEnvs.azure = false # rolls back to its prior state on a partial failure, which makes the recorded # output diverge from the direct engine. Run them on direct only; the error # surface is the same regardless of engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ "databricks.yml", diff --git a/acceptance/bundle/resources/postgres_databases/recreate/out.test.toml b/acceptance/bundle/resources/postgres_databases/recreate/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_databases/recreate/out.test.toml +++ b/acceptance/bundle/resources/postgres_databases/recreate/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_databases/replace_existing/out.requests.deploy.direct.json b/acceptance/bundle/resources/postgres_databases/replace_existing/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/postgres_databases/replace_existing/out.requests.deploy.direct.json rename to acceptance/bundle/resources/postgres_databases/replace_existing/out.requests.deploy.json diff --git a/acceptance/bundle/resources/postgres_databases/replace_existing/out.requests.deploy.terraform.json b/acceptance/bundle/resources/postgres_databases/replace_existing/out.requests.deploy.terraform.json deleted file mode 100644 index 186913bda05..00000000000 --- a/acceptance/bundle/resources/postgres_databases/replace_existing/out.requests.deploy.terraform.json +++ /dev/null @@ -1,31 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles/app-owner" -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/databases", - "q": { - "database_id": "my-database", - "replace_existing": "true" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "postgres_database": "app_db", - "role": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles/app-owner" - } - } -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/databases/my-database" -} 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 94f9aa09315..a026907d175 100644 --- a/acceptance/bundle/resources/postgres_databases/replace_existing/out.test.toml +++ b/acceptance/bundle/resources/postgres_databases/replace_existing/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/resources/postgres_databases/replace_existing/script b/acceptance/bundle/resources/postgres_databases/replace_existing/script index 799abd4493c..2a824739a06 100644 --- a/acceptance/bundle/resources/postgres_databases/replace_existing/script +++ b/acceptance/bundle/resources/postgres_databases/replace_existing/script @@ -24,4 +24,4 @@ trace $CLI bundle deploy title "Confirm the database is under management again" trace $CLI postgres get-database "projects/test-pg-proj-${UNIQUE_NAME}/branches/main/databases/my-database" | database_fields -trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.deploy.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.deploy.json diff --git a/acceptance/bundle/resources/postgres_databases/test.toml b/acceptance/bundle/resources/postgres_databases/test.toml index 63d2317caa8..f1afb0816e3 100644 --- a/acceptance/bundle/resources/postgres_databases/test.toml +++ b/acceptance/bundle/resources/postgres_databases/test.toml @@ -5,7 +5,6 @@ CloudEnvs.gcp = false CloudEnvs.azure = false # Run on both direct and Terraform modes -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] Ignore = [ "databricks.yml", diff --git a/acceptance/bundle/resources/postgres_databases/update/out.plan.create.direct.json b/acceptance/bundle/resources/postgres_databases/update/out.plan.create.json similarity index 100% rename from acceptance/bundle/resources/postgres_databases/update/out.plan.create.direct.json rename to acceptance/bundle/resources/postgres_databases/update/out.plan.create.json diff --git a/acceptance/bundle/resources/postgres_databases/update/out.plan.create.terraform.json b/acceptance/bundle/resources/postgres_databases/update/out.plan.create.terraform.json deleted file mode 100644 index b4425b9687c..00000000000 --- a/acceptance/bundle/resources/postgres_databases/update/out.plan.create.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "create" -} diff --git a/acceptance/bundle/resources/postgres_databases/update/out.plan.no_change.direct.json b/acceptance/bundle/resources/postgres_databases/update/out.plan.no_change.json similarity index 100% rename from acceptance/bundle/resources/postgres_databases/update/out.plan.no_change.direct.json rename to acceptance/bundle/resources/postgres_databases/update/out.plan.no_change.json diff --git a/acceptance/bundle/resources/postgres_databases/update/out.plan.no_change.terraform.json b/acceptance/bundle/resources/postgres_databases/update/out.plan.no_change.terraform.json deleted file mode 100644 index b2f23a5015f..00000000000 --- a/acceptance/bundle/resources/postgres_databases/update/out.plan.no_change.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "skip" -} diff --git a/acceptance/bundle/resources/postgres_databases/update/out.plan.restore.direct.json b/acceptance/bundle/resources/postgres_databases/update/out.plan.restore.json similarity index 100% rename from acceptance/bundle/resources/postgres_databases/update/out.plan.restore.direct.json rename to acceptance/bundle/resources/postgres_databases/update/out.plan.restore.json diff --git a/acceptance/bundle/resources/postgres_databases/update/out.plan.restore.terraform.json b/acceptance/bundle/resources/postgres_databases/update/out.plan.restore.terraform.json deleted file mode 100644 index 375b496fef0..00000000000 --- a/acceptance/bundle/resources/postgres_databases/update/out.plan.restore.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "update" -} diff --git a/acceptance/bundle/resources/postgres_databases/update/out.plan.update.direct.json b/acceptance/bundle/resources/postgres_databases/update/out.plan.update.json similarity index 100% rename from acceptance/bundle/resources/postgres_databases/update/out.plan.update.direct.json rename to acceptance/bundle/resources/postgres_databases/update/out.plan.update.json diff --git a/acceptance/bundle/resources/postgres_databases/update/out.plan.update.terraform.json b/acceptance/bundle/resources/postgres_databases/update/out.plan.update.terraform.json deleted file mode 100644 index 375b496fef0..00000000000 --- a/acceptance/bundle/resources/postgres_databases/update/out.plan.update.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "update" -} diff --git a/acceptance/bundle/resources/postgres_databases/update/out.requests.create.direct.json b/acceptance/bundle/resources/postgres_databases/update/out.requests.create.json similarity index 100% rename from acceptance/bundle/resources/postgres_databases/update/out.requests.create.direct.json rename to acceptance/bundle/resources/postgres_databases/update/out.requests.create.json diff --git a/acceptance/bundle/resources/postgres_databases/update/out.requests.create.terraform.json b/acceptance/bundle/resources/postgres_databases/update/out.requests.create.terraform.json deleted file mode 100644 index c4e31a5d55d..00000000000 --- a/acceptance/bundle/resources/postgres_databases/update/out.requests.create.terraform.json +++ /dev/null @@ -1,54 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/postgres/projects", - "q": { - "project_id": "test-pg-proj-[UNIQUE_NAME]" - }, - "body": { - "spec": { - "display_name": "Test Project for Database Update", - "history_retention_duration": "604800s", - "pg_version": 16 - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches", - "q": { - "branch_id": "main" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "no_expiry": true - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles", - "q": { - "role_id": "app-owner" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "postgres_role": "app_owner" - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/databases", - "q": { - "database_id": "my-database" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "postgres_database": "initial_db_name", - "role": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles/app-owner" - } - } -} diff --git a/acceptance/bundle/resources/postgres_databases/update/out.requests.no_change.direct.json b/acceptance/bundle/resources/postgres_databases/update/out.requests.no_change.json similarity index 100% rename from acceptance/bundle/resources/postgres_databases/update/out.requests.no_change.direct.json rename to acceptance/bundle/resources/postgres_databases/update/out.requests.no_change.json diff --git a/acceptance/bundle/resources/postgres_databases/update/out.requests.no_change.terraform.json b/acceptance/bundle/resources/postgres_databases/update/out.requests.no_change.terraform.json deleted file mode 100644 index ff91f1561cf..00000000000 --- a/acceptance/bundle/resources/postgres_databases/update/out.requests.no_change.terraform.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles/app-owner" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/[MY_DATABASE_ID]" -} diff --git a/acceptance/bundle/resources/postgres_databases/update/out.requests.restore.direct.json b/acceptance/bundle/resources/postgres_databases/update/out.requests.restore.json similarity index 100% rename from acceptance/bundle/resources/postgres_databases/update/out.requests.restore.direct.json rename to acceptance/bundle/resources/postgres_databases/update/out.requests.restore.json diff --git a/acceptance/bundle/resources/postgres_databases/update/out.requests.restore.terraform.json b/acceptance/bundle/resources/postgres_databases/update/out.requests.restore.terraform.json deleted file mode 100644 index be32218e65e..00000000000 --- a/acceptance/bundle/resources/postgres_databases/update/out.requests.restore.terraform.json +++ /dev/null @@ -1,31 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles/app-owner" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/[MY_DATABASE_ID]" -} -{ - "method": "PATCH", - "path": "/api/2.0/postgres/[MY_DATABASE_ID]", - "q": { - "update_mask": "spec" - }, - "body": { - "name": "[MY_DATABASE_ID]", - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "postgres_database": "initial_db_name", - "role": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles/app-owner" - } - } -} diff --git a/acceptance/bundle/resources/postgres_databases/update/out.requests.update.direct.json b/acceptance/bundle/resources/postgres_databases/update/out.requests.update.json similarity index 100% rename from acceptance/bundle/resources/postgres_databases/update/out.requests.update.direct.json rename to acceptance/bundle/resources/postgres_databases/update/out.requests.update.json diff --git a/acceptance/bundle/resources/postgres_databases/update/out.requests.update.terraform.json b/acceptance/bundle/resources/postgres_databases/update/out.requests.update.terraform.json deleted file mode 100644 index f3e8e7858c3..00000000000 --- a/acceptance/bundle/resources/postgres_databases/update/out.requests.update.terraform.json +++ /dev/null @@ -1,31 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles/app-owner" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/[MY_DATABASE_ID]" -} -{ - "method": "PATCH", - "path": "/api/2.0/postgres/[MY_DATABASE_ID]", - "q": { - "update_mask": "spec" - }, - "body": { - "name": "[MY_DATABASE_ID]", - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "postgres_database": "renamed_db_name", - "role": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles/app-owner" - } - } -} diff --git a/acceptance/bundle/resources/postgres_databases/update/out.test.toml b/acceptance/bundle/resources/postgres_databases/update/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_databases/update/out.test.toml +++ b/acceptance/bundle/resources/postgres_databases/update/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_databases/update/script b/acceptance/bundle/resources/postgres_databases/update/script index 54c76aa8d59..96afa5b6714 100644 --- a/acceptance/bundle/resources/postgres_databases/update/script +++ b/acceptance/bundle/resources/postgres_databases/update/script @@ -8,14 +8,14 @@ trap cleanup EXIT print_requests() { local name=$1 - trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.${name}.$DATABRICKS_BUNDLE_ENGINE.json + trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.${name}.json rm -f "$OUT_REQUESTS" } title "Initial deployment" trace $CLI bundle validate trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_databases.my_database" // .' > out.plan.create.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_databases.my_database" // .' > out.plan.create.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy @@ -29,7 +29,7 @@ trace $CLI postgres get-database "${database_name}" | database_fields title "Verify no changes" trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_databases.my_database" // .' > out.plan.no_change.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_databases.my_database" // .' > out.plan.no_change.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy @@ -40,7 +40,7 @@ trace update_file.py databricks.yml "postgres_database: initial_db_name" "postgr trace cat databricks.yml trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_databases.my_database" // .' > out.plan.update.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_databases.my_database" // .' > out.plan.update.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy @@ -52,7 +52,7 @@ trace $CLI postgres get-database "${database_name}" | database_fields title "Restore postgres_database to original value" trace update_file.py databricks.yml "postgres_database: renamed_db_name" "postgres_database: initial_db_name" trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_databases.my_database" // .' > out.plan.restore.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_databases.my_database" // .' > out.plan.restore.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy diff --git a/acceptance/bundle/resources/postgres_endpoints/add_settings/out.requests.direct.json b/acceptance/bundle/resources/postgres_endpoints/add_settings/out.requests.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/add_settings/out.requests.direct.json rename to acceptance/bundle/resources/postgres_endpoints/add_settings/out.requests.json diff --git a/acceptance/bundle/resources/postgres_endpoints/add_settings/out.requests.terraform.json b/acceptance/bundle/resources/postgres_endpoints/add_settings/out.requests.terraform.json deleted file mode 100644 index 56601044e08..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/add_settings/out.requests.terraform.json +++ /dev/null @@ -1,21 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/endpoints/my-endpoint", - "q": { - "update_mask": "spec" - }, - "body": { - "name": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main/endpoints/my-endpoint", - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "autoscaling_limit_max_cu": 8, - "autoscaling_limit_min_cu": 0.5, - "endpoint_type": "ENDPOINT_TYPE_READ_ONLY", - "settings": { - "pg_settings": { - "statement_timeout": "8000" - } - } - } - } -} diff --git a/acceptance/bundle/resources/postgres_endpoints/add_settings/out.test.toml b/acceptance/bundle/resources/postgres_endpoints/add_settings/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_endpoints/add_settings/out.test.toml +++ b/acceptance/bundle/resources/postgres_endpoints/add_settings/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_endpoints/add_settings/script b/acceptance/bundle/resources/postgres_endpoints/add_settings/script index 049a4f663be..a1bb85d40fc 100644 --- a/acceptance/bundle/resources/postgres_endpoints/add_settings/script +++ b/acceptance/bundle/resources/postgres_endpoints/add_settings/script @@ -22,7 +22,7 @@ YAML trace $CLI bundle plan trace $CLI bundle deploy -trace print_requests.py --del-body project_id,branch_id,endpoint_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id,branch_id,endpoint_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.json title "Plan again: the addition must leave no drift behind" trace $CLI bundle plan diff --git a/acceptance/bundle/resources/postgres_endpoints/basic/out.requests.direct.json b/acceptance/bundle/resources/postgres_endpoints/basic/out.requests.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/basic/out.requests.direct.json rename to acceptance/bundle/resources/postgres_endpoints/basic/out.requests.json diff --git a/acceptance/bundle/resources/postgres_endpoints/basic/out.requests.terraform.json b/acceptance/bundle/resources/postgres_endpoints/basic/out.requests.terraform.json deleted file mode 100644 index 90fcc42649c..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/basic/out.requests.terraform.json +++ /dev/null @@ -1,51 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/postgres/projects", - "q": { - "project_id": "test-pg-proj-[UNIQUE_NAME]" - }, - "body": { - "spec": { - "default_endpoint_settings": { - "autoscaling_limit_max_cu": 4, - "autoscaling_limit_min_cu": 0.5, - "suspend_timeout_duration": "300s" - }, - "display_name": "Test Project for Endpoint", - "history_retention_duration": "604800s", - "pg_version": 16 - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches", - "q": { - "branch_id": "main" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "no_expiry": true - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/endpoints", - "q": { - "endpoint_id": "custom" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "autoscaling_limit_max_cu": 2, - "autoscaling_limit_min_cu": 0.5, - "endpoint_type": "ENDPOINT_TYPE_READ_ONLY" - } - } -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/endpoints/custom" -} diff --git a/acceptance/bundle/resources/postgres_endpoints/basic/out.test.toml b/acceptance/bundle/resources/postgres_endpoints/basic/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_endpoints/basic/out.test.toml +++ b/acceptance/bundle/resources/postgres_endpoints/basic/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_endpoints/basic/script b/acceptance/bundle/resources/postgres_endpoints/basic/script index 92fb20fc004..bdb24f81251 100755 --- a/acceptance/bundle/resources/postgres_endpoints/basic/script +++ b/acceptance/bundle/resources/postgres_endpoints/basic/script @@ -22,4 +22,4 @@ trace $CLI postgres get-endpoint "${endpoint_name}" | endpoint_fields trace $CLI bundle summary # Filter requests to only show postgres operations (exclude workspace, telemetry, and operation polling) -trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.json diff --git a/acceptance/bundle/resources/postgres_endpoints/recreate/out.test.toml b/acceptance/bundle/resources/postgres_endpoints/recreate/out.test.toml index 7ad46517eca..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_endpoints/recreate/out.test.toml +++ b/acceptance/bundle/resources/postgres_endpoints/recreate/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_endpoints/recreate/test.toml b/acceptance/bundle/resources/postgres_endpoints/recreate/test.toml index 9116bfb7da6..7881eb59c2f 100644 --- a/acceptance/bundle/resources/postgres_endpoints/recreate/test.toml +++ b/acceptance/bundle/resources/postgres_endpoints/recreate/test.toml @@ -1,2 +1 @@ Badness = "Terraform provider doesn't wait for endpoint reconciliation to complete after delete, causing subsequent create to fail with 'endpoint reconciliation still in progress'" -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.deploy.terraform.txt b/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.deploy.terraform.txt deleted file mode 100644 index c8d3feefbbf..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.deploy.terraform.txt +++ /dev/null @@ -1,4 +0,0 @@ -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/remove-postgres-endpoint-suspend-[UNIQUE_NAME]/default/files... -Updated postgres_endpoints.my_endpoint -Files: 0 uploaded, 0 deleted -Resources: 0 created, 1 changed, 0 deleted, 2 unchanged diff --git a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.deploy.direct.txt b/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.deploy.txt similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.deploy.direct.txt rename to acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.deploy.txt diff --git a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.direct.json b/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.drift.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.direct.json rename to acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.drift.json diff --git a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.drift.terraform.json b/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.drift.terraform.json deleted file mode 100644 index 6d36d78db61..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.drift.terraform.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "action": "skip", - "changes": null -} diff --git a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.drift.terraform.txt b/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.drift.terraform.txt deleted file mode 100644 index 0b1f3a9d31f..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.drift.terraform.txt +++ /dev/null @@ -1,3 +0,0 @@ - ->>> [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 3 unchanged diff --git a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.drift.direct.txt b/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.drift.txt similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.drift.direct.txt rename to acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.drift.txt diff --git a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.drift.direct.json b/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.drift.direct.json rename to acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.json diff --git a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.terraform.json b/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.terraform.json deleted file mode 100644 index fb09ecaf88a..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.plan.terraform.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "action": "update", - "changes": null -} diff --git a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.requests.direct.json b/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.requests.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.requests.direct.json rename to acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.requests.json diff --git a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.requests.terraform.json b/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.requests.terraform.json deleted file mode 100644 index e9af3c1811b..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.requests.terraform.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/endpoints/my-endpoint", - "q": { - "update_mask": "spec" - }, - "body": { - "name": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main/endpoints/my-endpoint", - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "autoscaling_limit_max_cu": 8, - "autoscaling_limit_min_cu": 0.5, - "endpoint_type": "ENDPOINT_TYPE_READ_ONLY" - } - } -} diff --git a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.test.toml b/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.test.toml +++ b/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/script b/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/script index ba38c4a714e..ecd4e1c3db9 100644 --- a/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/script +++ b/acceptance/bundle/resources/postgres_endpoints/remove_suspend_timeout/script @@ -22,14 +22,14 @@ trace update_file.py databricks.yml " suspend_timeout_duration: 300s" "" # Terraform provider masks the whole spec, which the API accepts and then ignores. See # test.toml. trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_endpoints.my_endpoint" | {action, changes}' > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_endpoints.my_endpoint" | {action, changes}' > out.plan.json rm -f "$OUT_REQUESTS" -errcode $CLI bundle deploy &> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt -trace print_requests.py --del-body project_id,branch_id,endpoint_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +errcode $CLI bundle deploy &> out.deploy.txt +trace print_requests.py --del-body project_id,branch_id,endpoint_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.json # Read the endpoint back to see whether the removal reached it, then plan again to # record the drift it leaves behind: direct still has the removal pending and will # fail again on every deploy, terraform applied it and is clean. trace $CLI postgres get-endpoint "${endpoint_name}" | endpoint_fields -trace $CLI bundle plan &> out.plan.drift.$DATABRICKS_BUNDLE_ENGINE.txt -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_endpoints.my_endpoint" | {action, changes}' > out.plan.drift.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan &> out.plan.drift.txt +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_endpoints.my_endpoint" | {action, changes}' > out.plan.drift.json diff --git a/acceptance/bundle/resources/postgres_endpoints/replace_existing/out.requests.deploy.direct.json b/acceptance/bundle/resources/postgres_endpoints/replace_existing/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/replace_existing/out.requests.deploy.direct.json rename to acceptance/bundle/resources/postgres_endpoints/replace_existing/out.requests.deploy.json diff --git a/acceptance/bundle/resources/postgres_endpoints/replace_existing/out.requests.deploy.terraform.json b/acceptance/bundle/resources/postgres_endpoints/replace_existing/out.requests.deploy.terraform.json deleted file mode 100644 index 6ab68fc5dd9..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/replace_existing/out.requests.deploy.terraform.json +++ /dev/null @@ -1,53 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/postgres/projects", - "q": { - "project_id": "test-pg-proj-[UNIQUE_NAME]" - }, - "body": { - "spec": { - "default_endpoint_settings": { - "autoscaling_limit_max_cu": 4, - "autoscaling_limit_min_cu": 0.5, - "suspend_timeout_duration": "300s" - }, - "display_name": "Replace existing endpoint test", - "history_retention_duration": "604800s", - "pg_version": 16 - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches", - "q": { - "branch_id": "develop" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "no_expiry": true - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/develop/endpoints", - "q": { - "endpoint_id": "primary", - "replace_existing": "true" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/develop", - "spec": { - "autoscaling_limit_max_cu": 4, - "autoscaling_limit_min_cu": 0.5, - "endpoint_type": "ENDPOINT_TYPE_READ_WRITE", - "suspend_timeout_duration": "600s" - } - } -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/develop/endpoints/primary" -} diff --git a/acceptance/bundle/resources/postgres_endpoints/replace_existing/out.requests.destroy.direct.json b/acceptance/bundle/resources/postgres_endpoints/replace_existing/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/replace_existing/out.requests.destroy.direct.json rename to acceptance/bundle/resources/postgres_endpoints/replace_existing/out.requests.destroy.json diff --git a/acceptance/bundle/resources/postgres_endpoints/replace_existing/out.requests.destroy.terraform.json b/acceptance/bundle/resources/postgres_endpoints/replace_existing/out.requests.destroy.terraform.json deleted file mode 100644 index 1bebfa32251..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/replace_existing/out.requests.destroy.terraform.json +++ /dev/null @@ -1,77 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/postgres/projects", - "q": { - "project_id": "test-pg-proj-[UNIQUE_NAME]" - }, - "body": { - "spec": { - "default_endpoint_settings": { - "autoscaling_limit_max_cu": 4, - "autoscaling_limit_min_cu": 0.5, - "suspend_timeout_duration": "300s" - }, - "display_name": "Replace existing endpoint test", - "history_retention_duration": "604800s", - "pg_version": 16 - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches", - "q": { - "branch_id": "develop" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "no_expiry": true - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/develop/endpoints", - "q": { - "endpoint_id": "primary", - "replace_existing": "true" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/develop", - "spec": { - "autoscaling_limit_max_cu": 4, - "autoscaling_limit_min_cu": 0.5, - "endpoint_type": "ENDPOINT_TYPE_READ_WRITE", - "suspend_timeout_duration": "600s" - } - } -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/develop/endpoints/primary" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/develop" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/develop/endpoints/primary" -} -{ - "method": "DELETE", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/develop/endpoints/primary" -} -{ - "method": "DELETE", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/develop" -} -{ - "method": "DELETE", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]" -} diff --git a/acceptance/bundle/resources/postgres_endpoints/replace_existing/out.test.toml b/acceptance/bundle/resources/postgres_endpoints/replace_existing/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_endpoints/replace_existing/out.test.toml +++ b/acceptance/bundle/resources/postgres_endpoints/replace_existing/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_endpoints/replace_existing/script b/acceptance/bundle/resources/postgres_endpoints/replace_existing/script index 05016df6a1e..ec2575485cc 100644 --- a/acceptance/bundle/resources/postgres_endpoints/replace_existing/script +++ b/acceptance/bundle/resources/postgres_endpoints/replace_existing/script @@ -17,7 +17,7 @@ trace $CLI bundle deploy # bundle's spec must be applied: 600s. trace $CLI postgres get-endpoint "projects/test-pg-proj-${UNIQUE_NAME}/branches/develop/endpoints/primary" | endpoint_fields -trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.deploy.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.deploy.json # bundle destroy: the backend rejects independent deletion of the primary # read-write endpoint with a MANAGED_BY_PARENT marker; both engines @@ -27,4 +27,4 @@ trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id, title "bundle destroy" $CLI bundle destroy --auto-approve > out.destroy.txt 2>&1 || true -trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.destroy.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.destroy.json diff --git a/acceptance/bundle/resources/postgres_endpoints/test.toml b/acceptance/bundle/resources/postgres_endpoints/test.toml index cb416de94d6..53c6fa4bf5d 100644 --- a/acceptance/bundle/resources/postgres_endpoints/test.toml +++ b/acceptance/bundle/resources/postgres_endpoints/test.toml @@ -5,7 +5,6 @@ CloudEnvs.gcp = false CloudEnvs.azure = false # Run on both direct and Terraform modes -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] Ignore = [ "databricks.yml", diff --git a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.create.direct.json b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.create.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.create.direct.json rename to acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.create.json diff --git a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.create.terraform.json b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.create.terraform.json deleted file mode 100644 index b4425b9687c..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.create.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "create" -} diff --git a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.no_change.direct.json b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.no_change.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.no_change.direct.json rename to acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.no_change.json diff --git a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.no_change.terraform.json b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.no_change.terraform.json deleted file mode 100644 index b2f23a5015f..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.no_change.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "skip" -} diff --git a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.restore.direct.json b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.restore.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.restore.direct.json rename to acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.restore.json diff --git a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.restore.terraform.json b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.restore.terraform.json deleted file mode 100644 index 375b496fef0..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.restore.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "update" -} diff --git a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.update.direct.json b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.update.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.update.direct.json rename to acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.update.json diff --git a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.update.terraform.json b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.update.terraform.json deleted file mode 100644 index 375b496fef0..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.plan.update.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "update" -} diff --git a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.create.direct.json b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.create.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.create.direct.json rename to acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.create.json diff --git a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.create.terraform.json b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.create.terraform.json deleted file mode 100644 index 1337f660525..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.create.terraform.json +++ /dev/null @@ -1,43 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/postgres/projects", - "q": { - "project_id": "test-pg-proj-[UNIQUE_NAME]" - }, - "body": { - "spec": { - "display_name": "Test Project for Endpoint Update", - "history_retention_duration": "604800s", - "pg_version": 16 - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches", - "q": { - "branch_id": "main" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "no_expiry": true - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/endpoints", - "q": { - "endpoint_id": "my-endpoint" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "autoscaling_limit_max_cu": 8, - "autoscaling_limit_min_cu": 0.5, - "endpoint_type": "ENDPOINT_TYPE_READ_ONLY", - "suspend_timeout_duration": "300s" - } - } -} diff --git a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.no_change.direct.json b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.no_change.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.no_change.direct.json rename to acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.no_change.json diff --git a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.no_change.terraform.json b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.no_change.terraform.json deleted file mode 100644 index e7dafa1da70..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.no_change.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/[MY_ENDPOINT_ID]" -} diff --git a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.restore.direct.json b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.restore.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.restore.direct.json rename to acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.restore.json diff --git a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.restore.terraform.json b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.restore.terraform.json deleted file mode 100644 index e551ed5eeae..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.restore.terraform.json +++ /dev/null @@ -1,29 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/[MY_ENDPOINT_ID]" -} -{ - "method": "PATCH", - "path": "/api/2.0/postgres/[MY_ENDPOINT_ID]", - "q": { - "update_mask": "spec" - }, - "body": { - "name": "[MY_ENDPOINT_ID]", - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "autoscaling_limit_max_cu": 8, - "autoscaling_limit_min_cu": 0.5, - "endpoint_type": "ENDPOINT_TYPE_READ_ONLY", - "suspend_timeout_duration": "300s" - } - } -} diff --git a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.update.direct.json b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.update.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.update.direct.json rename to acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.update.json diff --git a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.update.terraform.json b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.update.terraform.json deleted file mode 100644 index 26c0897d868..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.requests.update.terraform.json +++ /dev/null @@ -1,29 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/[MY_ENDPOINT_ID]" -} -{ - "method": "PATCH", - "path": "/api/2.0/postgres/[MY_ENDPOINT_ID]", - "q": { - "update_mask": "spec" - }, - "body": { - "name": "[MY_ENDPOINT_ID]", - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "autoscaling_limit_max_cu": 4, - "autoscaling_limit_min_cu": 0.5, - "endpoint_type": "ENDPOINT_TYPE_READ_ONLY", - "suspend_timeout_duration": "300s" - } - } -} diff --git a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.test.toml b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.test.toml +++ b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/script b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/script index 3feacc57539..7862d827bdb 100755 --- a/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/script +++ b/acceptance/bundle/resources/postgres_endpoints/update_autoscaling/script @@ -8,14 +8,14 @@ trap cleanup EXIT print_requests() { local name=$1 - trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.${name}.$DATABRICKS_BUNDLE_ENGINE.json + trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.${name}.json rm -f "$OUT_REQUESTS" } title "Initial deployment" trace $CLI bundle validate trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_endpoints.my_endpoint" // . | del(.remote_state)' > out.plan.create.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_endpoints.my_endpoint" // . | del(.remote_state)' > out.plan.create.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy @@ -29,7 +29,7 @@ trace $CLI postgres get-endpoint "${endpoint_name}" | endpoint_fields title "Verify no changes" trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_endpoints.my_endpoint" // . | del(.remote_state)' > out.plan.no_change.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_endpoints.my_endpoint" // . | del(.remote_state)' > out.plan.no_change.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy @@ -40,7 +40,7 @@ trace update_file.py databricks.yml "autoscaling_limit_max_cu: 8" "autoscaling_l trace cat databricks.yml trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_endpoints.my_endpoint" // . | del(.remote_state)' > out.plan.update.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_endpoints.my_endpoint" // . | del(.remote_state)' > out.plan.update.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy @@ -52,7 +52,7 @@ trace $CLI postgres get-endpoint "${endpoint_name}" | endpoint_fields title "Restore endpoint autoscaling to original value" trace update_file.py databricks.yml "autoscaling_limit_max_cu: 4" "autoscaling_limit_max_cu: 8" trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_endpoints.my_endpoint" // . | del(.remote_state)' > out.plan.restore.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_endpoints.my_endpoint" // . | del(.remote_state)' > out.plan.restore.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy diff --git a/acceptance/bundle/resources/postgres_endpoints/update_pg_settings/out.plan.direct.json b/acceptance/bundle/resources/postgres_endpoints/update_pg_settings/out.plan.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/update_pg_settings/out.plan.direct.json rename to acceptance/bundle/resources/postgres_endpoints/update_pg_settings/out.plan.json diff --git a/acceptance/bundle/resources/postgres_endpoints/update_pg_settings/out.plan.terraform.json b/acceptance/bundle/resources/postgres_endpoints/update_pg_settings/out.plan.terraform.json deleted file mode 100644 index fb09ecaf88a..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/update_pg_settings/out.plan.terraform.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "action": "update", - "changes": null -} diff --git a/acceptance/bundle/resources/postgres_endpoints/update_pg_settings/out.requests.direct.json b/acceptance/bundle/resources/postgres_endpoints/update_pg_settings/out.requests.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/update_pg_settings/out.requests.direct.json rename to acceptance/bundle/resources/postgres_endpoints/update_pg_settings/out.requests.json diff --git a/acceptance/bundle/resources/postgres_endpoints/update_pg_settings/out.requests.terraform.json b/acceptance/bundle/resources/postgres_endpoints/update_pg_settings/out.requests.terraform.json deleted file mode 100644 index ce239694d16..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/update_pg_settings/out.requests.terraform.json +++ /dev/null @@ -1,21 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/endpoints/my-endpoint", - "q": { - "update_mask": "spec" - }, - "body": { - "name": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main/endpoints/my-endpoint", - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "autoscaling_limit_max_cu": 8, - "autoscaling_limit_min_cu": 0.5, - "endpoint_type": "ENDPOINT_TYPE_READ_ONLY", - "settings": { - "pg_settings": { - "statement_timeout": "16000" - } - } - } - } -} diff --git a/acceptance/bundle/resources/postgres_endpoints/update_pg_settings/out.test.toml b/acceptance/bundle/resources/postgres_endpoints/update_pg_settings/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_endpoints/update_pg_settings/out.test.toml +++ b/acceptance/bundle/resources/postgres_endpoints/update_pg_settings/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_endpoints/update_pg_settings/script b/acceptance/bundle/resources/postgres_endpoints/update_pg_settings/script index 22e28508fba..936c97f018b 100644 --- a/acceptance/bundle/resources/postgres_endpoints/update_pg_settings/script +++ b/acceptance/bundle/resources/postgres_endpoints/update_pg_settings/script @@ -22,12 +22,12 @@ trace update_file.py databricks.yml "statement_timeout: 8000" "statement_timeout # spec.settings.pg_settings are both accepted, while an indexed path is answered with # 400 "Unknown field path in update_mask". trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_endpoints.my_endpoint" | {action, changes}' > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_endpoints.my_endpoint" | {action, changes}' > out.plan.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy # The mask each engine sends: direct names the map, terraform replaces the whole spec. -trace print_requests.py --del-body project_id,branch_id,endpoint_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id,branch_id,endpoint_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.json title "Plan again: the change must leave no drift behind" trace $CLI bundle plan diff --git a/acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/out.plan.direct.json b/acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/out.plan.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/out.plan.direct.json rename to acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/out.plan.json diff --git a/acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/out.plan.terraform.json b/acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/out.plan.terraform.json deleted file mode 100644 index fb09ecaf88a..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/out.plan.terraform.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "action": "update", - "changes": null -} diff --git a/acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/out.requests.direct.json b/acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/out.requests.json similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/out.requests.direct.json rename to acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/out.requests.json diff --git a/acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/out.requests.terraform.json b/acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/out.requests.terraform.json deleted file mode 100644 index b03b483f9dc..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/out.requests.terraform.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/endpoints/my-endpoint", - "q": { - "update_mask": "spec" - }, - "body": { - "name": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main/endpoints/my-endpoint", - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "autoscaling_limit_max_cu": 8, - "autoscaling_limit_min_cu": 0.5, - "endpoint_type": "ENDPOINT_TYPE_READ_ONLY", - "suspend_timeout_duration": "600s" - } - } -} diff --git a/acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/out.test.toml b/acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/out.test.toml +++ b/acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/script b/acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/script index 41637c130e6..8c6653dd7ff 100644 --- a/acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/script +++ b/acceptance/bundle/resources/postgres_endpoints/update_suspend_timeout/script @@ -26,11 +26,11 @@ title "Plan and deploy" # Both engines apply the change; only the mask they send differs, so out.requests # is the one per-engine file left. trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_endpoints.my_endpoint" | {action, changes}' > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_endpoints.my_endpoint" | {action, changes}' > out.plan.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy # The update_mask each engine sends is the whole point of this test. -trace print_requests.py --del-body project_id,branch_id,endpoint_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id,branch_id,endpoint_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.json trace $CLI postgres get-endpoint "${endpoint_name}" | endpoint_fields diff --git a/acceptance/bundle/resources/postgres_endpoints/without_endpoint_id/out.deploy.terraform.txt b/acceptance/bundle/resources/postgres_endpoints/without_endpoint_id/out.deploy.terraform.txt deleted file mode 100644 index 1b6eb357abf..00000000000 --- a/acceptance/bundle/resources/postgres_endpoints/without_endpoint_id/out.deploy.terraform.txt +++ /dev/null @@ -1,16 +0,0 @@ -Warning: required field "endpoint_id" is not set - at resources.postgres_endpoints.primary - in databricks.yml:27:7 - -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/deploy-postgres-endpoint-no-id-[UNIQUE_NAME]/default/files... -Error: exit status 1 - -Error: Missing required argument - - on bundle.tf.json line 31, in resource.databricks_postgres_endpoint.primary: - 31: } - -The argument "endpoint_id" is required, but no definition was found. - - -Files: 0 uploaded, 0 deleted diff --git a/acceptance/bundle/resources/postgres_endpoints/without_endpoint_id/out.deploy.direct.txt b/acceptance/bundle/resources/postgres_endpoints/without_endpoint_id/out.deploy.txt similarity index 100% rename from acceptance/bundle/resources/postgres_endpoints/without_endpoint_id/out.deploy.direct.txt rename to acceptance/bundle/resources/postgres_endpoints/without_endpoint_id/out.deploy.txt diff --git a/acceptance/bundle/resources/postgres_endpoints/without_endpoint_id/out.test.toml b/acceptance/bundle/resources/postgres_endpoints/without_endpoint_id/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_endpoints/without_endpoint_id/out.test.toml +++ b/acceptance/bundle/resources/postgres_endpoints/without_endpoint_id/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_endpoints/without_endpoint_id/script b/acceptance/bundle/resources/postgres_endpoints/without_endpoint_id/script index 6b718a8f22f..b707a1e7760 100755 --- a/acceptance/bundle/resources/postgres_endpoints/without_endpoint_id/script +++ b/acceptance/bundle/resources/postgres_endpoints/without_endpoint_id/script @@ -9,4 +9,4 @@ trap cleanup EXIT trace $CLI bundle validate # Deploy output differs between engines, so capture to per-engine file only -$CLI bundle deploy > out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 || true +$CLI bundle deploy > out.deploy.txt 2>&1 || true diff --git a/acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/out.deploy.terraform.txt b/acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/out.deploy.terraform.txt deleted file mode 100644 index fa179f237ca..00000000000 --- a/acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/out.deploy.terraform.txt +++ /dev/null @@ -1,4 +0,0 @@ -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle-[UNIQUE_NAME]/default/files... -Updated postgres_projects.my_project -Files: 0 uploaded, 0 deleted -Resources: 0 created, 1 changed, 0 deleted, 0 unchanged diff --git a/acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/out.deploy.direct.txt b/acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/out.deploy.txt similarity index 100% rename from acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/out.deploy.direct.txt rename to acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/out.deploy.txt diff --git a/acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/out.plan.direct.json b/acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/out.plan.json similarity index 100% rename from acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/out.plan.direct.json rename to acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/out.plan.json diff --git a/acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/out.plan.terraform.json b/acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/out.plan.terraform.json deleted file mode 100644 index a02bd4b40a7..00000000000 --- a/acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.postgres_projects.my_project": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/out.test.toml b/acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/out.test.toml +++ b/acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/script b/acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/script index 9a86e0ac38b..40651fdd3ec 100644 --- a/acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/script +++ b/acceptance/bundle/resources/postgres_projects/add_default_endpoint_settings/script @@ -16,11 +16,11 @@ trace update_file.py databricks.yml "#TO_ADD: " "" # The direct plan's "changes" map is the structdiff artifact: it records one # change at path default_endpoint_settings (the whole block) instead of descending # to its leaves. (The top-level plan verdict is 'update' on both engines.) -$CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan.json # The consequence shows up at deploy time, which diverges by engine, so route it to # per-engine files. Masking the whole message means the API requires the suspension # oneof in the body (see dresources/util.go), so the direct deploy FAILS with a 400; # terraform masks the leaf spec.default_endpoint_settings.autoscaling_limit_max_cu # and succeeds. -errcode $CLI bundle deploy > out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 +errcode $CLI bundle deploy > out.deploy.txt 2>&1 diff --git a/acceptance/bundle/resources/postgres_projects/basic/out.test.toml b/acceptance/bundle/resources/postgres_projects/basic/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_projects/basic/out.test.toml +++ b/acceptance/bundle/resources/postgres_projects/basic/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_projects/purge_on_delete/out.test.toml b/acceptance/bundle/resources/postgres_projects/purge_on_delete/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_projects/purge_on_delete/out.test.toml +++ b/acceptance/bundle/resources/postgres_projects/purge_on_delete/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_projects/purge_on_delete_transitions/out.test.toml b/acceptance/bundle/resources/postgres_projects/purge_on_delete_transitions/out.test.toml index 7ad46517eca..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_projects/purge_on_delete_transitions/out.test.toml +++ b/acceptance/bundle/resources/postgres_projects/purge_on_delete_transitions/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_projects/purge_on_delete_transitions/test.toml b/acceptance/bundle/resources/postgres_projects/purge_on_delete_transitions/test.toml deleted file mode 100644 index 797a2d57508..00000000000 --- a/acceptance/bundle/resources/postgres_projects/purge_on_delete_transitions/test.toml +++ /dev/null @@ -1,4 +0,0 @@ -# Direct engine only: this test exercises the FSF preservation in -# PrepareState and direct's plan/diff classification when the user flips -# purge_on_delete. Terraform has its own provider-managed state lifecycle. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/postgres_projects/recreate/out.test.toml b/acceptance/bundle/resources/postgres_projects/recreate/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_projects/recreate/out.test.toml +++ b/acceptance/bundle/resources/postgres_projects/recreate/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.deploy.terraform.txt b/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.deploy.terraform.txt deleted file mode 100644 index 971d9a7733c..00000000000 --- a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.deploy.terraform.txt +++ /dev/null @@ -1,4 +0,0 @@ -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/remove-postgres-project-retention-[UNIQUE_NAME]/default/files... -Updated postgres_projects.my_project -Files: 0 uploaded, 0 deleted -Resources: 0 created, 1 changed, 0 deleted, 0 unchanged diff --git a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.deploy.direct.txt b/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.deploy.txt similarity index 100% rename from acceptance/bundle/resources/postgres_projects/remove_history_retention/out.deploy.direct.txt rename to acceptance/bundle/resources/postgres_projects/remove_history_retention/out.deploy.txt diff --git a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.direct.json b/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.drift.json similarity index 100% rename from acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.direct.json rename to acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.drift.json diff --git a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.drift.terraform.json b/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.drift.terraform.json deleted file mode 100644 index 6d36d78db61..00000000000 --- a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.drift.terraform.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "action": "skip", - "changes": null -} diff --git a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.drift.terraform.txt b/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.drift.terraform.txt deleted file mode 100644 index f88b3379f3c..00000000000 --- a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.drift.terraform.txt +++ /dev/null @@ -1,3 +0,0 @@ - ->>> [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 1 unchanged diff --git a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.drift.direct.txt b/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.drift.txt similarity index 100% rename from acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.drift.direct.txt rename to acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.drift.txt diff --git a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.drift.direct.json b/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.json similarity index 100% rename from acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.drift.direct.json rename to acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.json diff --git a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.terraform.json b/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.terraform.json deleted file mode 100644 index fb09ecaf88a..00000000000 --- a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.plan.terraform.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "action": "update", - "changes": null -} diff --git a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.project.terraform.txt b/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.project.terraform.txt deleted file mode 100644 index eb446feebbf..00000000000 --- a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.project.terraform.txt +++ /dev/null @@ -1,21 +0,0 @@ -{ - "name": "projects/test-pg-proj-[UNIQUE_NAME]", - "project_id": "test-pg-proj-[UNIQUE_NAME]", - "status": { - "branch_logical_size_limit_bytes": [NUMID], - "default_branch": "projects/test-pg-proj-[UNIQUE_NAME]/branches/production", - "default_endpoint_settings": { - "autoscaling_limit_max_cu": 1, - "autoscaling_limit_min_cu": 1, - "suspend_timeout_duration": "86400s" - }, - "display_name": "Test Project for History Retention Update", - "enable_pg_native_login": false, - "history_retention_duration": "604800s", - "owner": "[USERNAME]", - "pg_version": 16, - "project_id": "test-pg-proj-[UNIQUE_NAME]", - "synthetic_storage_size_bytes": 0 - }, - "uid": "[UUID]" -} diff --git a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.project.direct.txt b/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.project.txt similarity index 100% rename from acceptance/bundle/resources/postgres_projects/remove_history_retention/out.project.direct.txt rename to acceptance/bundle/resources/postgres_projects/remove_history_retention/out.project.txt diff --git a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.requests.direct.json b/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.requests.json similarity index 100% rename from acceptance/bundle/resources/postgres_projects/remove_history_retention/out.requests.direct.json rename to acceptance/bundle/resources/postgres_projects/remove_history_retention/out.requests.json diff --git a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.requests.terraform.json b/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.requests.terraform.json deleted file mode 100644 index da517f2dbe5..00000000000 --- a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.requests.terraform.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]", - "q": { - "update_mask": "initial_branch_spec,initial_endpoint_spec,spec" - }, - "body": { - "name": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "display_name": "Test Project for History Retention Update", - "pg_version": 16 - } - } -} diff --git a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.test.toml b/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.test.toml +++ b/acceptance/bundle/resources/postgres_projects/remove_history_retention/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_projects/remove_history_retention/script b/acceptance/bundle/resources/postgres_projects/remove_history_retention/script index 90fc57abea5..99ff406c0c0 100644 --- a/acceptance/bundle/resources/postgres_projects/remove_history_retention/script +++ b/acceptance/bundle/resources/postgres_projects/remove_history_retention/script @@ -16,13 +16,13 @@ trace $CLI postgres get-project "${project_name}" | project_fields title "Remove history_retention_duration and re-deploy" trace update_file.py databricks.yml " history_retention_duration: 604800s" "" trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_projects.my_project" | {action, changes}' > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_projects.my_project" | {action, changes}' > out.plan.json rm -f "$OUT_REQUESTS" -errcode $CLI bundle deploy &> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt -trace print_requests.py --del-body project_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +errcode $CLI bundle deploy &> out.deploy.txt +trace print_requests.py --del-body project_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.json # Read the project back to see whether the removal reached it, then plan again to # record the drift it leaves behind. -trace $CLI postgres get-project "${project_name}" | project_fields > out.project.$DATABRICKS_BUNDLE_ENGINE.txt -trace $CLI bundle plan &> out.plan.drift.$DATABRICKS_BUNDLE_ENGINE.txt -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_projects.my_project" | {action, changes}' > out.plan.drift.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI postgres get-project "${project_name}" | project_fields > out.project.txt +trace $CLI bundle plan &> out.plan.drift.txt +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_projects.my_project" | {action, changes}' > out.plan.drift.json diff --git a/acceptance/bundle/resources/postgres_projects/remove_history_retention/test.toml b/acceptance/bundle/resources/postgres_projects/remove_history_retention/test.toml index efa6e2c01e2..98301005d9c 100644 --- a/acceptance/bundle/resources/postgres_projects/remove_history_retention/test.toml +++ b/acceptance/bundle/resources/postgres_projects/remove_history_retention/test.toml @@ -2,6 +2,6 @@ # update_mask and omits it from the body, and the API requires every masked field to # carry a value: 400 "Field 'spec.history_retention_duration' is in update_mask but # not provided in request" (verified against a real workspace on 2026-08-28). The old -# value therefore stays in state, so out.plan.drift.direct.json shows the same +# value therefore stays in state, so out.plan.drift.json shows the same # removal pending again, and every later deploy fails the same way. Badness = "Removing history_retention_duration fails: the field is named in update_mask but omitted from the body, which the API rejects, so the removal can never be applied and every later deploy retries and fails" diff --git a/acceptance/bundle/resources/postgres_projects/test.toml b/acceptance/bundle/resources/postgres_projects/test.toml index 7c0df797b93..7bec33c5e34 100644 --- a/acceptance/bundle/resources/postgres_projects/test.toml +++ b/acceptance/bundle/resources/postgres_projects/test.toml @@ -5,7 +5,6 @@ CloudEnvs.gcp = false CloudEnvs.azure = false # Run on both direct and Terraform modes -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] Ignore = [ "databricks.yml", diff --git a/acceptance/bundle/resources/postgres_projects/update_default_endpoint_autoscaling/out.requests.direct.json b/acceptance/bundle/resources/postgres_projects/update_default_endpoint_autoscaling/out.requests.json similarity index 100% rename from acceptance/bundle/resources/postgres_projects/update_default_endpoint_autoscaling/out.requests.direct.json rename to acceptance/bundle/resources/postgres_projects/update_default_endpoint_autoscaling/out.requests.json diff --git a/acceptance/bundle/resources/postgres_projects/update_default_endpoint_autoscaling/out.requests.terraform.json b/acceptance/bundle/resources/postgres_projects/update_default_endpoint_autoscaling/out.requests.terraform.json deleted file mode 100644 index 7bdbee14163..00000000000 --- a/acceptance/bundle/resources/postgres_projects/update_default_endpoint_autoscaling/out.requests.terraform.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]", - "q": { - "update_mask": "initial_branch_spec,initial_endpoint_spec,spec" - }, - "body": { - "name": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "default_endpoint_settings": { - "autoscaling_limit_max_cu": 8, - "autoscaling_limit_min_cu": 0.5 - }, - "display_name": "Test Project for Default Endpoint Autoscaling", - "history_retention_duration": "604800s", - "pg_version": 16 - } - } -} diff --git a/acceptance/bundle/resources/postgres_projects/update_default_endpoint_autoscaling/out.test.toml b/acceptance/bundle/resources/postgres_projects/update_default_endpoint_autoscaling/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_projects/update_default_endpoint_autoscaling/out.test.toml +++ b/acceptance/bundle/resources/postgres_projects/update_default_endpoint_autoscaling/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_projects/update_default_endpoint_autoscaling/script b/acceptance/bundle/resources/postgres_projects/update_default_endpoint_autoscaling/script index a00ce644da6..12c11b7408b 100644 --- a/acceptance/bundle/resources/postgres_projects/update_default_endpoint_autoscaling/script +++ b/acceptance/bundle/resources/postgres_projects/update_default_endpoint_autoscaling/script @@ -21,7 +21,7 @@ trace update_file.py databricks.yml "autoscaling_limit_max_cu: 4" "autoscaling_l trace $CLI bundle plan trace $CLI bundle deploy -trace print_requests.py --del-body project_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.json trace $CLI postgres get-project "${project_name}" | jq '.status.default_endpoint_settings' title "Plan again: the change must leave no drift behind" diff --git a/acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/out.plan.direct.json b/acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/out.plan.json similarity index 100% rename from acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/out.plan.direct.json rename to acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/out.plan.json diff --git a/acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/out.plan.terraform.json b/acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/out.plan.terraform.json deleted file mode 100644 index fb09ecaf88a..00000000000 --- a/acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/out.plan.terraform.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "action": "update", - "changes": null -} diff --git a/acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/out.requests.direct.json b/acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/out.requests.json similarity index 100% rename from acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/out.requests.direct.json rename to acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/out.requests.json diff --git a/acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/out.requests.terraform.json b/acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/out.requests.terraform.json deleted file mode 100644 index dc707362329..00000000000 --- a/acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/out.requests.terraform.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]", - "q": { - "update_mask": "initial_branch_spec,initial_endpoint_spec,spec" - }, - "body": { - "name": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "default_endpoint_settings": { - "autoscaling_limit_max_cu": 4, - "autoscaling_limit_min_cu": 0.5, - "suspend_timeout_duration": "600s" - }, - "display_name": "Test Project for Default Endpoint Suspend Update", - "pg_version": 16 - } - } -} diff --git a/acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/out.test.toml b/acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/out.test.toml +++ b/acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/script b/acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/script index 2125a4af7fe..21dafdc6c7e 100644 --- a/acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/script +++ b/acceptance/bundle/resources/postgres_projects/update_default_endpoint_suspend/script @@ -25,8 +25,8 @@ trace update_file.py databricks.yml "suspend_timeout_duration: 300s" "suspend_ti # member of the suspension oneof, nested under default_endpoint_settings, and the # direct engine masks it under its own name. See test.toml. trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_projects.my_project" | {action, changes}' > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_projects.my_project" | {action, changes}' > out.plan.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy -trace print_requests.py --del-body project_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.json trace $CLI postgres get-project "${project_name}" | project_fields diff --git a/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.create.direct.json b/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.create.json similarity index 100% rename from acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.create.direct.json rename to acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.create.json diff --git a/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.create.terraform.json b/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.create.terraform.json deleted file mode 100644 index b4425b9687c..00000000000 --- a/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.create.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "create" -} diff --git a/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.no_change.direct.json b/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.no_change.json similarity index 100% rename from acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.no_change.direct.json rename to acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.no_change.json diff --git a/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.no_change.terraform.json b/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.no_change.terraform.json deleted file mode 100644 index b2f23a5015f..00000000000 --- a/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.no_change.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "skip" -} diff --git a/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.restore.direct.json b/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.restore.json similarity index 100% rename from acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.restore.direct.json rename to acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.restore.json diff --git a/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.restore.terraform.json b/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.restore.terraform.json deleted file mode 100644 index 375b496fef0..00000000000 --- a/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.restore.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "update" -} diff --git a/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.update.direct.json b/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.update.json similarity index 100% rename from acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.update.direct.json rename to acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.update.json diff --git a/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.update.terraform.json b/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.update.terraform.json deleted file mode 100644 index 375b496fef0..00000000000 --- a/acceptance/bundle/resources/postgres_projects/update_display_name/out.plan.update.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "update" -} diff --git a/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.create.direct.json b/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.create.json similarity index 100% rename from acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.create.direct.json rename to acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.create.json diff --git a/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.create.terraform.json b/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.create.terraform.json deleted file mode 100644 index c9d08e089ba..00000000000 --- a/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.create.terraform.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/postgres/projects", - "q": { - "project_id": "test-pg-proj-[UNIQUE_NAME]" - }, - "body": { - "spec": { - "default_endpoint_settings": { - "autoscaling_limit_max_cu": 4, - "autoscaling_limit_min_cu": 0.5, - "suspend_timeout_duration": "300s" - }, - "display_name": "Original Name", - "history_retention_duration": "604800s", - "pg_version": 16 - } - } -} diff --git a/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.no_change.direct.json b/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.no_change.json similarity index 100% rename from acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.no_change.direct.json rename to acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.no_change.json diff --git a/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.no_change.terraform.json b/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.no_change.terraform.json deleted file mode 100644 index 1d6880d333b..00000000000 --- a/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.no_change.terraform.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.0/postgres/[MY_PROJECT_ID]" -} diff --git a/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.restore.direct.json b/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.restore.json similarity index 100% rename from acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.restore.direct.json rename to acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.restore.json diff --git a/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.restore.terraform.json b/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.restore.terraform.json deleted file mode 100644 index 0289e24a593..00000000000 --- a/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.restore.terraform.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.0/postgres/[MY_PROJECT_ID]" -} -{ - "method": "PATCH", - "path": "/api/2.0/postgres/[MY_PROJECT_ID]", - "q": { - "update_mask": "initial_branch_spec,initial_endpoint_spec,spec" - }, - "body": { - "name": "[MY_PROJECT_ID]", - "spec": { - "default_endpoint_settings": { - "autoscaling_limit_max_cu": 4, - "autoscaling_limit_min_cu": 0.5, - "suspend_timeout_duration": "300s" - }, - "display_name": "Original Name", - "history_retention_duration": "604800s", - "pg_version": 16 - } - } -} diff --git a/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.update.direct.json b/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.update.json similarity index 100% rename from acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.update.direct.json rename to acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.update.json diff --git a/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.update.terraform.json b/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.update.terraform.json deleted file mode 100644 index 7dbf422479b..00000000000 --- a/acceptance/bundle/resources/postgres_projects/update_display_name/out.requests.update.terraform.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.0/postgres/[MY_PROJECT_ID]" -} -{ - "method": "PATCH", - "path": "/api/2.0/postgres/[MY_PROJECT_ID]", - "q": { - "update_mask": "initial_branch_spec,initial_endpoint_spec,spec" - }, - "body": { - "name": "[MY_PROJECT_ID]", - "spec": { - "default_endpoint_settings": { - "autoscaling_limit_max_cu": 4, - "autoscaling_limit_min_cu": 0.5, - "suspend_timeout_duration": "300s" - }, - "display_name": "Updated Name", - "history_retention_duration": "604800s", - "pg_version": 16 - } - } -} diff --git a/acceptance/bundle/resources/postgres_projects/update_display_name/out.test.toml b/acceptance/bundle/resources/postgres_projects/update_display_name/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_projects/update_display_name/out.test.toml +++ b/acceptance/bundle/resources/postgres_projects/update_display_name/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_projects/update_display_name/script b/acceptance/bundle/resources/postgres_projects/update_display_name/script index f06754b9790..766891a7e50 100755 --- a/acceptance/bundle/resources/postgres_projects/update_display_name/script +++ b/acceptance/bundle/resources/postgres_projects/update_display_name/script @@ -8,14 +8,14 @@ trap cleanup EXIT print_requests() { local name=$1 - trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.${name}.$DATABRICKS_BUNDLE_ENGINE.json + trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.${name}.json rm -f "$OUT_REQUESTS" } title "Initial deployment" trace $CLI bundle validate trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_projects.my_project" // .' > out.plan.create.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_projects.my_project" // .' > out.plan.create.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy @@ -27,7 +27,7 @@ trace $CLI postgres get-project "${project_name}" | project_fields title "Verify no changes" trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_projects.my_project" // .' > out.plan.no_change.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_projects.my_project" // .' > out.plan.no_change.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy @@ -38,7 +38,7 @@ trace update_file.py databricks.yml "Original Name" "Updated Name" trace cat databricks.yml trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_projects.my_project" // .' > out.plan.update.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_projects.my_project" // .' > out.plan.update.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy @@ -50,7 +50,7 @@ trace $CLI postgres get-project "${project_name}" | project_fields title "Restore display_name to original value" trace update_file.py databricks.yml "Updated Name" "Original Name" trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_projects.my_project" // .' > out.plan.restore.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_projects.my_project" // .' > out.plan.restore.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy diff --git a/acceptance/bundle/resources/postgres_projects/update_history_retention/out.plan.direct.json b/acceptance/bundle/resources/postgres_projects/update_history_retention/out.plan.json similarity index 100% rename from acceptance/bundle/resources/postgres_projects/update_history_retention/out.plan.direct.json rename to acceptance/bundle/resources/postgres_projects/update_history_retention/out.plan.json diff --git a/acceptance/bundle/resources/postgres_projects/update_history_retention/out.plan.terraform.json b/acceptance/bundle/resources/postgres_projects/update_history_retention/out.plan.terraform.json deleted file mode 100644 index fb09ecaf88a..00000000000 --- a/acceptance/bundle/resources/postgres_projects/update_history_retention/out.plan.terraform.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "action": "update", - "changes": null -} diff --git a/acceptance/bundle/resources/postgres_projects/update_history_retention/out.requests.direct.json b/acceptance/bundle/resources/postgres_projects/update_history_retention/out.requests.json similarity index 100% rename from acceptance/bundle/resources/postgres_projects/update_history_retention/out.requests.direct.json rename to acceptance/bundle/resources/postgres_projects/update_history_retention/out.requests.json diff --git a/acceptance/bundle/resources/postgres_projects/update_history_retention/out.requests.terraform.json b/acceptance/bundle/resources/postgres_projects/update_history_retention/out.requests.terraform.json deleted file mode 100644 index a316b7d8171..00000000000 --- a/acceptance/bundle/resources/postgres_projects/update_history_retention/out.requests.terraform.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "method": "PATCH", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]", - "q": { - "update_mask": "initial_branch_spec,initial_endpoint_spec,spec" - }, - "body": { - "name": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "display_name": "Test Project for History Retention Update", - "history_retention_duration": "259200s", - "pg_version": 16 - } - } -} diff --git a/acceptance/bundle/resources/postgres_projects/update_history_retention/out.test.toml b/acceptance/bundle/resources/postgres_projects/update_history_retention/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_projects/update_history_retention/out.test.toml +++ b/acceptance/bundle/resources/postgres_projects/update_history_retention/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_projects/update_history_retention/script b/acceptance/bundle/resources/postgres_projects/update_history_retention/script index b1a703f3732..115a7ed034e 100644 --- a/acceptance/bundle/resources/postgres_projects/update_history_retention/script +++ b/acceptance/bundle/resources/postgres_projects/update_history_retention/script @@ -16,12 +16,12 @@ trace $CLI postgres get-project "${project_name}" | project_fields title "Change history_retention_duration to 259200s and re-deploy" trace update_file.py databricks.yml "history_retention_duration: 604800s" "history_retention_duration: 259200s" trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_projects.my_project" | {action, changes}' > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_projects.my_project" | {action, changes}' > out.plan.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy # Unlike the suspension oneof, history_retention_duration is masked under its own # name, so the direct engine's update_mask is accepted and the change applies. -trace print_requests.py --del-body project_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id --sort '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.json trace $CLI postgres get-project "${project_name}" | project_fields diff --git a/acceptance/bundle/resources/postgres_projects/without_project_id/out.deploy.terraform.txt b/acceptance/bundle/resources/postgres_projects/without_project_id/out.deploy.terraform.txt deleted file mode 100644 index 8068586bd85..00000000000 --- a/acceptance/bundle/resources/postgres_projects/without_project_id/out.deploy.terraform.txt +++ /dev/null @@ -1,16 +0,0 @@ -Warning: required field "project_id" is not set - at resources.postgres_projects.my_project - in databricks.yml:10:7 - -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/deploy-postgres-no-id-[UNIQUE_NAME]/default/files... -Error: exit status 1 - -Error: Missing required argument - - on bundle.tf.json line 26, in resource.databricks_postgres_project.my_project: - 26: } - -The argument "project_id" is required, but no definition was found. - - -Files: 0 uploaded, 0 deleted diff --git a/acceptance/bundle/resources/postgres_projects/without_project_id/out.deploy.direct.txt b/acceptance/bundle/resources/postgres_projects/without_project_id/out.deploy.txt similarity index 100% rename from acceptance/bundle/resources/postgres_projects/without_project_id/out.deploy.direct.txt rename to acceptance/bundle/resources/postgres_projects/without_project_id/out.deploy.txt diff --git a/acceptance/bundle/resources/postgres_projects/without_project_id/out.test.toml b/acceptance/bundle/resources/postgres_projects/without_project_id/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_projects/without_project_id/out.test.toml +++ b/acceptance/bundle/resources/postgres_projects/without_project_id/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_projects/without_project_id/script b/acceptance/bundle/resources/postgres_projects/without_project_id/script index 112f4071ada..1a7b0ae6894 100644 --- a/acceptance/bundle/resources/postgres_projects/without_project_id/script +++ b/acceptance/bundle/resources/postgres_projects/without_project_id/script @@ -3,4 +3,4 @@ envsubst < databricks.yml.tmpl > databricks.yml trace $CLI bundle validate # Deploy output differs between engines, so capture to per-engine file only -$CLI bundle deploy > out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 || true +$CLI bundle deploy > out.deploy.txt 2>&1 || true diff --git a/acceptance/bundle/resources/postgres_roles/basic/out.requests.direct.json b/acceptance/bundle/resources/postgres_roles/basic/out.requests.json similarity index 100% rename from acceptance/bundle/resources/postgres_roles/basic/out.requests.direct.json rename to acceptance/bundle/resources/postgres_roles/basic/out.requests.json diff --git a/acceptance/bundle/resources/postgres_roles/basic/out.requests.terraform.json b/acceptance/bundle/resources/postgres_roles/basic/out.requests.terraform.json deleted file mode 100644 index ad5c2ec0d03..00000000000 --- a/acceptance/bundle/resources/postgres_roles/basic/out.requests.terraform.json +++ /dev/null @@ -1,47 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/postgres/projects", - "q": { - "project_id": "test-pg-proj-[UNIQUE_NAME]" - }, - "body": { - "spec": { - "display_name": "Test Project for Role", - "history_retention_duration": "604800s", - "pg_version": 16 - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches", - "q": { - "branch_id": "main" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "no_expiry": true - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles", - "q": { - "role_id": "test-role" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "attributes": { - "createdb": true - }, - "postgres_role": "app_role" - } - } -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles/test-role" -} diff --git a/acceptance/bundle/resources/postgres_roles/basic/out.test.toml b/acceptance/bundle/resources/postgres_roles/basic/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_roles/basic/out.test.toml +++ b/acceptance/bundle/resources/postgres_roles/basic/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_roles/basic/script b/acceptance/bundle/resources/postgres_roles/basic/script index 8d9c88c73b6..ebb54463a07 100644 --- a/acceptance/bundle/resources/postgres_roles/basic/script +++ b/acceptance/bundle/resources/postgres_roles/basic/script @@ -26,4 +26,4 @@ trace musterr $CLI bundle open my_role trace $CLI bundle summary # Filter requests to only show postgres operations (exclude workspace, telemetry, and operation polling) -trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.json 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 26f5e3debde..18f5005f731 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,5 +1,4 @@ Cloud = false CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] 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 01b05580cec..ca6f1025071 100644 --- a/acceptance/bundle/resources/postgres_roles/inherited-role-bind/test.toml +++ b/acceptance/bundle/resources/postgres_roles/inherited-role-bind/test.toml @@ -6,7 +6,6 @@ Cloud = false # bind/deploy are engine-agnostic here; run on direct for a single stable output. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # bind and unbind refuse to run when deployment history recording is on, so the # escape hatch this test covers is not available there yet. 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 26f5e3debde..18f5005f731 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,5 +1,4 @@ Cloud = false CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] 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 5bfbe6698e8..0a198808bc5 100644 --- a/acceptance/bundle/resources/postgres_roles/inherited-role-conflict/test.toml +++ b/acceptance/bundle/resources/postgres_roles/inherited-role-conflict/test.toml @@ -4,7 +4,6 @@ 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. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # `bundle unbind` does not yet drop the resource from what the deployment metadata service # reports, so the role staged above still looks tracked. diff --git a/acceptance/bundle/resources/postgres_roles/recreate-postgres-role/out.test.toml b/acceptance/bundle/resources/postgres_roles/recreate-postgres-role/out.test.toml index 7ad46517eca..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_roles/recreate-postgres-role/out.test.toml +++ b/acceptance/bundle/resources/postgres_roles/recreate-postgres-role/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_roles/recreate-postgres-role/test.toml b/acceptance/bundle/resources/postgres_roles/recreate-postgres-role/test.toml index 6d0c603a991..55033fb27fc 100644 --- a/acceptance/bundle/resources/postgres_roles/recreate-postgres-role/test.toml +++ b/acceptance/bundle/resources/postgres_roles/recreate-postgres-role/test.toml @@ -1,2 +1 @@ Badness = "Terraform provider treats spec.postgres_role as updateable and sends update_mask=spec instead of recreating; backend silently no-ops the change. Direct engine correctly recreates." -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/postgres_roles/recreate/out.test.toml b/acceptance/bundle/resources/postgres_roles/recreate/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_roles/recreate/out.test.toml +++ b/acceptance/bundle/resources/postgres_roles/recreate/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_roles/replace_existing/out.requests.deploy.direct.json b/acceptance/bundle/resources/postgres_roles/replace_existing/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/resources/postgres_roles/replace_existing/out.requests.deploy.direct.json rename to acceptance/bundle/resources/postgres_roles/replace_existing/out.requests.deploy.json diff --git a/acceptance/bundle/resources/postgres_roles/replace_existing/out.requests.deploy.terraform.json b/acceptance/bundle/resources/postgres_roles/replace_existing/out.requests.deploy.terraform.json deleted file mode 100644 index 2679673de46..00000000000 --- a/acceptance/bundle/resources/postgres_roles/replace_existing/out.requests.deploy.terraform.json +++ /dev/null @@ -1,26 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main" -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles", - "q": { - "replace_existing": "true", - "role_id": "test-role" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "postgres_role": "app_role" - } - } -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles/test-role" -} 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 94f9aa09315..a026907d175 100644 --- a/acceptance/bundle/resources/postgres_roles/replace_existing/out.test.toml +++ b/acceptance/bundle/resources/postgres_roles/replace_existing/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/resources/postgres_roles/replace_existing/script b/acceptance/bundle/resources/postgres_roles/replace_existing/script index 81cdb4b7924..211e0f6458f 100644 --- a/acceptance/bundle/resources/postgres_roles/replace_existing/script +++ b/acceptance/bundle/resources/postgres_roles/replace_existing/script @@ -24,4 +24,4 @@ trace $CLI bundle deploy title "Confirm the role is under management again" trace $CLI postgres get-role "projects/test-pg-proj-${UNIQUE_NAME}/branches/main/roles/test-role" | role_fields -trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.deploy.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.deploy.json diff --git a/acceptance/bundle/resources/postgres_roles/test.toml b/acceptance/bundle/resources/postgres_roles/test.toml index 6b34a9705dd..035e2e8da61 100644 --- a/acceptance/bundle/resources/postgres_roles/test.toml +++ b/acceptance/bundle/resources/postgres_roles/test.toml @@ -5,7 +5,6 @@ CloudEnvs.gcp = false CloudEnvs.azure = false # Run on both direct and Terraform modes -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] Ignore = [ "databricks.yml", diff --git a/acceptance/bundle/resources/postgres_roles/update/out.plan.create.direct.json b/acceptance/bundle/resources/postgres_roles/update/out.plan.create.json similarity index 100% rename from acceptance/bundle/resources/postgres_roles/update/out.plan.create.direct.json rename to acceptance/bundle/resources/postgres_roles/update/out.plan.create.json diff --git a/acceptance/bundle/resources/postgres_roles/update/out.plan.create.terraform.json b/acceptance/bundle/resources/postgres_roles/update/out.plan.create.terraform.json deleted file mode 100644 index b4425b9687c..00000000000 --- a/acceptance/bundle/resources/postgres_roles/update/out.plan.create.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "create" -} diff --git a/acceptance/bundle/resources/postgres_roles/update/out.plan.no_change.direct.json b/acceptance/bundle/resources/postgres_roles/update/out.plan.no_change.json similarity index 100% rename from acceptance/bundle/resources/postgres_roles/update/out.plan.no_change.direct.json rename to acceptance/bundle/resources/postgres_roles/update/out.plan.no_change.json diff --git a/acceptance/bundle/resources/postgres_roles/update/out.plan.no_change.terraform.json b/acceptance/bundle/resources/postgres_roles/update/out.plan.no_change.terraform.json deleted file mode 100644 index b2f23a5015f..00000000000 --- a/acceptance/bundle/resources/postgres_roles/update/out.plan.no_change.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "skip" -} diff --git a/acceptance/bundle/resources/postgres_roles/update/out.plan.restore.direct.json b/acceptance/bundle/resources/postgres_roles/update/out.plan.restore.json similarity index 100% rename from acceptance/bundle/resources/postgres_roles/update/out.plan.restore.direct.json rename to acceptance/bundle/resources/postgres_roles/update/out.plan.restore.json diff --git a/acceptance/bundle/resources/postgres_roles/update/out.plan.restore.terraform.json b/acceptance/bundle/resources/postgres_roles/update/out.plan.restore.terraform.json deleted file mode 100644 index 375b496fef0..00000000000 --- a/acceptance/bundle/resources/postgres_roles/update/out.plan.restore.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "update" -} diff --git a/acceptance/bundle/resources/postgres_roles/update/out.plan.update.direct.json b/acceptance/bundle/resources/postgres_roles/update/out.plan.update.json similarity index 100% rename from acceptance/bundle/resources/postgres_roles/update/out.plan.update.direct.json rename to acceptance/bundle/resources/postgres_roles/update/out.plan.update.json diff --git a/acceptance/bundle/resources/postgres_roles/update/out.plan.update.terraform.json b/acceptance/bundle/resources/postgres_roles/update/out.plan.update.terraform.json deleted file mode 100644 index 375b496fef0..00000000000 --- a/acceptance/bundle/resources/postgres_roles/update/out.plan.update.terraform.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "action": "update" -} diff --git a/acceptance/bundle/resources/postgres_roles/update/out.requests.create.direct.json b/acceptance/bundle/resources/postgres_roles/update/out.requests.create.json similarity index 100% rename from acceptance/bundle/resources/postgres_roles/update/out.requests.create.direct.json rename to acceptance/bundle/resources/postgres_roles/update/out.requests.create.json diff --git a/acceptance/bundle/resources/postgres_roles/update/out.requests.create.terraform.json b/acceptance/bundle/resources/postgres_roles/update/out.requests.create.terraform.json deleted file mode 100644 index 0a6bbfc61da..00000000000 --- a/acceptance/bundle/resources/postgres_roles/update/out.requests.create.terraform.json +++ /dev/null @@ -1,43 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/postgres/projects", - "q": { - "project_id": "test-pg-proj-[UNIQUE_NAME]" - }, - "body": { - "spec": { - "display_name": "Test Project for Role Update", - "history_retention_duration": "604800s", - "pg_version": 16 - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches", - "q": { - "branch_id": "main" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]", - "spec": { - "no_expiry": true - } - } -} -{ - "method": "POST", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles", - "q": { - "role_id": "test-role" - }, - "body": { - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "attributes": { - "createdb": false - }, - "postgres_role": "app_role" - } - } -} diff --git a/acceptance/bundle/resources/postgres_roles/update/out.requests.no_change.direct.json b/acceptance/bundle/resources/postgres_roles/update/out.requests.no_change.json similarity index 100% rename from acceptance/bundle/resources/postgres_roles/update/out.requests.no_change.direct.json rename to acceptance/bundle/resources/postgres_roles/update/out.requests.no_change.json diff --git a/acceptance/bundle/resources/postgres_roles/update/out.requests.no_change.terraform.json b/acceptance/bundle/resources/postgres_roles/update/out.requests.no_change.terraform.json deleted file mode 100644 index 4296a1779c8..00000000000 --- a/acceptance/bundle/resources/postgres_roles/update/out.requests.no_change.terraform.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles/test-role" -} diff --git a/acceptance/bundle/resources/postgres_roles/update/out.requests.restore.direct.json b/acceptance/bundle/resources/postgres_roles/update/out.requests.restore.json similarity index 100% rename from acceptance/bundle/resources/postgres_roles/update/out.requests.restore.direct.json rename to acceptance/bundle/resources/postgres_roles/update/out.requests.restore.json diff --git a/acceptance/bundle/resources/postgres_roles/update/out.requests.restore.terraform.json b/acceptance/bundle/resources/postgres_roles/update/out.requests.restore.terraform.json deleted file mode 100644 index d62792a95a0..00000000000 --- a/acceptance/bundle/resources/postgres_roles/update/out.requests.restore.terraform.json +++ /dev/null @@ -1,29 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles/test-role" -} -{ - "method": "PATCH", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles/test-role", - "q": { - "update_mask": "spec" - }, - "body": { - "name": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles/test-role", - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "attributes": { - "createdb": false - }, - "postgres_role": "app_role" - } - } -} diff --git a/acceptance/bundle/resources/postgres_roles/update/out.requests.update.direct.json b/acceptance/bundle/resources/postgres_roles/update/out.requests.update.json similarity index 100% rename from acceptance/bundle/resources/postgres_roles/update/out.requests.update.direct.json rename to acceptance/bundle/resources/postgres_roles/update/out.requests.update.json diff --git a/acceptance/bundle/resources/postgres_roles/update/out.requests.update.terraform.json b/acceptance/bundle/resources/postgres_roles/update/out.requests.update.terraform.json deleted file mode 100644 index 3f56f596530..00000000000 --- a/acceptance/bundle/resources/postgres_roles/update/out.requests.update.terraform.json +++ /dev/null @@ -1,29 +0,0 @@ -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main" -} -{ - "method": "GET", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles/test-role" -} -{ - "method": "PATCH", - "path": "/api/2.0/postgres/projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles/test-role", - "q": { - "update_mask": "spec" - }, - "body": { - "name": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main/roles/test-role", - "parent": "projects/test-pg-proj-[UNIQUE_NAME]/branches/main", - "spec": { - "attributes": { - "createdb": true - }, - "postgres_role": "app_role" - } - } -} diff --git a/acceptance/bundle/resources/postgres_roles/update/out.test.toml b/acceptance/bundle/resources/postgres_roles/update/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_roles/update/out.test.toml +++ b/acceptance/bundle/resources/postgres_roles/update/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_roles/update/script b/acceptance/bundle/resources/postgres_roles/update/script index 6073dd3a11f..0c81dd423e0 100644 --- a/acceptance/bundle/resources/postgres_roles/update/script +++ b/acceptance/bundle/resources/postgres_roles/update/script @@ -8,14 +8,14 @@ trap cleanup EXIT print_requests() { local name=$1 - trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.${name}.$DATABRICKS_BUNDLE_ENGINE.json + trace print_requests.py --del-body project_id,branch_id,endpoint_id,database_id,role_id,catalog_id,synced_table_id --keep --get '//postgres' '^//workspace-files/' '^//workspace/' '^//telemetry-ext' '^//operations/' > out.requests.${name}.json rm -f "$OUT_REQUESTS" } title "Initial deployment" trace $CLI bundle validate trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_roles.my_role" // .' > out.plan.create.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_roles.my_role" // .' > out.plan.create.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy @@ -28,7 +28,7 @@ trace $CLI postgres get-role "${role_name}" | role_fields title "Verify no changes" trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_roles.my_role" // .' > out.plan.no_change.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_roles.my_role" // .' > out.plan.no_change.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy @@ -39,7 +39,7 @@ trace update_file.py databricks.yml "createdb: false" "createdb: true" trace cat databricks.yml trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_roles.my_role" // .' > out.plan.update.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_roles.my_role" // .' > out.plan.update.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy @@ -50,7 +50,7 @@ trace $CLI postgres get-role "${role_name}" | role_fields title "Restore attributes.createdb to original value" trace update_file.py databricks.yml "createdb: true" "createdb: false" trace $CLI bundle plan -trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_roles.my_role" // .' > out.plan.restore.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp | jq '.plan."resources.postgres_roles.my_role" // .' > out.plan.restore.json rm -f "$OUT_REQUESTS" trace $CLI bundle deploy diff --git a/acceptance/bundle/resources/postgres_snapshot_schedules/basic/out.test.toml b/acceptance/bundle/resources/postgres_snapshot_schedules/basic/out.test.toml index 7ad46517eca..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_snapshot_schedules/basic/out.test.toml +++ b/acceptance/bundle/resources/postgres_snapshot_schedules/basic/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_snapshot_schedules/out-of-band/out.test.toml b/acceptance/bundle/resources/postgres_snapshot_schedules/out-of-band/out.test.toml index 7ad46517eca..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_snapshot_schedules/out-of-band/out.test.toml +++ b/acceptance/bundle/resources/postgres_snapshot_schedules/out-of-band/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_snapshot_schedules/test.toml b/acceptance/bundle/resources/postgres_snapshot_schedules/test.toml index 888670d085c..e3ff8d8a1b1 100644 --- a/acceptance/bundle/resources/postgres_snapshot_schedules/test.toml +++ b/acceptance/bundle/resources/postgres_snapshot_schedules/test.toml @@ -8,7 +8,6 @@ CloudEnvs.azure = false # v0.177.0, which the pinned Terraform provider does not yet include, so there is # no databricks_..._snapshot_schedule resource to deploy through. Run the direct # engine only until the provider catches up. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ "databricks.yml", diff --git a/acceptance/bundle/resources/postgres_synced_tables/basic/out.test.toml b/acceptance/bundle/resources/postgres_synced_tables/basic/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_synced_tables/basic/out.test.toml +++ b/acceptance/bundle/resources/postgres_synced_tables/basic/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_synced_tables/recreate/out.test.toml b/acceptance/bundle/resources/postgres_synced_tables/recreate/out.test.toml index 9c8db837a9e..ee153e82621 100644 --- a/acceptance/bundle/resources/postgres_synced_tables/recreate/out.test.toml +++ b/acceptance/bundle/resources/postgres_synced_tables/recreate/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/postgres_synced_tables/test.toml b/acceptance/bundle/resources/postgres_synced_tables/test.toml index bfaf7d18e70..4cf521183b9 100644 --- a/acceptance/bundle/resources/postgres_synced_tables/test.toml +++ b/acceptance/bundle/resources/postgres_synced_tables/test.toml @@ -4,7 +4,6 @@ Cloud = true CloudEnvs.gcp = false CloudEnvs.azure = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct", "terraform"] Ignore = [ "databricks.yml", diff --git a/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.deploy.requests.direct.json b/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.deploy.requests.json similarity index 100% rename from acceptance/bundle/resources/quality_monitors/change_assets_dir/out.deploy.requests.direct.json rename to acceptance/bundle/resources/quality_monitors/change_assets_dir/out.deploy.requests.json diff --git a/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.deploy.requests.terraform.json b/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.deploy.requests.terraform.json deleted file mode 100644 index db37d531e33..00000000000 --- a/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.deploy.requests.terraform.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "method": "PUT", - "path": "/api/2.1/unity-catalog/tables/main.qm_test_[UNIQUE_NAME].test_table/monitor", - "body": { - "dashboard_id": "(redacted)", - "output_schema_name": "main.qm_test_[UNIQUE_NAME]", - "snapshot": {} - } -} diff --git a/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.deploy.terraform.txt b/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.deploy.terraform.txt deleted file mode 100644 index f10ff7b9f90..00000000000 --- a/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.deploy.terraform.txt +++ /dev/null @@ -1,21 +0,0 @@ - ->>> errcode [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/quality-monitor-update-[UNIQUE_NAME]/default/files... -Error: terraform apply: exit status 1 - -Error: Provider produced inconsistent result after apply - -When applying changes to databricks_quality_monitor.monitor1, provider -"provider[\"registry.terraform.io/databricks/databricks\"]" produced an -unexpected new value: .assets_dir: was -cty.StringVal("/Workspace/Users/[USERNAME]/monitor_assets2_[UNIQUE_NAME]"), -but now -cty.StringVal("/Workspace/Users/[USERNAME]/monitor_assets_[UNIQUE_NAME]"). - -This is a bug in the provider, which should be reported in the provider's own -issue tracker. - - -Files: 4 uploaded, 0 deleted - -Exit code: 1 diff --git a/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.deploy.direct.txt b/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.deploy.txt similarity index 100% rename from acceptance/bundle/resources/quality_monitors/change_assets_dir/out.deploy.direct.txt rename to acceptance/bundle/resources/quality_monitors/change_assets_dir/out.deploy.txt diff --git a/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan.direct.json b/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan.json similarity index 100% rename from acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan.direct.json rename to acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan.json diff --git a/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan.terraform.json b/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan.terraform.json deleted file mode 100644 index ba464e9a3c2..00000000000 --- a/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.quality_monitors.monitor1": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan.terraform.txt b/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan.terraform.txt deleted file mode 100644 index f84d2e70af7..00000000000 --- a/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan.terraform.txt +++ /dev/null @@ -1,5 +0,0 @@ - ->>> errcode [CLI] bundle plan -update quality_monitors.monitor1 - -Plan: 0 to add, 1 to change, 0 to delete, 0 unchanged diff --git a/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan.direct.txt b/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan.txt similarity index 100% rename from acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan.direct.txt rename to acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan.txt diff --git a/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan_after_deploy.terraform.txt b/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan_after_deploy.terraform.txt deleted file mode 100644 index f84d2e70af7..00000000000 --- a/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan_after_deploy.terraform.txt +++ /dev/null @@ -1,5 +0,0 @@ - ->>> errcode [CLI] bundle plan -update quality_monitors.monitor1 - -Plan: 0 to add, 1 to change, 0 to delete, 0 unchanged diff --git a/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan_after_deploy.direct.txt b/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan_after_deploy.txt similarity index 100% rename from acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan_after_deploy.direct.txt rename to acceptance/bundle/resources/quality_monitors/change_assets_dir/out.plan_after_deploy.txt diff --git a/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.test.toml b/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.test.toml +++ b/acceptance/bundle/resources/quality_monitors/change_assets_dir/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/quality_monitors/change_assets_dir/script b/acceptance/bundle/resources/quality_monitors/change_assets_dir/script index cb01f841677..5ea603ee6fe 100644 --- a/acceptance/bundle/resources/quality_monitors/change_assets_dir/script +++ b/acceptance/bundle/resources/quality_monitors/change_assets_dir/script @@ -23,13 +23,13 @@ trace $CLI bundle plan | contains.py "1 unchanged" update_file.py databricks.yml "assets_dir: /Workspace/Users/$CURRENT_USER_NAME/monitor_assets_$UNIQUE_NAME" "assets_dir: /Workspace/Users/$CURRENT_USER_NAME/monitor_assets2_$UNIQUE_NAME" -trace errcode $CLI bundle plan &> out.plan.$DATABRICKS_BUNDLE_ENGINE.txt +trace errcode $CLI bundle plan &> out.plan.txt # Untraced: with &> the trace header lands in the file, leaving it unfilterable. Capture the raw # plan aside and stamp it out into the golden instead. errcode $CLI bundle plan -o json &> .databricks/tmp.plan.json -nostamp < .databricks/tmp.plan.json > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +nostamp < .databricks/tmp.plan.json > out.plan.json rm "$OUT_REQUESTS" -trace errcode $CLI bundle deploy &> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt -trace print_requests.py '^//api/2.0/bundle' '^//import-file/' '^//workspace/' '^//telemetry-ext' > out.deploy.requests.$DATABRICKS_BUNDLE_ENGINE.json -trace errcode $CLI bundle plan &> out.plan_after_deploy.$DATABRICKS_BUNDLE_ENGINE.txt +trace errcode $CLI bundle deploy &> out.deploy.txt +trace print_requests.py '^//api/2.0/bundle' '^//import-file/' '^//workspace/' '^//telemetry-ext' > out.deploy.requests.json +trace errcode $CLI bundle plan &> out.plan_after_deploy.txt diff --git a/acceptance/bundle/resources/quality_monitors/change_output_schema_name/out.plan.direct.json b/acceptance/bundle/resources/quality_monitors/change_output_schema_name/out.plan.json similarity index 100% rename from acceptance/bundle/resources/quality_monitors/change_output_schema_name/out.plan.direct.json rename to acceptance/bundle/resources/quality_monitors/change_output_schema_name/out.plan.json diff --git a/acceptance/bundle/resources/quality_monitors/change_output_schema_name/out.plan.terraform.json b/acceptance/bundle/resources/quality_monitors/change_output_schema_name/out.plan.terraform.json deleted file mode 100644 index ba464e9a3c2..00000000000 --- a/acceptance/bundle/resources/quality_monitors/change_output_schema_name/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.quality_monitors.monitor1": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/quality_monitors/change_output_schema_name/out.test.toml b/acceptance/bundle/resources/quality_monitors/change_output_schema_name/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/quality_monitors/change_output_schema_name/out.test.toml +++ b/acceptance/bundle/resources/quality_monitors/change_output_schema_name/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/quality_monitors/change_output_schema_name/script b/acceptance/bundle/resources/quality_monitors/change_output_schema_name/script index 08e1e8e3ffd..fbd62ade8df 100644 --- a/acceptance/bundle/resources/quality_monitors/change_output_schema_name/script +++ b/acceptance/bundle/resources/quality_monitors/change_output_schema_name/script @@ -22,7 +22,7 @@ trace $CLI bundle plan | contains.py "1 unchanged" update_file.py databricks.yml "output_schema_name: main.qm_test_${UNIQUE_NAME}" "output_schema_name: main.qm_test_${UNIQUE_NAME}_2" trace $CLI bundle plan | contains.py "1 to change" -trace $CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan.json rm "$OUT_REQUESTS" trace $CLI bundle deploy diff --git a/acceptance/bundle/resources/quality_monitors/change_table_name/out.deploy.requests.direct.json b/acceptance/bundle/resources/quality_monitors/change_table_name/out.deploy.requests.json similarity index 100% rename from acceptance/bundle/resources/quality_monitors/change_table_name/out.deploy.requests.direct.json rename to acceptance/bundle/resources/quality_monitors/change_table_name/out.deploy.requests.json diff --git a/acceptance/bundle/resources/quality_monitors/change_table_name/out.deploy.direct.txt b/acceptance/bundle/resources/quality_monitors/change_table_name/out.deploy.txt similarity index 100% rename from acceptance/bundle/resources/quality_monitors/change_table_name/out.deploy.direct.txt rename to acceptance/bundle/resources/quality_monitors/change_table_name/out.deploy.txt diff --git a/acceptance/bundle/resources/quality_monitors/change_table_name/out.get.direct.json b/acceptance/bundle/resources/quality_monitors/change_table_name/out.get.json similarity index 100% rename from acceptance/bundle/resources/quality_monitors/change_table_name/out.get.direct.json rename to acceptance/bundle/resources/quality_monitors/change_table_name/out.get.json diff --git a/acceptance/bundle/resources/quality_monitors/change_table_name/out.plan.direct.json b/acceptance/bundle/resources/quality_monitors/change_table_name/out.plan.json similarity index 100% rename from acceptance/bundle/resources/quality_monitors/change_table_name/out.plan.direct.json rename to acceptance/bundle/resources/quality_monitors/change_table_name/out.plan.json diff --git a/acceptance/bundle/resources/quality_monitors/change_table_name/out.plan.direct.txt b/acceptance/bundle/resources/quality_monitors/change_table_name/out.plan.txt similarity index 100% rename from acceptance/bundle/resources/quality_monitors/change_table_name/out.plan.direct.txt rename to acceptance/bundle/resources/quality_monitors/change_table_name/out.plan.txt diff --git a/acceptance/bundle/resources/quality_monitors/change_table_name/out.plan_after_deploy.direct.txt b/acceptance/bundle/resources/quality_monitors/change_table_name/out.plan_after_deploy.txt similarity index 100% rename from acceptance/bundle/resources/quality_monitors/change_table_name/out.plan_after_deploy.direct.txt rename to acceptance/bundle/resources/quality_monitors/change_table_name/out.plan_after_deploy.txt diff --git a/acceptance/bundle/resources/quality_monitors/change_table_name/out.test.toml b/acceptance/bundle/resources/quality_monitors/change_table_name/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/quality_monitors/change_table_name/out.test.toml +++ b/acceptance/bundle/resources/quality_monitors/change_table_name/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/quality_monitors/change_table_name/output.txt b/acceptance/bundle/resources/quality_monitors/change_table_name/output.txt index 0051a52528f..dda51726c88 100644 --- a/acceptance/bundle/resources/quality_monitors/change_table_name/output.txt +++ b/acceptance/bundle/resources/quality_monitors/change_table_name/output.txt @@ -17,7 +17,7 @@ Table main.qm_test_[UNIQUE_NAME].test_table_2 is now visible (catalog_name=main) >>> [CLI] bundle deploy Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/quality-monitor-update-[UNIQUE_NAME]/default/files... Created quality_monitors.monitor1 -Files: 4 uploaded, 0 deleted +Files: 3 uploaded, 0 deleted Resources: 1 created, 0 changed, 0 deleted, 0 unchanged >>> [CLI] bundle plan diff --git a/acceptance/bundle/resources/quality_monitors/change_table_name/script b/acceptance/bundle/resources/quality_monitors/change_table_name/script index 7f9093dbdfa..ca49568b38a 100644 --- a/acceptance/bundle/resources/quality_monitors/change_table_name/script +++ b/acceptance/bundle/resources/quality_monitors/change_table_name/script @@ -23,15 +23,15 @@ trace $CLI bundle plan | contains.py "1 unchanged" update_file.py databricks.yml "table_name: $TABLE_NAME" "table_name: ${TABLE_NAME}_2" -trace errcode $CLI bundle plan &> out.plan.$DATABRICKS_BUNDLE_ENGINE.txt +trace errcode $CLI bundle plan &> out.plan.txt # Untraced: with &> the trace header lands in the file, leaving it unfilterable. Capture the raw # plan aside and stamp it out into the golden instead. errcode $CLI bundle plan -o json &> .databricks/tmp.plan.json -nostamp < .databricks/tmp.plan.json > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +nostamp < .databricks/tmp.plan.json > out.plan.json rm "$OUT_REQUESTS" -trace errcode $CLI bundle deploy &> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt -trace print_requests.py '^//api/2.0/bundle' '^//import-file/' '^//workspace/' '^//telemetry-ext' > out.deploy.requests.$DATABRICKS_BUNDLE_ENGINE.json -trace errcode $CLI bundle plan &> out.plan_after_deploy.$DATABRICKS_BUNDLE_ENGINE.txt +trace errcode $CLI bundle deploy &> out.deploy.txt +trace print_requests.py '^//api/2.0/bundle' '^//import-file/' '^//workspace/' '^//telemetry-ext' > out.deploy.requests.json +trace errcode $CLI bundle plan &> out.plan_after_deploy.txt -trace errcode $CLI quality-monitors get ${TABLE_NAME}_2 2> /dev/null > out.get.$DATABRICKS_BUNDLE_ENGINE.json +trace errcode $CLI quality-monitors get ${TABLE_NAME}_2 2> /dev/null > out.get.json diff --git a/acceptance/bundle/resources/quality_monitors/change_table_name/test.toml b/acceptance/bundle/resources/quality_monitors/change_table_name/test.toml deleted file mode 100644 index 7e03ffedd9a..00000000000 --- a/acceptance/bundle/resources/quality_monitors/change_table_name/test.toml +++ /dev/null @@ -1,2 +0,0 @@ -# this does not work on terraform -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/quality_monitors/create/out.plan_create.direct.json b/acceptance/bundle/resources/quality_monitors/create/out.plan_create.json similarity index 100% rename from acceptance/bundle/resources/quality_monitors/create/out.plan_create.direct.json rename to acceptance/bundle/resources/quality_monitors/create/out.plan_create.json diff --git a/acceptance/bundle/resources/quality_monitors/create/out.plan_create.terraform.json b/acceptance/bundle/resources/quality_monitors/create/out.plan_create.terraform.json deleted file mode 100644 index 2ccead697f8..00000000000 --- a/acceptance/bundle/resources/quality_monitors/create/out.plan_create.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.quality_monitors.monitor1": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/quality_monitors/create/out.plan_noop.direct.json b/acceptance/bundle/resources/quality_monitors/create/out.plan_noop.json similarity index 100% rename from acceptance/bundle/resources/quality_monitors/create/out.plan_noop.direct.json rename to acceptance/bundle/resources/quality_monitors/create/out.plan_noop.json diff --git a/acceptance/bundle/resources/quality_monitors/create/out.plan_noop.terraform.json b/acceptance/bundle/resources/quality_monitors/create/out.plan_noop.terraform.json deleted file mode 100644 index 4fcb0670582..00000000000 --- a/acceptance/bundle/resources/quality_monitors/create/out.plan_noop.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.quality_monitors.monitor1": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/resources/quality_monitors/create/out.state.terraform.txt b/acceptance/bundle/resources/quality_monitors/create/out.state.terraform.txt deleted file mode 100644 index dbdd758797b..00000000000 --- a/acceptance/bundle/resources/quality_monitors/create/out.state.terraform.txt +++ /dev/null @@ -1,6 +0,0 @@ - "name": "monitor1", - "baseline_table_name": null, - "drift_metrics_table_name": "main.qm_test_[UNIQUE_NAME].test_table_drift_metrics", - "output_schema_name": "main.qm_test_[UNIQUE_NAME]", - "profile_metrics_table_name": "main.qm_test_[UNIQUE_NAME].test_table_profile_metrics", - "table_name": "main.qm_test_[UNIQUE_NAME].test_table", diff --git a/acceptance/bundle/resources/quality_monitors/create/out.state.direct.txt b/acceptance/bundle/resources/quality_monitors/create/out.state.txt similarity index 100% rename from acceptance/bundle/resources/quality_monitors/create/out.state.direct.txt rename to acceptance/bundle/resources/quality_monitors/create/out.state.txt diff --git a/acceptance/bundle/resources/quality_monitors/create/out.test.toml b/acceptance/bundle/resources/quality_monitors/create/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/quality_monitors/create/out.test.toml +++ b/acceptance/bundle/resources/quality_monitors/create/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/quality_monitors/create/script b/acceptance/bundle/resources/quality_monitors/create/script index e3466c9a386..b45b8226f4e 100644 --- a/acceptance/bundle/resources/quality_monitors/create/script +++ b/acceptance/bundle/resources/quality_monitors/create/script @@ -17,13 +17,13 @@ trap cleanup EXIT envsubst < databricks.yml.tmpl > databricks.yml -trace $CLI bundle plan -o json | nostamp > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_create.json rm "$OUT_REQUESTS" trace $CLI bundle deploy &> out.deploy.txt trace print_requests.py '^//api/2.0/bundle' '^//import-file/' '^//workspace/' '^//telemetry-ext' > out.deploy.requests.json # store state to ensure we have table_name there -print_state.py | grep name > out.state.$DATABRICKS_BUNDLE_ENGINE.txt +print_state.py | grep name > out.state.txt -trace $CLI bundle plan -o json | nostamp > out.plan_noop.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -o json | nostamp > out.plan_noop.json diff --git a/acceptance/bundle/resources/quality_monitors/test.toml b/acceptance/bundle/resources/quality_monitors/test.toml index 541dff9c5e1..587c7b669b1 100644 --- a/acceptance/bundle/resources/quality_monitors/test.toml +++ b/acceptance/bundle/resources/quality_monitors/test.toml @@ -2,7 +2,6 @@ Cloud = true RecordRequests = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] # Fake SQL endpoint for local tests [[Server]] diff --git a/acceptance/bundle/resources/registered_models/aliases_converge/out.test.toml b/acceptance/bundle/resources/registered_models/aliases_converge/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/registered_models/aliases_converge/out.test.toml +++ b/acceptance/bundle/resources/registered_models/aliases_converge/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/registered_models/aliases_converge/test.toml b/acceptance/bundle/resources/registered_models/aliases_converge/test.toml index b06ed5ceaab..85af31f8076 100644 --- a/acceptance/bundle/resources/registered_models/aliases_converge/test.toml +++ b/acceptance/bundle/resources/registered_models/aliases_converge/test.toml @@ -2,4 +2,3 @@ RecordRequests = false # The aliases input_only classification lives in the direct engine, so scope # this regression there. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/registered_models/basic/out.test.toml b/acceptance/bundle/resources/registered_models/basic/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/registered_models/basic/out.test.toml +++ b/acceptance/bundle/resources/registered_models/basic/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/registered_models/comment_cleared/out.test.toml b/acceptance/bundle/resources/registered_models/comment_cleared/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/registered_models/comment_cleared/out.test.toml +++ b/acceptance/bundle/resources/registered_models/comment_cleared/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/registered_models/comment_cleared/test.toml b/acceptance/bundle/resources/registered_models/comment_cleared/test.toml index 3ad98d57646..1a06951fb71 100644 --- a/acceptance/bundle/resources/registered_models/comment_cleared/test.toml +++ b/acceptance/bundle/resources/registered_models/comment_cleared/test.toml @@ -1,7 +1,6 @@ Cloud = true # UpdateRegisteredModel payload construction is direct-engine-specific. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ ".databricks", diff --git a/acceptance/bundle/resources/registered_models/drift/browse_only/out.test.toml b/acceptance/bundle/resources/registered_models/drift/browse_only/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/registered_models/drift/browse_only/out.test.toml +++ b/acceptance/bundle/resources/registered_models/drift/browse_only/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/registered_models/drift/browse_only/test.toml b/acceptance/bundle/resources/registered_models/drift/browse_only/test.toml index 979a73fd380..50f2c0e20df 100644 --- a/acceptance/bundle/resources/registered_models/drift/browse_only/test.toml +++ b/acceptance/bundle/resources/registered_models/drift/browse_only/test.toml @@ -2,4 +2,3 @@ RecordRequests = true # Terraform does not model browse_only as an output-only field the same way, so # scope this regression to the direct engine where the classification lives. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/schemas/auto-approve/out.test.toml b/acceptance/bundle/resources/schemas/auto-approve/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/schemas/auto-approve/out.test.toml +++ b/acceptance/bundle/resources/schemas/auto-approve/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/schemas/comment_out_of_band/out.test.toml b/acceptance/bundle/resources/schemas/comment_out_of_band/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/schemas/comment_out_of_band/out.test.toml +++ b/acceptance/bundle/resources/schemas/comment_out_of_band/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/schemas/comment_out_of_band/test.toml b/acceptance/bundle/resources/schemas/comment_out_of_band/test.toml index 65219bba62a..0b48c6a3619 100644 --- a/acceptance/bundle/resources/schemas/comment_out_of_band/test.toml +++ b/acceptance/bundle/resources/schemas/comment_out_of_band/test.toml @@ -1,7 +1,6 @@ Cloud = true # UpdateSchema payload construction is direct-engine-specific. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ ".databricks", diff --git a/acceptance/bundle/resources/schemas/drift/managed_properties/out.test.toml b/acceptance/bundle/resources/schemas/drift/managed_properties/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/schemas/drift/managed_properties/out.test.toml +++ b/acceptance/bundle/resources/schemas/drift/managed_properties/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/schemas/drift/managed_properties/test.toml b/acceptance/bundle/resources/schemas/drift/managed_properties/test.toml index 67819b3d322..a51c65be14e 100644 --- a/acceptance/bundle/resources/schemas/drift/managed_properties/test.toml +++ b/acceptance/bundle/resources/schemas/drift/managed_properties/test.toml @@ -2,4 +2,3 @@ RecordRequests = true # Terraform issues a spurious PATCH for enable_predictive_optimization on every # deploy, which is outside the scope of backend-default handling in schemas.yml. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/schemas/recreate/out.test.toml b/acceptance/bundle/resources/schemas/recreate/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/schemas/recreate/out.test.toml +++ b/acceptance/bundle/resources/schemas/recreate/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/schemas/update/out.test.toml b/acceptance/bundle/resources/schemas/update/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/schemas/update/out.test.toml +++ b/acceptance/bundle/resources/schemas/update/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/secret_scopes/backend-type/out.test.toml b/acceptance/bundle/resources/secret_scopes/backend-type/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/secret_scopes/backend-type/out.test.toml +++ b/acceptance/bundle/resources/secret_scopes/backend-type/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/secret_scopes/basic/out.plan1.terraform.txt b/acceptance/bundle/resources/secret_scopes/basic/out.plan1.terraform.txt deleted file mode 100644 index 64bdd6b32ea..00000000000 --- a/acceptance/bundle/resources/secret_scopes/basic/out.plan1.terraform.txt +++ /dev/null @@ -1,3 +0,0 @@ -json.cli_version = "[CLI_VERSION]"; -json.plan.resources.secret_scopes.my_scope.action = "create"; -json.plan.resources.secret_scopes.my_scope.permissions.action = "create"; diff --git a/acceptance/bundle/resources/secret_scopes/basic/out.plan1.direct.txt b/acceptance/bundle/resources/secret_scopes/basic/out.plan1.txt similarity index 100% rename from acceptance/bundle/resources/secret_scopes/basic/out.plan1.direct.txt rename to acceptance/bundle/resources/secret_scopes/basic/out.plan1.txt diff --git a/acceptance/bundle/resources/secret_scopes/basic/out.plan2.terraform.txt b/acceptance/bundle/resources/secret_scopes/basic/out.plan2.terraform.txt deleted file mode 100644 index a641b29a7ee..00000000000 --- a/acceptance/bundle/resources/secret_scopes/basic/out.plan2.terraform.txt +++ /dev/null @@ -1,3 +0,0 @@ -json.cli_version = "[CLI_VERSION]"; -json.plan.resources.secret_scopes.my_scope.action = "recreate"; -json.plan.resources.secret_scopes.my_scope.permissions.action = "recreate"; diff --git a/acceptance/bundle/resources/secret_scopes/basic/out.plan2.direct.txt b/acceptance/bundle/resources/secret_scopes/basic/out.plan2.txt similarity index 100% rename from acceptance/bundle/resources/secret_scopes/basic/out.plan2.direct.txt rename to acceptance/bundle/resources/secret_scopes/basic/out.plan2.txt diff --git a/acceptance/bundle/resources/secret_scopes/basic/out.plan_verify_no_drift.terraform.txt b/acceptance/bundle/resources/secret_scopes/basic/out.plan_verify_no_drift.terraform.txt deleted file mode 100644 index 77289e434e6..00000000000 --- a/acceptance/bundle/resources/secret_scopes/basic/out.plan_verify_no_drift.terraform.txt +++ /dev/null @@ -1,3 +0,0 @@ -json.cli_version = "[CLI_VERSION]"; -json.plan.resources.secret_scopes.my_scope.action = "skip"; -json.plan.resources.secret_scopes.my_scope.permissions.action = "skip"; diff --git a/acceptance/bundle/resources/secret_scopes/basic/out.plan_verify_no_drift.direct.txt b/acceptance/bundle/resources/secret_scopes/basic/out.plan_verify_no_drift.txt similarity index 100% rename from acceptance/bundle/resources/secret_scopes/basic/out.plan_verify_no_drift.direct.txt rename to acceptance/bundle/resources/secret_scopes/basic/out.plan_verify_no_drift.txt diff --git a/acceptance/bundle/resources/secret_scopes/basic/out.recreate-requests.terraform.txt b/acceptance/bundle/resources/secret_scopes/basic/out.recreate-requests.terraform.txt deleted file mode 100644 index efe7030cb94..00000000000 --- a/acceptance/bundle/resources/secret_scopes/basic/out.recreate-requests.terraform.txt +++ /dev/null @@ -1,32 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/secrets/acls/delete", - "body": { - "principal": "deco-test-user@databricks.com", - "scope": "test-scope-[UNIQUE_NAME]-1" - } -} -{ - "method": "POST", - "path": "/api/2.0/secrets/scopes/delete", - "body": { - "scope": "test-scope-[UNIQUE_NAME]-1" - } -} -{ - "method": "POST", - "path": "/api/2.0/secrets/scopes/create", - "body": { - "scope": "test-scope-[UNIQUE_NAME]-2", - "scope_backend_type": "DATABRICKS" - } -} -{ - "method": "POST", - "path": "/api/2.0/secrets/acls/put", - "body": { - "permission": "WRITE", - "principal": "deco-test-user@databricks.com", - "scope": "test-scope-[UNIQUE_NAME]-2" - } -} diff --git a/acceptance/bundle/resources/secret_scopes/basic/out.recreate-requests.direct.txt b/acceptance/bundle/resources/secret_scopes/basic/out.recreate-requests.txt similarity index 100% rename from acceptance/bundle/resources/secret_scopes/basic/out.recreate-requests.direct.txt rename to acceptance/bundle/resources/secret_scopes/basic/out.recreate-requests.txt diff --git a/acceptance/bundle/resources/secret_scopes/basic/out.test.toml b/acceptance/bundle/resources/secret_scopes/basic/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/secret_scopes/basic/out.test.toml +++ b/acceptance/bundle/resources/secret_scopes/basic/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/secret_scopes/basic/script b/acceptance/bundle/resources/secret_scopes/basic/script index e62f873b129..e034e35a34d 100755 --- a/acceptance/bundle/resources/secret_scopes/basic/script +++ b/acceptance/bundle/resources/secret_scopes/basic/script @@ -9,7 +9,7 @@ cleanup() { trap cleanup EXIT title "create the secret scope" -trace $CLI bundle plan -o json | nostamp | gron.py --sort-arrays acls > out.plan1.$DATABRICKS_BUNDLE_ENGINE.txt +trace $CLI bundle plan -o json | nostamp | gron.py --sort-arrays acls > out.plan1.txt trace $CLI bundle deploy -qq scope_name=$($CLI bundle summary --output json | jq -r '.resources.secret_scopes.my_scope.name') @@ -26,11 +26,11 @@ title "update the name of the scope (should recreate)" export SECRET_SCOPE_NAME="test-scope-$UNIQUE_NAME-2" envsubst < databricks.yml.tmpl > databricks.yml -trace $CLI bundle plan -o json | nostamp | gron.py --sort-arrays acls > out.plan2.$DATABRICKS_BUNDLE_ENGINE.txt +trace $CLI bundle plan -o json | nostamp | gron.py --sort-arrays acls > out.plan2.txt trace $CLI bundle deploy -qq # Capture API requests for verification. Terraform cleans up ACLs before deleting the scope, but direct does not, hence the difference in requests. -trace print_requests.py //secrets > out.recreate-requests.$DATABRICKS_BUNDLE_ENGINE.txt +trace print_requests.py //secrets > out.recreate-requests.txt scope_name=$($CLI bundle summary --output json | jq -r '.resources.secret_scopes.my_scope.name') trace $CLI secrets list-scopes -o json | jq ".[] | select(.name == \"$scope_name\")" @@ -43,4 +43,4 @@ trace $CLI secrets list-acls $scope_name | jq -c '.[]' | sort trace print_requests.py //secrets title "verify there's no persistent drift" -trace $CLI bundle plan -o json | nostamp | gron.py --sort-arrays acls > out.plan_verify_no_drift.$DATABRICKS_BUNDLE_ENGINE.txt +trace $CLI bundle plan -o json | nostamp | gron.py --sort-arrays acls > out.plan_verify_no_drift.txt diff --git a/acceptance/bundle/resources/secret_scopes/delete_scope/out.plan.terraform.txt b/acceptance/bundle/resources/secret_scopes/delete_scope/out.plan.terraform.txt deleted file mode 100644 index 989400461fa..00000000000 --- a/acceptance/bundle/resources/secret_scopes/delete_scope/out.plan.terraform.txt +++ /dev/null @@ -1,5 +0,0 @@ - ->>> [CLI] bundle plan -delete secret_scopes.second - -Plan: 0 to add, 0 to change, 1 to delete, 1 unchanged diff --git a/acceptance/bundle/resources/secret_scopes/delete_scope/out.plan.direct.txt b/acceptance/bundle/resources/secret_scopes/delete_scope/out.plan.txt similarity index 100% rename from acceptance/bundle/resources/secret_scopes/delete_scope/out.plan.direct.txt rename to acceptance/bundle/resources/secret_scopes/delete_scope/out.plan.txt diff --git a/acceptance/bundle/resources/secret_scopes/delete_scope/out.test.toml b/acceptance/bundle/resources/secret_scopes/delete_scope/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/secret_scopes/delete_scope/out.test.toml +++ b/acceptance/bundle/resources/secret_scopes/delete_scope/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/secret_scopes/delete_scope/script b/acceptance/bundle/resources/secret_scopes/delete_scope/script index f9e0b9676a3..6cd30fffdae 100755 --- a/acceptance/bundle/resources/secret_scopes/delete_scope/script +++ b/acceptance/bundle/resources/secret_scopes/delete_scope/script @@ -11,7 +11,7 @@ trace $CLI bundle deploy -qq grep -v DELETE < databricks.yml > databricks.yml.tmp && mv databricks.yml.tmp databricks.yml -trace $CLI bundle plan &> out.plan.$DATABRICKS_BUNDLE_ENGINE.txt +trace $CLI bundle plan &> out.plan.txt rm "$OUT_REQUESTS" trace $CLI bundle deploy -qq diff --git a/acceptance/bundle/resources/secret_scopes/permissions-collapse/out.plan.direct.txt b/acceptance/bundle/resources/secret_scopes/permissions-collapse/out.plan.txt similarity index 100% rename from acceptance/bundle/resources/secret_scopes/permissions-collapse/out.plan.direct.txt rename to acceptance/bundle/resources/secret_scopes/permissions-collapse/out.plan.txt diff --git a/acceptance/bundle/resources/secret_scopes/permissions-collapse/out.test.toml b/acceptance/bundle/resources/secret_scopes/permissions-collapse/out.test.toml index 3f27baf73db..67a16a8bcf3 100644 --- a/acceptance/bundle/resources/secret_scopes/permissions-collapse/out.test.toml +++ b/acceptance/bundle/resources/secret_scopes/permissions-collapse/out.test.toml @@ -1,5 +1,4 @@ Cloud = true RunsOnDbr = true CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/secret_scopes/permissions-collapse/script b/acceptance/bundle/resources/secret_scopes/permissions-collapse/script index 6c2b4366c35..1b0040a2cbb 100755 --- a/acceptance/bundle/resources/secret_scopes/permissions-collapse/script +++ b/acceptance/bundle/resources/secret_scopes/permissions-collapse/script @@ -8,7 +8,7 @@ cleanup() { trap cleanup EXIT title "create secret scope with duplicate permissions" -trace $CLI bundle plan > out.plan.$DATABRICKS_BUNDLE_ENGINE.txt +trace $CLI bundle plan > out.plan.txt trace $CLI bundle deploy scope_name=$($CLI bundle summary --output json | jq -r '.resources.secret_scopes.my_scope.name') diff --git a/acceptance/bundle/resources/secret_scopes/permissions-collapse/test.toml b/acceptance/bundle/resources/secret_scopes/permissions-collapse/test.toml index 4d0b3d0cb2b..d927cd90be4 100644 --- a/acceptance/bundle/resources/secret_scopes/permissions-collapse/test.toml +++ b/acceptance/bundle/resources/secret_scopes/permissions-collapse/test.toml @@ -5,5 +5,3 @@ IsServicePrincipal = true # The current user on GCP is not a service principal. This causes diverging output since we set permissions for the current user. Thus we skip this test on GCP. CloudEnvs.gcp = false - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/secret_scopes/permissions/out.plan.recreate.terraform.txt b/acceptance/bundle/resources/secret_scopes/permissions/out.plan.recreate.terraform.txt deleted file mode 100644 index 6126244cbe3..00000000000 --- a/acceptance/bundle/resources/secret_scopes/permissions/out.plan.recreate.terraform.txt +++ /dev/null @@ -1,4 +0,0 @@ -recreate secret_scopes.my_scope -recreate secret_scopes.my_scope.permissions - -Plan: 2 to add, 0 to change, 2 to delete, 0 unchanged diff --git a/acceptance/bundle/resources/secret_scopes/permissions/out.plan.recreate.direct.txt b/acceptance/bundle/resources/secret_scopes/permissions/out.plan.recreate.txt similarity index 100% rename from acceptance/bundle/resources/secret_scopes/permissions/out.plan.recreate.direct.txt rename to acceptance/bundle/resources/secret_scopes/permissions/out.plan.recreate.txt diff --git a/acceptance/bundle/resources/secret_scopes/permissions/out.test.toml b/acceptance/bundle/resources/secret_scopes/permissions/out.test.toml index a560ff5a08f..67a16a8bcf3 100644 --- a/acceptance/bundle/resources/secret_scopes/permissions/out.test.toml +++ b/acceptance/bundle/resources/secret_scopes/permissions/out.test.toml @@ -1,5 +1,4 @@ Cloud = true RunsOnDbr = true CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/secret_scopes/permissions/script b/acceptance/bundle/resources/secret_scopes/permissions/script index ad5d2a518f1..8f8b8308d24 100755 --- a/acceptance/bundle/resources/secret_scopes/permissions/script +++ b/acceptance/bundle/resources/secret_scopes/permissions/script @@ -67,7 +67,7 @@ trace $CLI secrets list-acls $scope_name | jq -c '.[]' | sort title "change scope name (should recreate scope and update permissions)" export SECRET_SCOPE_NAME="test-scope-permissions-$UNIQUE_NAME-2" envsubst < databricks.yml.tmpl > databricks.yml -trace $CLI bundle plan > out.plan.recreate.$DATABRICKS_BUNDLE_ENGINE.txt +trace $CLI bundle plan > out.plan.recreate.txt trace $CLI bundle deploy -qq scope_name=$($CLI bundle summary --output json | jq -r '.resources.secret_scopes.my_scope.name') trace $CLI secrets list-scopes -o json | jq ".[] | select(.name == \"$scope_name\")" diff --git a/acceptance/bundle/resources/secrets/basic/out.test.toml b/acceptance/bundle/resources/secrets/basic/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/secrets/basic/out.test.toml +++ b/acceptance/bundle/resources/secrets/basic/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/secrets/basic/test.toml b/acceptance/bundle/resources/secrets/basic/test.toml index 78d49e21a1b..48fe22b99ac 100644 --- a/acceptance/bundle/resources/secrets/basic/test.toml +++ b/acceptance/bundle/resources/secrets/basic/test.toml @@ -2,5 +2,3 @@ Cloud = true RecordRequests = true Ignore = [".databricks"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/secrets/direct-only/databricks.yml b/acceptance/bundle/resources/secrets/direct-only/databricks.yml deleted file mode 100644 index 6edb6f3cf13..00000000000 --- a/acceptance/bundle/resources/secrets/direct-only/databricks.yml +++ /dev/null @@ -1,14 +0,0 @@ -bundle: - name: test-bundle - -variables: - secret_value: - description: "Test secret value" - -resources: - secrets: - secret1: - catalog_name: main - schema_name: default - name: test_secret - value: ${var.secret_value} diff --git a/acceptance/bundle/resources/secrets/direct-only/out.test.toml b/acceptance/bundle/resources/secrets/direct-only/out.test.toml deleted file mode 100644 index 5d0f3e4aac2..00000000000 --- a/acceptance/bundle/resources/secrets/direct-only/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] -EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/secrets/direct-only/output.txt b/acceptance/bundle/resources/secrets/direct-only/output.txt deleted file mode 100644 index d3bef4d3b23..00000000000 --- a/acceptance/bundle/resources/secrets/direct-only/output.txt +++ /dev/null @@ -1,11 +0,0 @@ - -=== Deploy should fail in terraform mode ->>> [CLI] bundle deploy --var secret_value=test-value -Error: Secret resources are only supported with direct deployment mode - in databricks.yml:10:5 - -Secret resources require direct deployment mode. Please set the DATABRICKS_BUNDLE_ENGINE environment variable to 'direct' or set 'bundle.engine: direct' in your databricks.yml to use secret resources. -Learn more at https://docs.databricks.com/dev-tools/bundles/direct - - -Exit code: 1 diff --git a/acceptance/bundle/resources/secrets/direct-only/script b/acceptance/bundle/resources/secrets/direct-only/script deleted file mode 100755 index 4ec9195eef9..00000000000 --- a/acceptance/bundle/resources/secrets/direct-only/script +++ /dev/null @@ -1,4 +0,0 @@ -title "Deploy should fail in terraform mode" -trace $CLI bundle deploy --var secret_value=test-value 2>&1 | contains.py \ - "Secret resources are only supported with direct deployment mode" \ - "DATABRICKS_BUNDLE_ENGINE" diff --git a/acceptance/bundle/resources/secrets/direct-only/test.toml b/acceptance/bundle/resources/secrets/direct-only/test.toml deleted file mode 100644 index 848edb71323..00000000000 --- a/acceptance/bundle/resources/secrets/direct-only/test.toml +++ /dev/null @@ -1,6 +0,0 @@ -Cloud = false -RecordRequests = false - -Ignore = [".databricks"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] diff --git a/acceptance/bundle/resources/secrets/remove-expire-time/out.plan.drift.direct.json b/acceptance/bundle/resources/secrets/remove-expire-time/out.plan.drift.json similarity index 100% rename from acceptance/bundle/resources/secrets/remove-expire-time/out.plan.drift.direct.json rename to acceptance/bundle/resources/secrets/remove-expire-time/out.plan.drift.json diff --git a/acceptance/bundle/resources/secrets/remove-expire-time/out.plan.direct.json b/acceptance/bundle/resources/secrets/remove-expire-time/out.plan.json similarity index 100% rename from acceptance/bundle/resources/secrets/remove-expire-time/out.plan.direct.json rename to acceptance/bundle/resources/secrets/remove-expire-time/out.plan.json diff --git a/acceptance/bundle/resources/secrets/remove-expire-time/out.test.toml b/acceptance/bundle/resources/secrets/remove-expire-time/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/secrets/remove-expire-time/out.test.toml +++ b/acceptance/bundle/resources/secrets/remove-expire-time/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/secrets/remove-expire-time/script b/acceptance/bundle/resources/secrets/remove-expire-time/script index 1659dfb2fee..47d893a4449 100644 --- a/acceptance/bundle/resources/secrets/remove-expire-time/script +++ b/acceptance/bundle/resources/secrets/remove-expire-time/script @@ -13,13 +13,13 @@ read_state.py secrets secret1 name expire_time title "Remove expire_time and re-deploy" trace update_file.py databricks.yml ' expire_time: "2030-01-01T00:00:00Z"' "" trace $CLI bundle plan --var secret_value=secret-value -trace $CLI bundle plan --var secret_value=secret-value -o json | nostamp | jq '.plan."resources.secrets.secret1" | {action, changes}' > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan --var secret_value=secret-value -o json | nostamp | jq '.plan."resources.secrets.secret1" | {action, changes}' > out.plan.json trace $CLI bundle deploy --var secret_value=secret-value trace print_requests.py //unity-catalog read_state.py secrets secret1 name expire_time title "Plan again to record any drift the removal leaves behind" trace $CLI bundle plan --var secret_value=secret-value -trace $CLI bundle plan --var secret_value=secret-value -o json | nostamp | jq '.plan."resources.secrets.secret1" | {action, changes}' > out.plan.drift.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan --var secret_value=secret-value -o json | nostamp | jq '.plan."resources.secrets.secret1" | {action, changes}' > out.plan.drift.json rm -f "$OUT_REQUESTS" diff --git a/acceptance/bundle/resources/secrets/remove-expire-time/test.toml b/acceptance/bundle/resources/secrets/remove-expire-time/test.toml index fd26f5c84d1..4295647466f 100644 --- a/acceptance/bundle/resources/secrets/remove-expire-time/test.toml +++ b/acceptance/bundle/resources/secrets/remove-expire-time/test.toml @@ -3,7 +3,6 @@ RecordRequests = true Ignore = [".databricks", ".gitignore"] # Secrets are only implemented in the direct engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # secrets/basic runs on cloud, so the expire_time semantics here are verified # against a real workspace too. @@ -13,7 +12,7 @@ Cloud = true # update_mask=* and omits the field, and the API keeps the previous value (verified # against a real workspace on 2026-08-25). Unlike the postgres project case the # difference is at least visible, because the secret GET echoes expire_time, so every -# later plan asks for the removal again. out.plan.drift.direct.json records that. +# later plan asks for the removal again. out.plan.drift.json records that. Badness = "Removing expire_time never takes effect: the API keeps the previous value, so deploy reports success and every later plan asks for the removal again" # The root test.toml collapses every timestamp to [TIMESTAMP], which would hide the diff --git a/acceptance/bundle/resources/secrets/update-expire-time/out.plan.direct.json b/acceptance/bundle/resources/secrets/update-expire-time/out.plan.json similarity index 100% rename from acceptance/bundle/resources/secrets/update-expire-time/out.plan.direct.json rename to acceptance/bundle/resources/secrets/update-expire-time/out.plan.json diff --git a/acceptance/bundle/resources/secrets/update-expire-time/out.test.toml b/acceptance/bundle/resources/secrets/update-expire-time/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/secrets/update-expire-time/out.test.toml +++ b/acceptance/bundle/resources/secrets/update-expire-time/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/secrets/update-expire-time/script b/acceptance/bundle/resources/secrets/update-expire-time/script index fe58d8c30c0..37ac6a79215 100644 --- a/acceptance/bundle/resources/secrets/update-expire-time/script +++ b/acceptance/bundle/resources/secrets/update-expire-time/script @@ -13,7 +13,7 @@ read_state.py secrets secret1 name expire_time title "Change expire_time and re-deploy" trace update_file.py databricks.yml "2030-01-01T00:00:00Z" "2031-06-15T12:00:00Z" trace $CLI bundle plan --var secret_value=secret-value -trace $CLI bundle plan --var secret_value=secret-value -o json | nostamp | jq '.plan."resources.secrets.secret1" | {action, changes}' > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan --var secret_value=secret-value -o json | nostamp | jq '.plan."resources.secrets.secret1" | {action, changes}' > out.plan.json trace $CLI bundle deploy --var secret_value=secret-value trace print_requests.py //unity-catalog read_state.py secrets secret1 name expire_time diff --git a/acceptance/bundle/resources/secrets/update-expire-time/test.toml b/acceptance/bundle/resources/secrets/update-expire-time/test.toml index dda317530a6..4e6b4e8964e 100644 --- a/acceptance/bundle/resources/secrets/update-expire-time/test.toml +++ b/acceptance/bundle/resources/secrets/update-expire-time/test.toml @@ -3,7 +3,6 @@ RecordRequests = true Ignore = [".databricks", ".gitignore"] # Secrets are only implemented in the direct engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # secrets/basic runs on cloud, so the expire_time semantics here are verified # against a real workspace too. diff --git a/acceptance/bundle/resources/secrets/update-value/out.test.toml b/acceptance/bundle/resources/secrets/update-value/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/secrets/update-value/out.test.toml +++ b/acceptance/bundle/resources/secrets/update-value/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/secrets/update-value/test.toml b/acceptance/bundle/resources/secrets/update-value/test.toml index 5d9988a96d7..3fada8d1657 100644 --- a/acceptance/bundle/resources/secrets/update-value/test.toml +++ b/acceptance/bundle/resources/secrets/update-value/test.toml @@ -2,5 +2,3 @@ Cloud = false RecordRequests = true Ignore = [".databricks", ".gitignore"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/secrets/validate-no-plain-text-default/out.test.toml b/acceptance/bundle/resources/secrets/validate-no-plain-text-default/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/secrets/validate-no-plain-text-default/out.test.toml +++ b/acceptance/bundle/resources/secrets/validate-no-plain-text-default/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/secrets/validate-no-plain-text-default/test.toml b/acceptance/bundle/resources/secrets/validate-no-plain-text-default/test.toml index f1bfe54d29e..4e86fd8ba52 100644 --- a/acceptance/bundle/resources/secrets/validate-no-plain-text-default/test.toml +++ b/acceptance/bundle/resources/secrets/validate-no-plain-text-default/test.toml @@ -2,5 +2,3 @@ Cloud = false RecordRequests = false Ignore = [".databricks"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/secrets/validate-no-plain-text/out.test.toml b/acceptance/bundle/resources/secrets/validate-no-plain-text/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/secrets/validate-no-plain-text/out.test.toml +++ b/acceptance/bundle/resources/secrets/validate-no-plain-text/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/secrets/validate-no-plain-text/test.toml b/acceptance/bundle/resources/secrets/validate-no-plain-text/test.toml index f1bfe54d29e..4e86fd8ba52 100644 --- a/acceptance/bundle/resources/secrets/validate-no-plain-text/test.toml +++ b/acceptance/bundle/resources/secrets/validate-no-plain-text/test.toml @@ -2,5 +2,3 @@ Cloud = false RecordRequests = false Ignore = [".databricks"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/secrets/validate-secret-is-string/out.test.toml b/acceptance/bundle/resources/secrets/validate-secret-is-string/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/secrets/validate-secret-is-string/out.test.toml +++ b/acceptance/bundle/resources/secrets/validate-secret-is-string/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/secrets/validate-secret-is-string/test.toml b/acceptance/bundle/resources/secrets/validate-secret-is-string/test.toml index f1bfe54d29e..4e86fd8ba52 100644 --- a/acceptance/bundle/resources/secrets/validate-secret-is-string/test.toml +++ b/acceptance/bundle/resources/secrets/validate-secret-is-string/test.toml @@ -2,5 +2,3 @@ Cloud = false RecordRequests = false Ignore = [".databricks"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/sql_warehouses/lifecycle-started-edit/out.test.toml b/acceptance/bundle/resources/sql_warehouses/lifecycle-started-edit/out.test.toml index f9f4880725d..8bfa768b35b 100644 --- a/acceptance/bundle/resources/sql_warehouses/lifecycle-started-edit/out.test.toml +++ b/acceptance/bundle/resources/sql_warehouses/lifecycle-started-edit/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/sql_warehouses/lifecycle-started-edit/test.toml b/acceptance/bundle/resources/sql_warehouses/lifecycle-started-edit/test.toml index d418e49465a..b6ef0492c6a 100644 --- a/acceptance/bundle/resources/sql_warehouses/lifecycle-started-edit/test.toml +++ b/acceptance/bundle/resources/sql_warehouses/lifecycle-started-edit/test.toml @@ -7,5 +7,3 @@ Cloud = true CloudSlow = true Ignore = [".databricks", "databricks.yml"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/sql_warehouses/lifecycle-started-terraform-error/databricks.yml.tmpl b/acceptance/bundle/resources/sql_warehouses/lifecycle-started-terraform-error/databricks.yml.tmpl deleted file mode 100644 index cad38109b8e..00000000000 --- a/acceptance/bundle/resources/sql_warehouses/lifecycle-started-terraform-error/databricks.yml.tmpl +++ /dev/null @@ -1,13 +0,0 @@ -bundle: - name: lifecycle-started-terraform-error-$UNIQUE_NAME - -workspace: - root_path: ~/.bundle/$UNIQUE_NAME - -resources: - sql_warehouses: - mywarehouse: - name: my-warehouse-$UNIQUE_NAME - cluster_size: "Medium" - lifecycle: - started: true diff --git a/acceptance/bundle/resources/sql_warehouses/lifecycle-started-terraform-error/out.test.toml b/acceptance/bundle/resources/sql_warehouses/lifecycle-started-terraform-error/out.test.toml deleted file mode 100644 index c5c084b944a..00000000000 --- a/acceptance/bundle/resources/sql_warehouses/lifecycle-started-terraform-error/out.test.toml +++ /dev/null @@ -1,4 +0,0 @@ -Cloud = false -CloudSlow = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] -EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/sql_warehouses/lifecycle-started-terraform-error/output.txt b/acceptance/bundle/resources/sql_warehouses/lifecycle-started-terraform-error/output.txt deleted file mode 100644 index 67d9a86b663..00000000000 --- a/acceptance/bundle/resources/sql_warehouses/lifecycle-started-terraform-error/output.txt +++ /dev/null @@ -1,16 +0,0 @@ - -=== bundle plan fails with lifecycle.started on terraform engine ->>> errcode [CLI] bundle plan -Error: lifecycle.started is only supported in direct deployment mode - in databricks.yml:13:18 - - -Exit code: 1 - -=== bundle deploy fails with lifecycle.started on terraform engine ->>> errcode [CLI] bundle deploy -Error: lifecycle.started is only supported in direct deployment mode - in databricks.yml:13:18 - - -Exit code: 1 diff --git a/acceptance/bundle/resources/sql_warehouses/lifecycle-started-terraform-error/script b/acceptance/bundle/resources/sql_warehouses/lifecycle-started-terraform-error/script deleted file mode 100644 index 4fb2038cd28..00000000000 --- a/acceptance/bundle/resources/sql_warehouses/lifecycle-started-terraform-error/script +++ /dev/null @@ -1,7 +0,0 @@ -envsubst < databricks.yml.tmpl > databricks.yml - -title "bundle plan fails with lifecycle.started on terraform engine" -trace errcode $CLI bundle plan - -title "bundle deploy fails with lifecycle.started on terraform engine" -trace errcode $CLI bundle deploy diff --git a/acceptance/bundle/resources/sql_warehouses/lifecycle-started-terraform-error/test.toml b/acceptance/bundle/resources/sql_warehouses/lifecycle-started-terraform-error/test.toml deleted file mode 100644 index 360624406cb..00000000000 --- a/acceptance/bundle/resources/sql_warehouses/lifecycle-started-terraform-error/test.toml +++ /dev/null @@ -1,8 +0,0 @@ -RecordRequests = false - -# This test performs static validation; no need to run on cloud. -Cloud = false - -Ignore = [".databricks", "databricks.yml"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] diff --git a/acceptance/bundle/resources/sql_warehouses/lifecycle-started-toggle/out.test.toml b/acceptance/bundle/resources/sql_warehouses/lifecycle-started-toggle/out.test.toml index 803afc4b4ae..403a04639c4 100644 --- a/acceptance/bundle/resources/sql_warehouses/lifecycle-started-toggle/out.test.toml +++ b/acceptance/bundle/resources/sql_warehouses/lifecycle-started-toggle/out.test.toml @@ -1,4 +1,3 @@ Cloud = false CloudSlow = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/sql_warehouses/lifecycle-started-toggle/test.toml b/acceptance/bundle/resources/sql_warehouses/lifecycle-started-toggle/test.toml index ea6f3c7767e..a13cf8200a4 100644 --- a/acceptance/bundle/resources/sql_warehouses/lifecycle-started-toggle/test.toml +++ b/acceptance/bundle/resources/sql_warehouses/lifecycle-started-toggle/test.toml @@ -5,5 +5,3 @@ RecordRequests = true Cloud = false Ignore = [".databricks", "databricks.yml"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/sql_warehouses/lifecycle-started/out.test.toml b/acceptance/bundle/resources/sql_warehouses/lifecycle-started/out.test.toml index 803afc4b4ae..403a04639c4 100644 --- a/acceptance/bundle/resources/sql_warehouses/lifecycle-started/out.test.toml +++ b/acceptance/bundle/resources/sql_warehouses/lifecycle-started/out.test.toml @@ -1,4 +1,3 @@ Cloud = false CloudSlow = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/sql_warehouses/lifecycle-started/test.toml b/acceptance/bundle/resources/sql_warehouses/lifecycle-started/test.toml index ea6f3c7767e..a13cf8200a4 100644 --- a/acceptance/bundle/resources/sql_warehouses/lifecycle-started/test.toml +++ b/acceptance/bundle/resources/sql_warehouses/lifecycle-started/test.toml @@ -5,5 +5,3 @@ RecordRequests = true Cloud = false Ignore = [".databricks", "databricks.yml"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/sql_warehouses/out.test.toml b/acceptance/bundle/resources/sql_warehouses/out.test.toml index 4f0550c97b2..403a04639c4 100644 --- a/acceptance/bundle/resources/sql_warehouses/out.test.toml +++ b/acceptance/bundle/resources/sql_warehouses/out.test.toml @@ -1,4 +1,3 @@ Cloud = false CloudSlow = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/sql_warehouses/output.txt b/acceptance/bundle/resources/sql_warehouses/output.txt index 986c9822bbc..08a337cce3f 100644 --- a/acceptance/bundle/resources/sql_warehouses/output.txt +++ b/acceptance/bundle/resources/sql_warehouses/output.txt @@ -37,7 +37,7 @@ Resources: >>> [CLI] bundle deploy Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test_sql_warehouse/default/files... Created sql_warehouses.test_sql_warehouse -Files: 19 uploaded, 0 deleted +Files: 15 uploaded, 0 deleted Resources: 1 created, 0 changed, 0 deleted, 0 unchanged === Verify the create request diff --git a/acceptance/bundle/resources/synced_database_tables/basic/out.test.toml b/acceptance/bundle/resources/synced_database_tables/basic/out.test.toml index 3247a9b2071..23cf24e68f4 100644 --- a/acceptance/bundle/resources/synced_database_tables/basic/out.test.toml +++ b/acceptance/bundle/resources/synced_database_tables/basic/out.test.toml @@ -1,5 +1,4 @@ Cloud = true RunsOnDbr = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/synced_database_tables/recreate/out.test.toml b/acceptance/bundle/resources/synced_database_tables/recreate/out.test.toml index bfeb0bd3aea..f7840b7a1df 100644 --- a/acceptance/bundle/resources/synced_database_tables/recreate/out.test.toml +++ b/acceptance/bundle/resources/synced_database_tables/recreate/out.test.toml @@ -1,4 +1,3 @@ Cloud = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/synced_database_tables/recreate/test.toml b/acceptance/bundle/resources/synced_database_tables/recreate/test.toml index 664eda83b1b..3c1096e8207 100644 --- a/acceptance/bundle/resources/synced_database_tables/recreate/test.toml +++ b/acceptance/bundle/resources/synced_database_tables/recreate/test.toml @@ -1,7 +1,6 @@ # The Database API has no UpdateSyncedDatabaseTable endpoint (PATCH returns 501), # so any field change must go through delete + create. The direct engine handles # this; the terraform path would need an upstream provider fix and is excluded. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] RecordRequests = true Ignore = [ diff --git a/acceptance/bundle/resources/vector_search_endpoints/basic/out.requests.direct.json b/acceptance/bundle/resources/vector_search_endpoints/basic/out.requests.json similarity index 100% rename from acceptance/bundle/resources/vector_search_endpoints/basic/out.requests.direct.json rename to acceptance/bundle/resources/vector_search_endpoints/basic/out.requests.json diff --git a/acceptance/bundle/resources/vector_search_endpoints/basic/out.test.toml b/acceptance/bundle/resources/vector_search_endpoints/basic/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/vector_search_endpoints/basic/out.test.toml +++ b/acceptance/bundle/resources/vector_search_endpoints/basic/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/vector_search_endpoints/basic/script b/acceptance/bundle/resources/vector_search_endpoints/basic/script index b4402e1208b..8e0e7b750f9 100644 --- a/acceptance/bundle/resources/vector_search_endpoints/basic/script +++ b/acceptance/bundle/resources/vector_search_endpoints/basic/script @@ -19,4 +19,4 @@ trace $CLI vector-search-endpoints get-endpoint "${endpoint_name}" | jq '{name, trace $CLI bundle summary -trace print_requests.py //vector-search/endpoints > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //vector-search/endpoints > out.requests.json diff --git a/acceptance/bundle/resources/vector_search_endpoints/drift/budget_policy/out.test.toml b/acceptance/bundle/resources/vector_search_endpoints/drift/budget_policy/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/vector_search_endpoints/drift/budget_policy/out.test.toml +++ b/acceptance/bundle/resources/vector_search_endpoints/drift/budget_policy/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/vector_search_endpoints/drift/recreated_same_name/out.test.toml b/acceptance/bundle/resources/vector_search_endpoints/drift/recreated_same_name/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/vector_search_endpoints/drift/recreated_same_name/out.test.toml +++ b/acceptance/bundle/resources/vector_search_endpoints/drift/recreated_same_name/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/vector_search_endpoints/drift/target_qps/out.plan.direct.json b/acceptance/bundle/resources/vector_search_endpoints/drift/target_qps/out.plan.json similarity index 100% rename from acceptance/bundle/resources/vector_search_endpoints/drift/target_qps/out.plan.direct.json rename to acceptance/bundle/resources/vector_search_endpoints/drift/target_qps/out.plan.json diff --git a/acceptance/bundle/resources/vector_search_endpoints/drift/target_qps/out.test.toml b/acceptance/bundle/resources/vector_search_endpoints/drift/target_qps/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/vector_search_endpoints/drift/target_qps/out.test.toml +++ b/acceptance/bundle/resources/vector_search_endpoints/drift/target_qps/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/vector_search_endpoints/drift/target_qps/script b/acceptance/bundle/resources/vector_search_endpoints/drift/target_qps/script index e6c3ad0e40d..d241f664d68 100644 --- a/acceptance/bundle/resources/vector_search_endpoints/drift/target_qps/script +++ b/acceptance/bundle/resources/vector_search_endpoints/drift/target_qps/script @@ -16,7 +16,7 @@ trace $CLI vector-search-endpoints patch-endpoint "${endpoint_name}" --target-qp title "Plan detects drift and proposes update" trace $CLI bundle plan | contains.py "Plan: 0 to add, 1 to change, 0 to delete, 0 unchanged" -$CLI bundle plan --output json | nostamp | jq '{plan: .plan | map_values({action, changes})}' > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan --output json | nostamp | jq '{plan: .plan | map_values({action, changes})}' > out.plan.json title "Deploy restores target_qps to 1" rm -f "$OUT_REQUESTS" diff --git a/acceptance/bundle/resources/vector_search_endpoints/recreate/create-fails/out.test.toml b/acceptance/bundle/resources/vector_search_endpoints/recreate/create-fails/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/vector_search_endpoints/recreate/create-fails/out.test.toml +++ b/acceptance/bundle/resources/vector_search_endpoints/recreate/create-fails/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/vector_search_endpoints/recreate/endpoint_type/out.requests.create.direct.json b/acceptance/bundle/resources/vector_search_endpoints/recreate/endpoint_type/out.requests.create.json similarity index 100% rename from acceptance/bundle/resources/vector_search_endpoints/recreate/endpoint_type/out.requests.create.direct.json rename to acceptance/bundle/resources/vector_search_endpoints/recreate/endpoint_type/out.requests.create.json diff --git a/acceptance/bundle/resources/vector_search_endpoints/recreate/endpoint_type/out.requests.recreate.direct.json b/acceptance/bundle/resources/vector_search_endpoints/recreate/endpoint_type/out.requests.recreate.json similarity index 100% rename from acceptance/bundle/resources/vector_search_endpoints/recreate/endpoint_type/out.requests.recreate.direct.json rename to acceptance/bundle/resources/vector_search_endpoints/recreate/endpoint_type/out.requests.recreate.json diff --git a/acceptance/bundle/resources/vector_search_endpoints/recreate/endpoint_type/out.test.toml b/acceptance/bundle/resources/vector_search_endpoints/recreate/endpoint_type/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/vector_search_endpoints/recreate/endpoint_type/out.test.toml +++ b/acceptance/bundle/resources/vector_search_endpoints/recreate/endpoint_type/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/vector_search_endpoints/recreate/endpoint_type/script b/acceptance/bundle/resources/vector_search_endpoints/recreate/endpoint_type/script index 309e21a3a49..7d26c1eb0a3 100644 --- a/acceptance/bundle/resources/vector_search_endpoints/recreate/endpoint_type/script +++ b/acceptance/bundle/resources/vector_search_endpoints/recreate/endpoint_type/script @@ -8,7 +8,7 @@ trap cleanup EXIT print_requests() { local name=$1 - trace print_requests.py --keep '//vector-search/endpoints' > out.requests.${name}.$DATABRICKS_BUNDLE_ENGINE.json + trace print_requests.py --keep '//vector-search/endpoints' > out.requests.${name}.json rm -f "$OUT_REQUESTS" } diff --git a/acceptance/bundle/resources/vector_search_endpoints/test.toml b/acceptance/bundle/resources/vector_search_endpoints/test.toml index ee9212ea9a9..0eba324f09d 100644 --- a/acceptance/bundle/resources/vector_search_endpoints/test.toml +++ b/acceptance/bundle/resources/vector_search_endpoints/test.toml @@ -1,7 +1,6 @@ Cloud = true # Vector Search endpoints are only available in direct mode (no Terraform provider) -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ "databricks.yml", diff --git a/acceptance/bundle/resources/vector_search_endpoints/update/budget_policy/out.requests.create.direct.json b/acceptance/bundle/resources/vector_search_endpoints/update/budget_policy/out.requests.create.json similarity index 100% rename from acceptance/bundle/resources/vector_search_endpoints/update/budget_policy/out.requests.create.direct.json rename to acceptance/bundle/resources/vector_search_endpoints/update/budget_policy/out.requests.create.json diff --git a/acceptance/bundle/resources/vector_search_endpoints/update/budget_policy/out.requests.update.direct.json b/acceptance/bundle/resources/vector_search_endpoints/update/budget_policy/out.requests.update.json similarity index 100% rename from acceptance/bundle/resources/vector_search_endpoints/update/budget_policy/out.requests.update.direct.json rename to acceptance/bundle/resources/vector_search_endpoints/update/budget_policy/out.requests.update.json diff --git a/acceptance/bundle/resources/vector_search_endpoints/update/budget_policy/out.test.toml b/acceptance/bundle/resources/vector_search_endpoints/update/budget_policy/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/vector_search_endpoints/update/budget_policy/out.test.toml +++ b/acceptance/bundle/resources/vector_search_endpoints/update/budget_policy/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/vector_search_endpoints/update/budget_policy/script b/acceptance/bundle/resources/vector_search_endpoints/update/budget_policy/script index f02a2bc6725..3b520933649 100644 --- a/acceptance/bundle/resources/vector_search_endpoints/update/budget_policy/script +++ b/acceptance/bundle/resources/vector_search_endpoints/update/budget_policy/script @@ -8,7 +8,7 @@ trap cleanup EXIT print_requests() { local name=$1 - trace print_requests.py --keep '//vector-search/endpoints' > out.requests.${name}.$DATABRICKS_BUNDLE_ENGINE.json + trace print_requests.py --keep '//vector-search/endpoints' > out.requests.${name}.json rm -f "$OUT_REQUESTS" } diff --git a/acceptance/bundle/resources/vector_search_endpoints/update/target_qps/out.requests.create.direct.json b/acceptance/bundle/resources/vector_search_endpoints/update/target_qps/out.requests.create.json similarity index 100% rename from acceptance/bundle/resources/vector_search_endpoints/update/target_qps/out.requests.create.direct.json rename to acceptance/bundle/resources/vector_search_endpoints/update/target_qps/out.requests.create.json diff --git a/acceptance/bundle/resources/vector_search_endpoints/update/target_qps/out.requests.update.direct.json b/acceptance/bundle/resources/vector_search_endpoints/update/target_qps/out.requests.update.json similarity index 100% rename from acceptance/bundle/resources/vector_search_endpoints/update/target_qps/out.requests.update.direct.json rename to acceptance/bundle/resources/vector_search_endpoints/update/target_qps/out.requests.update.json diff --git a/acceptance/bundle/resources/vector_search_endpoints/update/target_qps/out.test.toml b/acceptance/bundle/resources/vector_search_endpoints/update/target_qps/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/vector_search_endpoints/update/target_qps/out.test.toml +++ b/acceptance/bundle/resources/vector_search_endpoints/update/target_qps/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/vector_search_endpoints/update/target_qps/script b/acceptance/bundle/resources/vector_search_endpoints/update/target_qps/script index 07e6927c28a..155f56caae9 100644 --- a/acceptance/bundle/resources/vector_search_endpoints/update/target_qps/script +++ b/acceptance/bundle/resources/vector_search_endpoints/update/target_qps/script @@ -8,7 +8,7 @@ trap cleanup EXIT print_requests() { local name=$1 - trace print_requests.py '//vector-search/endpoints' '//permissions' > out.requests.${name}.$DATABRICKS_BUNDLE_ENGINE.json + trace print_requests.py '//vector-search/endpoints' '//permissions' > out.requests.${name}.json } title "Initial deployment" diff --git a/acceptance/bundle/resources/vector_search_indexes/basic/out.requests.direct.json b/acceptance/bundle/resources/vector_search_indexes/basic/out.requests.json similarity index 100% rename from acceptance/bundle/resources/vector_search_indexes/basic/out.requests.direct.json rename to acceptance/bundle/resources/vector_search_indexes/basic/out.requests.json diff --git a/acceptance/bundle/resources/vector_search_indexes/basic/out.test.toml b/acceptance/bundle/resources/vector_search_indexes/basic/out.test.toml index 9da8f3609b9..ea4733e76f6 100644 --- a/acceptance/bundle/resources/vector_search_indexes/basic/out.test.toml +++ b/acceptance/bundle/resources/vector_search_indexes/basic/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudSlow = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/vector_search_indexes/basic/script b/acceptance/bundle/resources/vector_search_indexes/basic/script index 7732c307e5e..3f86d9c3a1b 100644 --- a/acceptance/bundle/resources/vector_search_indexes/basic/script +++ b/acceptance/bundle/resources/vector_search_indexes/basic/script @@ -19,4 +19,4 @@ trace $CLI vector-search-indexes get-index "${index_name}" | jq '{name, endpoint trace $CLI bundle summary -trace print_requests.py //vector-search/indexes > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py //vector-search/indexes > out.requests.json diff --git a/acceptance/bundle/resources/vector_search_indexes/drift/deleted_remotely/out.test.toml b/acceptance/bundle/resources/vector_search_indexes/drift/deleted_remotely/out.test.toml index 77fd9b3b823..0eea50f8645 100644 --- a/acceptance/bundle/resources/vector_search_indexes/drift/deleted_remotely/out.test.toml +++ b/acceptance/bundle/resources/vector_search_indexes/drift/deleted_remotely/out.test.toml @@ -1,4 +1,3 @@ Cloud = false CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/vector_search_indexes/drift/orphaned_endpoint/out.test.toml b/acceptance/bundle/resources/vector_search_indexes/drift/orphaned_endpoint/out.test.toml index 77fd9b3b823..0eea50f8645 100644 --- a/acceptance/bundle/resources/vector_search_indexes/drift/orphaned_endpoint/out.test.toml +++ b/acceptance/bundle/resources/vector_search_indexes/drift/orphaned_endpoint/out.test.toml @@ -1,4 +1,3 @@ Cloud = false CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/vector_search_indexes/grants/select/out.requests.direct.json b/acceptance/bundle/resources/vector_search_indexes/grants/select/out.requests.json similarity index 100% rename from acceptance/bundle/resources/vector_search_indexes/grants/select/out.requests.direct.json rename to acceptance/bundle/resources/vector_search_indexes/grants/select/out.requests.json diff --git a/acceptance/bundle/resources/vector_search_indexes/grants/select/out.test.toml b/acceptance/bundle/resources/vector_search_indexes/grants/select/out.test.toml index 9da8f3609b9..ea4733e76f6 100644 --- a/acceptance/bundle/resources/vector_search_indexes/grants/select/out.test.toml +++ b/acceptance/bundle/resources/vector_search_indexes/grants/select/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudSlow = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/vector_search_indexes/grants/select/script b/acceptance/bundle/resources/vector_search_indexes/grants/select/script index 693d346208e..d6963772f80 100644 --- a/acceptance/bundle/resources/vector_search_indexes/grants/select/script +++ b/acceptance/bundle/resources/vector_search_indexes/grants/select/script @@ -16,4 +16,4 @@ trace $CLI bundle plan trace $CLI grants get table "${index_name}" | jq --sort-keys -trace print_requests.py '//vector-search/indexes' '//permissions' > out.requests.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py '//vector-search/indexes' '//permissions' > out.requests.json diff --git a/acceptance/bundle/resources/vector_search_indexes/recreate/embedding_dimension/out.requests.create.direct.json b/acceptance/bundle/resources/vector_search_indexes/recreate/embedding_dimension/out.requests.create.json similarity index 100% rename from acceptance/bundle/resources/vector_search_indexes/recreate/embedding_dimension/out.requests.create.direct.json rename to acceptance/bundle/resources/vector_search_indexes/recreate/embedding_dimension/out.requests.create.json diff --git a/acceptance/bundle/resources/vector_search_indexes/recreate/embedding_dimension/out.requests.recreate.direct.json b/acceptance/bundle/resources/vector_search_indexes/recreate/embedding_dimension/out.requests.recreate.json similarity index 100% rename from acceptance/bundle/resources/vector_search_indexes/recreate/embedding_dimension/out.requests.recreate.direct.json rename to acceptance/bundle/resources/vector_search_indexes/recreate/embedding_dimension/out.requests.recreate.json diff --git a/acceptance/bundle/resources/vector_search_indexes/recreate/embedding_dimension/out.test.toml b/acceptance/bundle/resources/vector_search_indexes/recreate/embedding_dimension/out.test.toml index f9f4880725d..8bfa768b35b 100644 --- a/acceptance/bundle/resources/vector_search_indexes/recreate/embedding_dimension/out.test.toml +++ b/acceptance/bundle/resources/vector_search_indexes/recreate/embedding_dimension/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/vector_search_indexes/recreate/embedding_dimension/script b/acceptance/bundle/resources/vector_search_indexes/recreate/embedding_dimension/script index 2f603f37141..0bb618e4895 100644 --- a/acceptance/bundle/resources/vector_search_indexes/recreate/embedding_dimension/script +++ b/acceptance/bundle/resources/vector_search_indexes/recreate/embedding_dimension/script @@ -14,7 +14,7 @@ print_requests() { # is the assertion that the wait actually fired. # --unique collapses the repeated identical poll GETs (one on the testserver, # many on a real workspace that provisions asynchronously) to a stable count. - trace print_requests.py --get --unique '//vector-search/indexes' > out.requests.${name}.$DATABRICKS_BUNDLE_ENGINE.json + trace print_requests.py --get --unique '//vector-search/indexes' > out.requests.${name}.json rm -f "$OUT_REQUESTS" } diff --git a/acceptance/bundle/resources/vector_search_indexes/recreate/pending_deletion/out.test.toml b/acceptance/bundle/resources/vector_search_indexes/recreate/pending_deletion/out.test.toml index 77fd9b3b823..0eea50f8645 100644 --- a/acceptance/bundle/resources/vector_search_indexes/recreate/pending_deletion/out.test.toml +++ b/acceptance/bundle/resources/vector_search_indexes/recreate/pending_deletion/out.test.toml @@ -1,4 +1,3 @@ Cloud = false CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/vector_search_indexes/recreate/with_endpoint/out.test.toml b/acceptance/bundle/resources/vector_search_indexes/recreate/with_endpoint/out.test.toml index 77fd9b3b823..0eea50f8645 100644 --- a/acceptance/bundle/resources/vector_search_indexes/recreate/with_endpoint/out.test.toml +++ b/acceptance/bundle/resources/vector_search_indexes/recreate/with_endpoint/out.test.toml @@ -1,4 +1,3 @@ Cloud = false CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/vector_search_indexes/schema_normalization/out.test.toml b/acceptance/bundle/resources/vector_search_indexes/schema_normalization/out.test.toml index 9da8f3609b9..ea4733e76f6 100644 --- a/acceptance/bundle/resources/vector_search_indexes/schema_normalization/out.test.toml +++ b/acceptance/bundle/resources/vector_search_indexes/schema_normalization/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudSlow = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/vector_search_indexes/test.toml b/acceptance/bundle/resources/vector_search_indexes/test.toml index cceb1ace6e4..a5ef9f285f7 100644 --- a/acceptance/bundle/resources/vector_search_indexes/test.toml +++ b/acceptance/bundle/resources/vector_search_indexes/test.toml @@ -4,7 +4,6 @@ Cloud = true CloudSlow = true # Vector Search indexes are only available in direct mode (no Terraform provider) -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ "databricks.yml", diff --git a/acceptance/bundle/resources/volumes/catalog-var-ref/out.test.toml b/acceptance/bundle/resources/volumes/catalog-var-ref/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/resources/volumes/catalog-var-ref/out.test.toml +++ b/acceptance/bundle/resources/volumes/catalog-var-ref/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/volumes/catalog-var-ref/test.toml b/acceptance/bundle/resources/volumes/catalog-var-ref/test.toml index bed5e07e897..262a6f41b15 100644 --- a/acceptance/bundle/resources/volumes/catalog-var-ref/test.toml +++ b/acceptance/bundle/resources/volumes/catalog-var-ref/test.toml @@ -1,4 +1,2 @@ Cloud = false RecordRequests = false - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/resources/volumes/change-comment/out.test.toml b/acceptance/bundle/resources/volumes/change-comment/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/volumes/change-comment/out.test.toml +++ b/acceptance/bundle/resources/volumes/change-comment/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/volumes/change-name/out.plan.direct.json b/acceptance/bundle/resources/volumes/change-name/out.plan.json similarity index 100% rename from acceptance/bundle/resources/volumes/change-name/out.plan.direct.json rename to acceptance/bundle/resources/volumes/change-name/out.plan.json diff --git a/acceptance/bundle/resources/volumes/change-name/out.plan.terraform.json b/acceptance/bundle/resources/volumes/change-name/out.plan.terraform.json deleted file mode 100644 index ac4d2b5561b..00000000000 --- a/acceptance/bundle/resources/volumes/change-name/out.plan.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.volumes.volume1": { - "action": "update" - } - } -} diff --git a/acceptance/bundle/resources/volumes/change-name/out.test.toml b/acceptance/bundle/resources/volumes/change-name/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/volumes/change-name/out.test.toml +++ b/acceptance/bundle/resources/volumes/change-name/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/volumes/change-name/script b/acceptance/bundle/resources/volumes/change-name/script index 55c6b990b8c..e2c2c5ea7ba 100644 --- a/acceptance/bundle/resources/volumes/change-name/script +++ b/acceptance/bundle/resources/volumes/change-name/script @@ -10,7 +10,7 @@ trace update_file.py databricks.yml myvolume mynewvolume trace $CLI bundle plan # terraform marks this as "update", direct marks this as "update_with_id" -$CLI bundle plan -o json | nostamp > out.plan.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan.json trace $CLI bundle deploy trace print_requests.py //unity diff --git a/acceptance/bundle/resources/volumes/change-schema-name/out.test.toml b/acceptance/bundle/resources/volumes/change-schema-name/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/volumes/change-schema-name/out.test.toml +++ b/acceptance/bundle/resources/volumes/change-schema-name/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/volumes/comment_out_of_band/out.test.toml b/acceptance/bundle/resources/volumes/comment_out_of_band/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/volumes/comment_out_of_band/out.test.toml +++ b/acceptance/bundle/resources/volumes/comment_out_of_band/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/volumes/comment_out_of_band/test.toml b/acceptance/bundle/resources/volumes/comment_out_of_band/test.toml index fa32d22b4e2..bec3515e848 100644 --- a/acceptance/bundle/resources/volumes/comment_out_of_band/test.toml +++ b/acceptance/bundle/resources/volumes/comment_out_of_band/test.toml @@ -1,7 +1,6 @@ Cloud = true # UpdateVolume payload construction is direct-engine-specific. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ ".databricks", diff --git a/acceptance/bundle/resources/volumes/comment_with_rename/out.test.toml b/acceptance/bundle/resources/volumes/comment_with_rename/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/resources/volumes/comment_with_rename/out.test.toml +++ b/acceptance/bundle/resources/volumes/comment_with_rename/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/volumes/comment_with_rename/test.toml b/acceptance/bundle/resources/volumes/comment_with_rename/test.toml index 27f8fb4be36..b7a6b3114ba 100644 --- a/acceptance/bundle/resources/volumes/comment_with_rename/test.toml +++ b/acceptance/bundle/resources/volumes/comment_with_rename/test.toml @@ -1,7 +1,6 @@ Cloud = true # UpdateVolume payload construction is direct-engine-specific. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ ".databricks", diff --git a/acceptance/bundle/resources/volumes/recreate/out.test.toml b/acceptance/bundle/resources/volumes/recreate/out.test.toml index aad5ccf5498..98ccab9aaeb 100644 --- a/acceptance/bundle/resources/volumes/recreate/out.test.toml +++ b/acceptance/bundle/resources/volumes/recreate/out.test.toml @@ -1,4 +1,3 @@ Cloud = true RunsOnDbr = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/volumes/remote-change-name/out.plan_create.direct.json b/acceptance/bundle/resources/volumes/remote-change-name/out.plan_create.json similarity index 100% rename from acceptance/bundle/resources/volumes/remote-change-name/out.plan_create.direct.json rename to acceptance/bundle/resources/volumes/remote-change-name/out.plan_create.json diff --git a/acceptance/bundle/resources/volumes/remote-change-name/out.plan_create.terraform.json b/acceptance/bundle/resources/volumes/remote-change-name/out.plan_create.terraform.json deleted file mode 100644 index cf56bd126cb..00000000000 --- a/acceptance/bundle/resources/volumes/remote-change-name/out.plan_create.terraform.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.volumes.foo": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/resources/volumes/remote-change-name/out.test.toml b/acceptance/bundle/resources/volumes/remote-change-name/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/volumes/remote-change-name/out.test.toml +++ b/acceptance/bundle/resources/volumes/remote-change-name/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/volumes/remote-change-name/script b/acceptance/bundle/resources/volumes/remote-change-name/script index 536ad6d50b8..a509529495e 100644 --- a/acceptance/bundle/resources/volumes/remote-change-name/script +++ b/acceptance/bundle/resources/volumes/remote-change-name/script @@ -1,4 +1,4 @@ -$CLI bundle plan -o json | nostamp > out.plan_create.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json | nostamp > out.plan_create.json trace $CLI bundle deploy trace $CLI volumes update mycatalog.myschema.myname --json '{"new_name": "my_new_name"}' diff --git a/acceptance/bundle/resources/volumes/remote-delete/out.test.toml b/acceptance/bundle/resources/volumes/remote-delete/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/volumes/remote-delete/out.test.toml +++ b/acceptance/bundle/resources/volumes/remote-delete/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/volumes/set-storage-location/out.deploy.terraform.txt b/acceptance/bundle/resources/volumes/set-storage-location/out.deploy.terraform.txt deleted file mode 100644 index 27230dcc397..00000000000 --- a/acceptance/bundle/resources/volumes/set-storage-location/out.deploy.terraform.txt +++ /dev/null @@ -1,14 +0,0 @@ - ->>> musterr [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/testbundle-[UNIQUE_NAME]/default/files... -Error: terraform apply: exit status 1 - -Error: cannot create volume: CreateVolume storage_location can not be provided. - - with databricks_volume.volume1, - on bundle.tf.json line 29, in resource.databricks_volume.volume1: - 29: } - - - -Files: 5 uploaded, 0 deleted diff --git a/acceptance/bundle/resources/volumes/set-storage-location/out.deploy.direct.txt b/acceptance/bundle/resources/volumes/set-storage-location/out.deploy.txt similarity index 100% rename from acceptance/bundle/resources/volumes/set-storage-location/out.deploy.direct.txt rename to acceptance/bundle/resources/volumes/set-storage-location/out.deploy.txt diff --git a/acceptance/bundle/resources/volumes/set-storage-location/out.test.toml b/acceptance/bundle/resources/volumes/set-storage-location/out.test.toml index b09d680c0e1..ee153e82621 100644 --- a/acceptance/bundle/resources/volumes/set-storage-location/out.test.toml +++ b/acceptance/bundle/resources/volumes/set-storage-location/out.test.toml @@ -1,5 +1,4 @@ Cloud = true CloudEnvs.azure = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/volumes/set-storage-location/script b/acceptance/bundle/resources/volumes/set-storage-location/script index 9c53155fff7..84c828500be 100644 --- a/acceptance/bundle/resources/volumes/set-storage-location/script +++ b/acceptance/bundle/resources/volumes/set-storage-location/script @@ -10,5 +10,5 @@ trace print_requests.py //unity trap cleanup EXIT -trace musterr $CLI bundle deploy &> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt +trace musterr $CLI bundle deploy &> out.deploy.txt trace print_requests.py //unity diff --git a/acceptance/bundle/resources/volumes/set-volume-path/out.test.toml b/acceptance/bundle/resources/volumes/set-volume-path/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/resources/volumes/set-volume-path/out.test.toml +++ b/acceptance/bundle/resources/volumes/set-volume-path/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/volumes/uppercase-name/out.deploy.terraform.txt b/acceptance/bundle/resources/volumes/uppercase-name/out.deploy.terraform.txt deleted file mode 100644 index 175ce4eeb33..00000000000 --- a/acceptance/bundle/resources/volumes/uppercase-name/out.deploy.terraform.txt +++ /dev/null @@ -1,26 +0,0 @@ -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle-[UNIQUE_NAME]/default/files... -Error: terraform apply: exit status 1 - -Error: Provider produced inconsistent final plan - -When expanding the plan for databricks_volume.vol1 to include new values -learned so far during apply, provider -"registry.terraform.io/databricks/databricks" produced an invalid new value -for .schema_name: was cty.StringVal("MySCHEMA_[UNIQUE_NAME]"), -but now cty.StringVal("myschema_[UNIQUE_NAME]"). - -This is a bug in the provider, which should be reported in the provider's own -issue tracker. - - -Files: 0 uploaded, 0 deleted - -Exit code: 1 -{ - "method": "POST", - "path": "/api/2.1/unity-catalog/schemas", - "body": { - "catalog_name": "main", - "name": "MySCHEMA_[UNIQUE_NAME]" - } -} diff --git a/acceptance/bundle/resources/volumes/uppercase-name/out.deploy.direct.txt b/acceptance/bundle/resources/volumes/uppercase-name/out.deploy.txt similarity index 100% rename from acceptance/bundle/resources/volumes/uppercase-name/out.deploy.direct.txt rename to acceptance/bundle/resources/volumes/uppercase-name/out.deploy.txt diff --git a/acceptance/bundle/resources/volumes/uppercase-name/out.test.toml b/acceptance/bundle/resources/volumes/uppercase-name/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/resources/volumes/uppercase-name/out.test.toml +++ b/acceptance/bundle/resources/volumes/uppercase-name/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/resources/volumes/uppercase-name/script b/acceptance/bundle/resources/volumes/uppercase-name/script index d40e5b42af4..37663bb0147 100644 --- a/acceptance/bundle/resources/volumes/uppercase-name/script +++ b/acceptance/bundle/resources/volumes/uppercase-name/script @@ -7,27 +7,25 @@ cleanup() { } trap cleanup EXIT -errcode $CLI bundle deploy &> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt -print_requests.py //unity-catalog >> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt +errcode $CLI bundle deploy &> out.deploy.txt +print_requests.py //unity-catalog >> out.deploy.txt -if [ "$DATABRICKS_BUNDLE_ENGINE" = "direct" ]; then - echo "=== Bundle summary shows lowercase IDs after UC normalizes names" >> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt - $CLI bundle summary -o json \ - | jq '{schema_id: .resources.schemas.schema1.id, volume_id: .resources.volumes.vol1.id}' \ - >> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt +echo "=== Bundle summary shows lowercase IDs after UC normalizes names" >> out.deploy.txt +$CLI bundle summary -o json \ + | jq '{schema_id: .resources.schemas.schema1.id, volume_id: .resources.volumes.vol1.id}' \ + >> out.deploy.txt - echo "=== Plan on no-op redeploy: mixed-case names are skipped, not recreated" >> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt - # UC injects managed-default properties on the schema via an async system write - # seconds after create, so the schema's `properties` change is present - # nondeterministically. Prune it with normalize_uc_payload.py before reshaping so - # the golden is stable. See #6027 and #6040. - $CLI bundle plan -o json | nostamp \ - | normalize_uc_payload.py \ - | jq '.plan | to_entries | map({resource: .key, changes: (.value.changes // {} | map_values({action, reason}))})' \ - >> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt +echo "=== Plan on no-op redeploy: mixed-case names are skipped, not recreated" >> out.deploy.txt +# UC injects managed-default properties on the schema via an async system write +# seconds after create, so the schema's `properties` change is present +# nondeterministically. Prune it with normalize_uc_payload.py before reshaping so +# the golden is stable. See #6027 and #6040. +$CLI bundle plan -o json | nostamp \ + | normalize_uc_payload.py \ + | jq '.plan | to_entries | map({resource: .key, changes: (.value.changes // {} | map_values({action, reason}))})' \ + >> out.deploy.txt - echo "=== Redeploy without changes - should be a no-op" >> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt - # &>> requires bash 4+; macOS CI runs the stock bash 3.2, so use >> ... 2>&1. - errcode $CLI bundle deploy >> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt 2>&1 - print_requests.py //unity-catalog >> out.deploy.$DATABRICKS_BUNDLE_ENGINE.txt -fi +echo "=== Redeploy without changes - should be a no-op" >> out.deploy.txt +# &>> requires bash 4+; macOS CI runs the stock bash 3.2, so use >> ... 2>&1. +errcode $CLI bundle deploy >> out.deploy.txt 2>&1 +print_requests.py //unity-catalog >> out.deploy.txt diff --git a/acceptance/bundle/resources/volumes/uppercase-name/test.toml b/acceptance/bundle/resources/volumes/uppercase-name/test.toml index 75248d67c43..a26bade48d0 100644 --- a/acceptance/bundle/resources/volumes/uppercase-name/test.toml +++ b/acceptance/bundle/resources/volumes/uppercase-name/test.toml @@ -4,7 +4,3 @@ Ignore = [ ".databricks", "databricks.yml", ] - -# TF provider fails with "inconsistent final plan" when schema_name contains -# uppercase letters that UC normalizes to lowercase; exclude from cloud runs. -EnvMatrixExclude.no_terraform_on_cloud = ["CONFIG_Cloud=true", "DATABRICKS_BUNDLE_ENGINE=terraform"] diff --git a/acceptance/bundle/root/env-not-a-directory/out.test.toml b/acceptance/bundle/root/env-not-a-directory/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/root/env-not-a-directory/out.test.toml +++ b/acceptance/bundle/root/env-not-a-directory/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/root/env-not-found/out.test.toml b/acceptance/bundle/root/env-not-found/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/root/env-not-found/out.test.toml +++ b/acceptance/bundle/root/env-not-found/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/root/not-found/out.test.toml b/acceptance/bundle/root/not-found/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/root/not-found/out.test.toml +++ b/acceptance/bundle/root/not-found/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/root/real-empty-dir/out.test.toml b/acceptance/bundle/root/real-empty-dir/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/root/real-empty-dir/out.test.toml +++ b/acceptance/bundle/root/real-empty-dir/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/root/test.toml b/acceptance/bundle/root/test.toml index a563faa0c79..35b8cfe69d9 100644 --- a/acceptance/bundle/root/test.toml +++ b/acceptance/bundle/root/test.toml @@ -2,4 +2,3 @@ Cloud = false # These errors originate in bundle/root.go before any engine is selected, # so they are identical for both deployment engines. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/run/app-with-job/out.test.toml b/acceptance/bundle/run/app-with-job/out.test.toml index 2fbe66e8d02..8bfa768b35b 100644 --- a/acceptance/bundle/run/app-with-job/out.test.toml +++ b/acceptance/bundle/run/app-with-job/out.test.toml @@ -1,4 +1,3 @@ Cloud = true CloudSlow = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/basic/out.test.toml b/acceptance/bundle/run/basic/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/basic/out.test.toml +++ b/acceptance/bundle/run/basic/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/diagnostics/out.test.toml b/acceptance/bundle/run/diagnostics/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/diagnostics/out.test.toml +++ b/acceptance/bundle/run/diagnostics/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/inline-script/basic/out.test.toml b/acceptance/bundle/run/inline-script/basic/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/inline-script/basic/out.test.toml +++ b/acceptance/bundle/run/inline-script/basic/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/inline-script/cwd/out.test.toml b/acceptance/bundle/run/inline-script/cwd/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/inline-script/cwd/out.test.toml +++ b/acceptance/bundle/run/inline-script/cwd/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/inline-script/databricks-cli/profile-is-passed/from_flag/out.test.toml b/acceptance/bundle/run/inline-script/databricks-cli/profile-is-passed/from_flag/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/inline-script/databricks-cli/profile-is-passed/from_flag/out.test.toml +++ b/acceptance/bundle/run/inline-script/databricks-cli/profile-is-passed/from_flag/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/inline-script/databricks-cli/target-is-passed/default/out.test.toml b/acceptance/bundle/run/inline-script/databricks-cli/target-is-passed/default/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/inline-script/databricks-cli/target-is-passed/default/out.test.toml +++ b/acceptance/bundle/run/inline-script/databricks-cli/target-is-passed/default/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/inline-script/databricks-cli/target-is-passed/from_flag/out.test.toml b/acceptance/bundle/run/inline-script/databricks-cli/target-is-passed/from_flag/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/inline-script/databricks-cli/target-is-passed/from_flag/out.test.toml +++ b/acceptance/bundle/run/inline-script/databricks-cli/target-is-passed/from_flag/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/inline-script/no-auth/out.test.toml b/acceptance/bundle/run/inline-script/no-auth/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/inline-script/no-auth/out.test.toml +++ b/acceptance/bundle/run/inline-script/no-auth/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/inline-script/no-bundle/out.test.toml b/acceptance/bundle/run/inline-script/no-bundle/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/inline-script/no-bundle/out.test.toml +++ b/acceptance/bundle/run/inline-script/no-bundle/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/inline-script/no-separator/out.test.toml b/acceptance/bundle/run/inline-script/no-separator/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/inline-script/no-separator/out.test.toml +++ b/acceptance/bundle/run/inline-script/no-separator/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/jobs/partial_run/out.test.toml b/acceptance/bundle/run/jobs/partial_run/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/jobs/partial_run/out.test.toml +++ b/acceptance/bundle/run/jobs/partial_run/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/no-state/out.test.toml b/acceptance/bundle/run/no-state/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/no-state/out.test.toml +++ b/acceptance/bundle/run/no-state/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/refresh-flags/out.test.toml b/acceptance/bundle/run/refresh-flags/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/refresh-flags/out.test.toml +++ b/acceptance/bundle/run/refresh-flags/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/scripts/basic/out.test.toml b/acceptance/bundle/run/scripts/basic/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/scripts/basic/out.test.toml +++ b/acceptance/bundle/run/scripts/basic/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/scripts/cwd/out.test.toml b/acceptance/bundle/run/scripts/cwd/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/scripts/cwd/out.test.toml +++ b/acceptance/bundle/run/scripts/cwd/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/scripts/databricks-cli/profile-is-passed/from_flag/out.test.toml b/acceptance/bundle/run/scripts/databricks-cli/profile-is-passed/from_flag/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/scripts/databricks-cli/profile-is-passed/from_flag/out.test.toml +++ b/acceptance/bundle/run/scripts/databricks-cli/profile-is-passed/from_flag/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/scripts/databricks-cli/target-is-passed/default/out.test.toml b/acceptance/bundle/run/scripts/databricks-cli/target-is-passed/default/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/scripts/databricks-cli/target-is-passed/default/out.test.toml +++ b/acceptance/bundle/run/scripts/databricks-cli/target-is-passed/default/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/scripts/databricks-cli/target-is-passed/from_flag/out.test.toml b/acceptance/bundle/run/scripts/databricks-cli/target-is-passed/from_flag/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/scripts/databricks-cli/target-is-passed/from_flag/out.test.toml +++ b/acceptance/bundle/run/scripts/databricks-cli/target-is-passed/from_flag/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/scripts/env-bad-prefix/out.test.toml b/acceptance/bundle/run/scripts/env-bad-prefix/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/scripts/env-bad-prefix/out.test.toml +++ b/acceptance/bundle/run/scripts/env-bad-prefix/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/scripts/env-bad-prefix/test.toml b/acceptance/bundle/run/scripts/env-bad-prefix/test.toml index dfbe1eeee99..18b1a88417e 100644 --- a/acceptance/bundle/run/scripts/env-bad-prefix/test.toml +++ b/acceptance/bundle/run/scripts/env-bad-prefix/test.toml @@ -1,3 +1 @@ Cloud = false - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/bundle/run/scripts/env-precedence/out.test.toml b/acceptance/bundle/run/scripts/env-precedence/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/scripts/env-precedence/out.test.toml +++ b/acceptance/bundle/run/scripts/env-precedence/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/scripts/env-precedence/test.toml b/acceptance/bundle/run/scripts/env-precedence/test.toml index dfbe1eeee99..18b1a88417e 100644 --- a/acceptance/bundle/run/scripts/env-precedence/test.toml +++ b/acceptance/bundle/run/scripts/env-precedence/test.toml @@ -1,3 +1 @@ Cloud = false - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/bundle/run/scripts/env-section/out.test.toml b/acceptance/bundle/run/scripts/env-section/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/scripts/env-section/out.test.toml +++ b/acceptance/bundle/run/scripts/env-section/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/scripts/env-section/test.toml b/acceptance/bundle/run/scripts/env-section/test.toml index dfbe1eeee99..18b1a88417e 100644 --- a/acceptance/bundle/run/scripts/env-section/test.toml +++ b/acceptance/bundle/run/scripts/env-section/test.toml @@ -1,3 +1 @@ Cloud = false - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/bundle/run/scripts/exit_code/out.test.toml b/acceptance/bundle/run/scripts/exit_code/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/scripts/exit_code/out.test.toml +++ b/acceptance/bundle/run/scripts/exit_code/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/scripts/io/out.test.toml b/acceptance/bundle/run/scripts/io/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/scripts/io/out.test.toml +++ b/acceptance/bundle/run/scripts/io/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/scripts/no-auth/out.test.toml b/acceptance/bundle/run/scripts/no-auth/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/scripts/no-auth/out.test.toml +++ b/acceptance/bundle/run/scripts/no-auth/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/scripts/no-interpolation/out.test.toml b/acceptance/bundle/run/scripts/no-interpolation/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/scripts/no-interpolation/out.test.toml +++ b/acceptance/bundle/run/scripts/no-interpolation/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/scripts/no_content/out.test.toml b/acceptance/bundle/run/scripts/no_content/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/scripts/no_content/out.test.toml +++ b/acceptance/bundle/run/scripts/no_content/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/scripts/shell/envvar/out.test.toml b/acceptance/bundle/run/scripts/shell/envvar/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/scripts/shell/envvar/out.test.toml +++ b/acceptance/bundle/run/scripts/shell/envvar/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/scripts/shell/math/out.test.toml b/acceptance/bundle/run/scripts/shell/math/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/scripts/shell/math/out.test.toml +++ b/acceptance/bundle/run/scripts/shell/math/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/scripts/unique_keys/duplicate_resource_and_script_name_root/out.test.toml b/acceptance/bundle/run/scripts/unique_keys/duplicate_resource_and_script_name_root/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/scripts/unique_keys/duplicate_resource_and_script_name_root/out.test.toml +++ b/acceptance/bundle/run/scripts/unique_keys/duplicate_resource_and_script_name_root/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/scripts/unique_keys/duplicate_resource_and_script_subconfigurations/out.test.toml b/acceptance/bundle/run/scripts/unique_keys/duplicate_resource_and_script_subconfigurations/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/scripts/unique_keys/duplicate_resource_and_script_subconfigurations/out.test.toml +++ b/acceptance/bundle/run/scripts/unique_keys/duplicate_resource_and_script_subconfigurations/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/scripts/unique_keys/duplicate_script_names_in_subconfiguration/out.test.toml b/acceptance/bundle/run/scripts/unique_keys/duplicate_script_names_in_subconfiguration/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/scripts/unique_keys/duplicate_script_names_in_subconfiguration/out.test.toml +++ b/acceptance/bundle/run/scripts/unique_keys/duplicate_script_names_in_subconfiguration/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run/state-wiped/out.test.toml b/acceptance/bundle/run/state-wiped/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run/state-wiped/out.test.toml +++ b/acceptance/bundle/run/state-wiped/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run_as/allowed/regular_user/out.test.toml b/acceptance/bundle/run_as/allowed/regular_user/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run_as/allowed/regular_user/out.test.toml +++ b/acceptance/bundle/run_as/allowed/regular_user/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run_as/allowed/service_principal/out.test.toml b/acceptance/bundle/run_as/allowed/service_principal/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run_as/allowed/service_principal/out.test.toml +++ b/acceptance/bundle/run_as/allowed/service_principal/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run_as/dashboard_embed/out.test.toml b/acceptance/bundle/run_as/dashboard_embed/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run_as/dashboard_embed/out.test.toml +++ b/acceptance/bundle/run_as/dashboard_embed/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run_as/empty_override/out.test.toml b/acceptance/bundle/run_as/empty_override/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run_as/empty_override/out.test.toml +++ b/acceptance/bundle/run_as/empty_override/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run_as/empty_run_as/out.test.toml b/acceptance/bundle/run_as/empty_run_as/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run_as/empty_run_as/out.test.toml +++ b/acceptance/bundle/run_as/empty_run_as/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run_as/empty_run_as_dict/out.test.toml b/acceptance/bundle/run_as/empty_run_as_dict/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run_as/empty_run_as_dict/out.test.toml +++ b/acceptance/bundle/run_as/empty_run_as_dict/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run_as/empty_sp/out.test.toml b/acceptance/bundle/run_as/empty_sp/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run_as/empty_sp/out.test.toml +++ b/acceptance/bundle/run_as/empty_sp/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run_as/empty_user/out.test.toml b/acceptance/bundle/run_as/empty_user/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run_as/empty_user/out.test.toml +++ b/acceptance/bundle/run_as/empty_user/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run_as/empty_user_and_sp/out.test.toml b/acceptance/bundle/run_as/empty_user_and_sp/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run_as/empty_user_and_sp/out.test.toml +++ b/acceptance/bundle/run_as/empty_user_and_sp/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run_as/invalid_both_sp_and_user/out.test.toml b/acceptance/bundle/run_as/invalid_both_sp_and_user/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run_as/invalid_both_sp_and_user/out.test.toml +++ b/acceptance/bundle/run_as/invalid_both_sp_and_user/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run_as/job_default/out.test.toml b/acceptance/bundle/run_as/job_default/out.test.toml index ae5c7bd798f..0f167effef1 100644 --- a/acceptance/bundle/run_as/job_default/out.test.toml +++ b/acceptance/bundle/run_as/job_default/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run_as/job_default/test.toml b/acceptance/bundle/run_as/job_default/test.toml index d0a778db5f8..9aaa963719f 100644 --- a/acceptance/bundle/run_as/job_default/test.toml +++ b/acceptance/bundle/run_as/job_default/test.toml @@ -3,5 +3,3 @@ Ignore = [".databricks/.gitignore"] Cloud = true RecordRequests = true - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/run_as/model_serving_different/out.test.toml b/acceptance/bundle/run_as/model_serving_different/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run_as/model_serving_different/out.test.toml +++ b/acceptance/bundle/run_as/model_serving_different/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run_as/model_serving_matching/out.test.toml b/acceptance/bundle/run_as/model_serving_matching/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run_as/model_serving_matching/out.test.toml +++ b/acceptance/bundle/run_as/model_serving_matching/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run_as/out.test.toml b/acceptance/bundle/run_as/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run_as/out.test.toml +++ b/acceptance/bundle/run_as/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run_as/pipelines/_script b/acceptance/bundle/run_as/pipelines/_script index 5f3d5f1cc8e..48345141741 100644 --- a/acceptance/bundle/run_as/pipelines/_script +++ b/acceptance/bundle/run_as/pipelines/_script @@ -15,7 +15,7 @@ for target in "${targets[@]}"; do trace $CLI bundle plan -t $target # Debug plan - $CLI bundle plan -o json -t $target | nostamp.py > out.plan_$target.$DATABRICKS_BUNDLE_ENGINE.json + $CLI bundle plan -o json -t $target | nostamp.py > out.plan_$target.json # Deploy rm -f "$OUT_REQUESTS" diff --git a/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_service_principal_name.direct.json b/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_service_principal_name.json similarity index 100% rename from acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_service_principal_name.direct.json rename to acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_service_principal_name.json diff --git a/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_service_principal_name.terraform.json b/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_service_principal_name.terraform.json deleted file mode 100644 index a517cb62716..00000000000 --- a/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_service_principal_name.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.nyc_taxi_pipeline": { - "action": "create" - }, - "resources.pipelines.nyc_taxi_pipeline.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_service_principal_name_different.direct.json b/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_service_principal_name_different.json similarity index 100% rename from acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_service_principal_name_different.direct.json rename to acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_service_principal_name_different.json diff --git a/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_service_principal_name_different.terraform.json b/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_service_principal_name_different.terraform.json deleted file mode 100644 index a517cb62716..00000000000 --- a/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_service_principal_name_different.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.nyc_taxi_pipeline": { - "action": "create" - }, - "resources.pipelines.nyc_taxi_pipeline.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_user_name.direct.json b/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_user_name.json similarity index 100% rename from acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_user_name.direct.json rename to acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_user_name.json diff --git a/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_user_name.terraform.json b/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_user_name.terraform.json deleted file mode 100644 index a517cb62716..00000000000 --- a/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_user_name.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.nyc_taxi_pipeline": { - "action": "create" - }, - "resources.pipelines.nyc_taxi_pipeline.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_user_name_different.direct.json b/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_user_name_different.json similarity index 100% rename from acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_user_name_different.direct.json rename to acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_user_name_different.json diff --git a/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_user_name_different.terraform.json b/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_user_name_different.terraform.json deleted file mode 100644 index a517cb62716..00000000000 --- a/acceptance/bundle/run_as/pipelines/regular_user/out.plan_t_user_name_different.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.nyc_taxi_pipeline": { - "action": "create" - }, - "resources.pipelines.nyc_taxi_pipeline.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/run_as/pipelines/regular_user/out.test.toml b/acceptance/bundle/run_as/pipelines/regular_user/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run_as/pipelines/regular_user/out.test.toml +++ b/acceptance/bundle/run_as/pipelines/regular_user/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_service_principal_name.direct.json b/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_service_principal_name.json similarity index 100% rename from acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_service_principal_name.direct.json rename to acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_service_principal_name.json diff --git a/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_service_principal_name.terraform.json b/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_service_principal_name.terraform.json deleted file mode 100644 index a517cb62716..00000000000 --- a/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_service_principal_name.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.nyc_taxi_pipeline": { - "action": "create" - }, - "resources.pipelines.nyc_taxi_pipeline.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_service_principal_name_different.direct.json b/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_service_principal_name_different.json similarity index 100% rename from acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_service_principal_name_different.direct.json rename to acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_service_principal_name_different.json diff --git a/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_service_principal_name_different.terraform.json b/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_service_principal_name_different.terraform.json deleted file mode 100644 index a517cb62716..00000000000 --- a/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_service_principal_name_different.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.nyc_taxi_pipeline": { - "action": "create" - }, - "resources.pipelines.nyc_taxi_pipeline.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_user_name.direct.json b/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_user_name.json similarity index 100% rename from acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_user_name.direct.json rename to acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_user_name.json diff --git a/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_user_name.terraform.json b/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_user_name.terraform.json deleted file mode 100644 index a517cb62716..00000000000 --- a/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_user_name.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.nyc_taxi_pipeline": { - "action": "create" - }, - "resources.pipelines.nyc_taxi_pipeline.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_user_name_different.direct.json b/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_user_name_different.json similarity index 100% rename from acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_user_name_different.direct.json rename to acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_user_name_different.json diff --git a/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_user_name_different.terraform.json b/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_user_name_different.terraform.json deleted file mode 100644 index a517cb62716..00000000000 --- a/acceptance/bundle/run_as/pipelines/service_principal/out.plan_t_user_name_different.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.pipelines.nyc_taxi_pipeline": { - "action": "create" - }, - "resources.pipelines.nyc_taxi_pipeline.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/run_as/pipelines/service_principal/out.test.toml b/acceptance/bundle/run_as/pipelines/service_principal/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run_as/pipelines/service_principal/out.test.toml +++ b/acceptance/bundle/run_as/pipelines/service_principal/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/run_as/pipelines_legacy/out.test.toml b/acceptance/bundle/run_as/pipelines_legacy/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/run_as/pipelines_legacy/out.test.toml +++ b/acceptance/bundle/run_as/pipelines_legacy/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/scripts/no-trailing-newline/out.test.toml b/acceptance/bundle/scripts/no-trailing-newline/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/scripts/no-trailing-newline/out.test.toml +++ b/acceptance/bundle/scripts/no-trailing-newline/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/scripts/out.test.toml b/acceptance/bundle/scripts/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/scripts/out.test.toml +++ b/acceptance/bundle/scripts/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/scripts/restricted-execution/out.test.toml b/acceptance/bundle/scripts/restricted-execution/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/scripts/restricted-execution/out.test.toml +++ b/acceptance/bundle/scripts/restricted-execution/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/select/ambiguous/out.test.toml b/acceptance/bundle/select/ambiguous/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/select/ambiguous/out.test.toml +++ b/acceptance/bundle/select/ambiguous/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/select/basic/out.test.toml b/acceptance/bundle/select/basic/out.test.toml index a420f50c421..7a62f726f25 100644 --- a/acceptance/bundle/select/basic/out.test.toml +++ b/acceptance/bundle/select/basic/out.test.toml @@ -1,4 +1,3 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/select/basic/test.toml b/acceptance/bundle/select/basic/test.toml index fe41d5f871a..36071e73476 100644 --- a/acceptance/bundle/select/basic/test.toml +++ b/acceptance/bundle/select/basic/test.toml @@ -2,7 +2,6 @@ Cloud = true RecordRequests = true # --select is only supported by the direct engine, so this happy-path test runs on # direct only (the rejection on terraform is covered by bundle/select/rejected). -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # Also run a variant that deploys a serialized (already filtered) plan via --plan. EnvMatrix.READPLAN = ["", "1"] # databricks.yml and the serialized plans are generated at runtime; the plan JSON diff --git a/acceptance/bundle/select/grants_permissions/out.test.toml b/acceptance/bundle/select/grants_permissions/out.test.toml index dd03baaabb6..f7fafbcc731 100644 --- a/acceptance/bundle/select/grants_permissions/out.test.toml +++ b/acceptance/bundle/select/grants_permissions/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/select/grants_permissions/test.toml b/acceptance/bundle/select/grants_permissions/test.toml index 4b4735b927d..a6919333d49 100644 --- a/acceptance/bundle/select/grants_permissions/test.toml +++ b/acceptance/bundle/select/grants_permissions/test.toml @@ -8,6 +8,5 @@ # own path resolution -- see the env -u workaround in acceptance/script.prepare.) Cloud = false RecordRequests = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.READPLAN = ["", "1"] Ignore = [".databricks", ".gitignore", "databricks.yml", "plan-job.json", "plan-schema.json"] diff --git a/acceptance/bundle/select/missing/out.test.toml b/acceptance/bundle/select/missing/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/select/missing/out.test.toml +++ b/acceptance/bundle/select/missing/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/select/plan_file_survives_not_selected/out.test.toml b/acceptance/bundle/select/plan_file_survives_not_selected/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/select/plan_file_survives_not_selected/out.test.toml +++ b/acceptance/bundle/select/plan_file_survives_not_selected/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/select/plan_file_survives_not_selected/test.toml b/acceptance/bundle/select/plan_file_survives_not_selected/test.toml index bd3bae37d8f..5fff653db11 100644 --- a/acceptance/bundle/select/plan_file_survives_not_selected/test.toml +++ b/acceptance/bundle/select/plan_file_survives_not_selected/test.toml @@ -1,3 +1,2 @@ # --select is only supported by the direct engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [".databricks", ".gitignore", "databricks.yml", "plan.json"] diff --git a/acceptance/bundle/select/rejected/databricks.yml b/acceptance/bundle/select/rejected/databricks.yml deleted file mode 100644 index 2c5ff850e63..00000000000 --- a/acceptance/bundle/select/rejected/databricks.yml +++ /dev/null @@ -1,7 +0,0 @@ -bundle: - name: select-rejected - -resources: - jobs: - my_job: - name: my-job diff --git a/acceptance/bundle/select/rejected/out.test.toml b/acceptance/bundle/select/rejected/out.test.toml deleted file mode 100644 index 5d0f3e4aac2..00000000000 --- a/acceptance/bundle/select/rejected/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] -EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/select/rejected/output.txt b/acceptance/bundle/select/rejected/output.txt deleted file mode 100644 index 9f4417461f6..00000000000 --- a/acceptance/bundle/select/rejected/output.txt +++ /dev/null @@ -1,12 +0,0 @@ - ->>> [CLI] bundle plan --select my_job -Error: --select is only supported with the direct engine. See https://docs.databricks.com/aws/en/dev-tools/bundles/direct - - -Exit code: 1 - ->>> [CLI] bundle deploy --select my_job -Error: --select is only supported with the direct engine. See https://docs.databricks.com/aws/en/dev-tools/bundles/direct - - -Exit code: 1 diff --git a/acceptance/bundle/select/rejected/script b/acceptance/bundle/select/rejected/script deleted file mode 100644 index 8e5acc82b87..00000000000 --- a/acceptance/bundle/select/rejected/script +++ /dev/null @@ -1,3 +0,0 @@ -# --select is only supported by the direct engine; both plan and deploy reject it. -errcode trace $CLI bundle plan --select my_job -errcode trace $CLI bundle deploy --select my_job diff --git a/acceptance/bundle/select/rejected/test.toml b/acceptance/bundle/select/rejected/test.toml deleted file mode 100644 index 7d8b7840fab..00000000000 --- a/acceptance/bundle/select/rejected/test.toml +++ /dev/null @@ -1,2 +0,0 @@ -# --select is rejected on the terraform engine with an actionable error. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] diff --git a/acceptance/bundle/state/bad_env/out.test.toml b/acceptance/bundle/state/bad_env/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/state/bad_env/out.test.toml +++ b/acceptance/bundle/state/bad_env/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/state/bad_env/output.txt b/acceptance/bundle/state/bad_env/output.txt index 5a88b62f95e..fea87090ecb 100644 --- a/acceptance/bundle/state/bad_env/output.txt +++ b/acceptance/bundle/state/bad_env/output.txt @@ -1,12 +1,12 @@ >>> musterr [CLI] bundle plan -Error: unexpected setting for DATABRICKS_BUNDLE_ENGINE="abc" (expected 'terraform' or 'direct') +Error: unexpected setting for DATABRICKS_BUNDLE_ENGINE="abc" (expected 'direct') >>> musterr [CLI] bundle deploy -Error: unexpected setting for DATABRICKS_BUNDLE_ENGINE="abc" (expected 'terraform' or 'direct') +Error: unexpected setting for DATABRICKS_BUNDLE_ENGINE="abc" (expected 'direct') >>> musterr [CLI] bundle summary -Error: unexpected setting for DATABRICKS_BUNDLE_ENGINE="abc" (expected 'terraform' or 'direct') +Error: unexpected setting for DATABRICKS_BUNDLE_ENGINE="abc" (expected 'direct') >>> musterr [CLI] bundle destroy --auto-approve -Error: unexpected setting for DATABRICKS_BUNDLE_ENGINE="abc" (expected 'terraform' or 'direct') +Error: unexpected setting for DATABRICKS_BUNDLE_ENGINE="abc" (expected 'direct') diff --git a/acceptance/bundle/state/bad_json_local/out.test.toml b/acceptance/bundle/state/bad_json_local/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/state/bad_json_local/out.test.toml +++ b/acceptance/bundle/state/bad_json_local/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/state/basic/out.test.toml b/acceptance/bundle/state/basic/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/state/basic/out.test.toml +++ b/acceptance/bundle/state/basic/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/state/engine_default/out.test.toml b/acceptance/bundle/state/engine_default/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/state/engine_default/out.test.toml +++ b/acceptance/bundle/state/engine_default/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/state/engine_default/test.toml b/acceptance/bundle/state/engine_default/test.toml index 4f88575f9d1..8c48ebc7c1c 100644 --- a/acceptance/bundle/state/engine_default/test.toml +++ b/acceptance/bundle/state/engine_default/test.toml @@ -5,4 +5,3 @@ Ignore = [".databricks"] # Run once (not per-engine); the script unsets DATABRICKS_BUNDLE_ENGINE to # exercise the default. "direct" (rather than []) keeps the test in the # engine-filtered CI runs. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/state/engine_mismatch/out.test.toml b/acceptance/bundle/state/engine_mismatch/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/state/engine_mismatch/out.test.toml +++ b/acceptance/bundle/state/engine_mismatch/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/state/feature_flags/accept_new/out.test.toml b/acceptance/bundle/state/feature_flags/accept_new/out.test.toml index 23f30ff55f8..a8bb70d979c 100644 --- a/acceptance/bundle/state/feature_flags/accept_new/out.test.toml +++ b/acceptance/bundle/state/feature_flags/accept_new/out.test.toml @@ -1,5 +1,4 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] EnvMatrix.STATE_FILE = [ "resources.v2.json", diff --git a/acceptance/bundle/state/feature_flags/accept_old/out.test.toml b/acceptance/bundle/state/feature_flags/accept_old/out.test.toml index 104d04f213a..262e49f0549 100644 --- a/acceptance/bundle/state/feature_flags/accept_old/out.test.toml +++ b/acceptance/bundle/state/feature_flags/accept_old/out.test.toml @@ -1,5 +1,4 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] EnvMatrix.STATE_FILE = [ "resources.v2.json", diff --git a/acceptance/bundle/state/feature_flags/reject_new/out.test.toml b/acceptance/bundle/state/feature_flags/reject_new/out.test.toml index 5684d9e1005..61185395437 100644 --- a/acceptance/bundle/state/feature_flags/reject_new/out.test.toml +++ b/acceptance/bundle/state/feature_flags/reject_new/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] EnvMatrix.STATE_FILE = ["resources.v2.future_feature.json", "resources.v3.future_feature.json"] diff --git a/acceptance/bundle/state/feature_flags/reject_old/out.test.toml b/acceptance/bundle/state/feature_flags/reject_old/out.test.toml index e47e156b114..45e38cd3073 100644 --- a/acceptance/bundle/state/feature_flags/reject_old/out.test.toml +++ b/acceptance/bundle/state/feature_flags/reject_old/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] EnvMatrix.FEATURE = ["future_feature", "deployment_history"] diff --git a/acceptance/bundle/state/feature_flags/test.toml b/acceptance/bundle/state/feature_flags/test.toml index e355ab2feb2..a6daca5de91 100644 --- a/acceptance/bundle/state/feature_flags/test.toml +++ b/acceptance/bundle/state/feature_flags/test.toml @@ -1,6 +1,5 @@ Ignore = [".databricks"] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] # New-CLI tests use the source build; pin them to this week's release (v1.17.0) once published. diff --git a/acceptance/bundle/state/force_pull_commands/out.test.toml b/acceptance/bundle/state/force_pull_commands/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/state/force_pull_commands/out.test.toml +++ b/acceptance/bundle/state/force_pull_commands/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/state/force_pull_commands/test.toml b/acceptance/bundle/state/force_pull_commands/test.toml index fdfa3ab33c0..429a262a2c9 100644 --- a/acceptance/bundle/state/force_pull_commands/test.toml +++ b/acceptance/bundle/state/force_pull_commands/test.toml @@ -3,7 +3,6 @@ RecordRequests = true Ignore = [".databricks"] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] [[Repls]] Old = '(resources\.json|terraform\.tfstate)' diff --git a/acceptance/bundle/state/future_version/out.test.toml b/acceptance/bundle/state/future_version/out.test.toml index 5d6d91241d2..fa44d14b3ae 100644 --- a/acceptance/bundle/state/future_version/out.test.toml +++ b/acceptance/bundle/state/future_version/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.STATE_FILE = ["resources.future.json", "resources.future_with_feature.json"] diff --git a/acceptance/bundle/state/future_version/test.toml b/acceptance/bundle/state/future_version/test.toml index 0d49a0272e7..190361bd603 100644 --- a/acceptance/bundle/state/future_version/test.toml +++ b/acceptance/bundle/state/future_version/test.toml @@ -1,5 +1,4 @@ Ignore = [".databricks"] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.STATE_FILE = ["resources.future.json", "resources.future_with_feature.json"] diff --git a/acceptance/bundle/state/lineage_different/out.test.toml b/acceptance/bundle/state/lineage_different/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/state/lineage_different/out.test.toml +++ b/acceptance/bundle/state/lineage_different/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/state/newer_cli_version/out.test.toml b/acceptance/bundle/state/newer_cli_version/out.test.toml index 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/state/newer_cli_version/out.test.toml +++ b/acceptance/bundle/state/newer_cli_version/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/state/newer_cli_version/test.toml b/acceptance/bundle/state/newer_cli_version/test.toml index d54612cbc49..e1f865c624d 100644 --- a/acceptance/bundle/state/newer_cli_version/test.toml +++ b/acceptance/bundle/state/newer_cli_version/test.toml @@ -1,6 +1,5 @@ Ignore = [".databricks"] # The warning is emitted when reading the direct engine's resources.json. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # This fixture seeds file-backed state; DMS mismatch behavior is covered under bundle/dms. EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/state/permission_level_migration/out.plan.direct.json b/acceptance/bundle/state/permission_level_migration/out.plan.json similarity index 100% rename from acceptance/bundle/state/permission_level_migration/out.plan.direct.json rename to acceptance/bundle/state/permission_level_migration/out.plan.json diff --git a/acceptance/bundle/state/permission_level_migration/out.test.toml b/acceptance/bundle/state/permission_level_migration/out.test.toml index 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/state/permission_level_migration/out.test.toml +++ b/acceptance/bundle/state/permission_level_migration/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/state/permission_level_migration/script b/acceptance/bundle/state/permission_level_migration/script index bd0cdee18f5..cfd4809fcd0 100644 --- a/acceptance/bundle/state/permission_level_migration/script +++ b/acceptance/bundle/state/permission_level_migration/script @@ -9,7 +9,7 @@ mkdir -p .databricks/bundle/default cp resources.v1.json .databricks/bundle/default/resources.json title "Plan with old v1 state" -trace $CLI bundle plan -o json | nostamp > out.plan.direct.json +trace $CLI bundle plan -o json | nostamp > out.plan.json title "Deploy (migrates state)" trace $CLI bundle deploy diff --git a/acceptance/bundle/state/permission_level_migration/test.toml b/acceptance/bundle/state/permission_level_migration/test.toml index 884ab4cfb29..4b4f83c101f 100644 --- a/acceptance/bundle/state/permission_level_migration/test.toml +++ b/acceptance/bundle/state/permission_level_migration/test.toml @@ -4,5 +4,3 @@ EnvMatrix.DMS = [""] Ignore = [".databricks"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/state/same_serial/out.test.toml b/acceptance/bundle/state/same_serial/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/state/same_serial/out.test.toml +++ b/acceptance/bundle/state/same_serial/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/state/state_present/databricks.yml b/acceptance/bundle/state/state_present/databricks.yml deleted file mode 100644 index 1b2e54dca47..00000000000 --- a/acceptance/bundle/state/state_present/databricks.yml +++ /dev/null @@ -1,8 +0,0 @@ -bundle: - name: test-bundle - -resources: - schemas: - foo: - catalog_name: bar - name: foo diff --git a/acceptance/bundle/state/state_present/out.test.toml b/acceptance/bundle/state/state_present/out.test.toml deleted file mode 100644 index ae800809893..00000000000 --- a/acceptance/bundle/state/state_present/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/state/state_present/output.txt b/acceptance/bundle/state/state_present/output.txt deleted file mode 100644 index 38d568259f6..00000000000 --- a/acceptance/bundle/state/state_present/output.txt +++ /dev/null @@ -1,95 +0,0 @@ - -=== Terraform state is present, empty env var uses state engine - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created schemas.foo -Files: 3 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged - ->>> print_requests.py //api/2.1/unity-catalog/schemas -"databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5 sdk/sdkv2 resource/schema auth/pat" - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 1 unchanged - ->>> print_requests.py --get //api/2.1/unity-catalog/schemas -"databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5 sdk/sdkv2 resource/schema auth/pat" - -=== Adding resources.json with lower serial does not change anything ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 1 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 1 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle plan -Plan: 0 to add, 0 to change, 0 to delete, 1 unchanged - -=== Adding resources.json with higher serial, env var mismatch warns but uses state engine - ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle plan -create schemas.foo - -Plan: 1 to add, 0 to change, 0 to delete, 0 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle plan -create schemas.foo - -Plan: 1 to add, 0 to change, 0 to delete, 0 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created schemas.foo -Files: 0 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle destroy --auto-approve -The following resources will be deleted: - delete resources.schemas.foo - -This action will result in the deletion of the following UC schemas. Any underlying data may be lost: - delete resources.schemas.foo - -All files and directories at the following location will be deleted: /Workspace/Users/[USERNAME]/.bundle/test-bundle/default - -Destroy: 1 deleted - ->>> DATABRICKS_BUNDLE_ENGINE=direct [CLI] bundle deploy -Warn: Direct engine selected via DATABRICKS_BUNDLE_ENGINE environment variable but the existing state uses "terraform". Deploying on "terraform"; will attempt to migrate the state to the direct engine after this deploy. -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Created schemas.foo -Files: 3 uploaded, 0 deleted -Resources: 1 created, 0 changed, 0 deleted, 0 unchanged -Migrating state to direct deployment engine (selected via DATABRICKS_BUNDLE_ENGINE environment variable)... -Migrated 1 resource to direct deployment engine. - ->>> print_requests.py //api/2.1/unity-catalog/schemas -"databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5 sdk/sdkv2 resource/schema auth/pat" - ->>> print_state.py -7 - ->>> DATABRICKS_BUNDLE_ENGINE=terraform [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 0 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 1 unchanged - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle deploy -Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... -Files: 0 uploaded, 0 deleted -Resources: 0 created, 0 changed, 0 deleted, 1 unchanged - ->>> print_requests.py --get //api/2.1/unity-catalog/schemas -"cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/direct auth/pat" -"cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/direct auth/pat" - ->>> print_state.py -7 - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle debug states -[TEST_TMP_DIR]/.databricks/bundle/default/resources.json: local direct state serial=7 lineage="test-lineage" - ->>> DATABRICKS_BUNDLE_ENGINE= [CLI] bundle debug states --force-pull -resources.json: remote direct state serial=7 lineage="test-lineage" -[TEST_TMP_DIR]/.databricks/bundle/default/resources.json: local direct state serial=7 lineage="test-lineage" diff --git a/acceptance/bundle/state/state_present/script b/acceptance/bundle/state/state_present/script deleted file mode 100644 index 5607b0baec3..00000000000 --- a/acceptance/bundle/state/state_present/script +++ /dev/null @@ -1,49 +0,0 @@ -title 'Terraform state is present, empty env var uses state engine\n' -mkdir -p .databricks/bundle/default/terraform -echo '{"version": 4, "serial": 1, "lineage": "test-lineage"}' > .databricks/bundle/default/terraform/terraform.tfstate - -# Deploy on terraform explicitly: with an empty env var direct is the default, so -# the deploy would migrate the state away from terraform (that path is covered by -# bundle/migrate/auto-migrate-default) and the rest of this test needs it intact. -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -trace print_requests.py //api/2.1/unity-catalog/schemas | jq '.headers["User-Agent"][0]' | contains.py 'terraform' 'tf-provider' '!direct' - -# An empty env var still reads the engine off the state, so plan runs on terraform. -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle plan -trace print_requests.py --get //api/2.1/unity-catalog/schemas | jq '.headers["User-Agent"][0]' | contains.py 'terraform' 'tf-provider' '!direct' - -title 'Adding resources.json with lower serial does not change anything' -rm .databricks/bundle/default/terraform/terraform.tfstate -echo '{"serial": 0, "lineage": "test-lineage"}' > .databricks/bundle/default/resources.json -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle plan -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle plan -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle plan - -rm "$OUT_REQUESTS" -title 'Adding resources.json with higher serial, env var mismatch warns but uses state engine\n' -echo '{"serial": 10, "lineage": "test-lineage"}' > .databricks/bundle/default/resources.json -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle plan -#trace print_requests.py --get //api/2.1/unity-catalog/schemas | jq '.headers["User-Agent"][0]' | contains.py 'engine/direct' '!terraform' '!tf-provider' - -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle plan -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle destroy --auto-approve - -rm "$OUT_REQUESTS" -# The destroy above ran on the higher-serial direct state and removed it, leaving only -# the terraform state the deploy created, so this deploy runs on terraform and migrates. -trace DATABRICKS_BUNDLE_ENGINE=direct $CLI bundle deploy -trace print_requests.py //api/2.1/unity-catalog/schemas | jq '.headers["User-Agent"][0]' | contains.py 'terraform' 'tf-provider' '!engine/direct' -trace print_state.py | jq .serial | contains.py "7" - -trace DATABRICKS_BUNDLE_ENGINE=terraform $CLI bundle deploy -#trace print_requests.py --get //api/2.1/unity-catalog/schemas | jq '.headers["User-Agent"][0]' | contains.py 'engine/direct' '!terraform' '!tf-provider' - -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle deploy -trace print_requests.py --get //api/2.1/unity-catalog/schemas | jq '.headers["User-Agent"][0]' | contains.py 'engine/direct' '!terraform' '!tf-provider' -trace print_state.py | jq .serial | contains.py "7" - -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle debug states -trace DATABRICKS_BUNDLE_ENGINE= $CLI bundle debug states --force-pull - -rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/state/state_present/test.toml b/acceptance/bundle/state/state_present/test.toml deleted file mode 100644 index 041121b226d..00000000000 --- a/acceptance/bundle/state/state_present/test.toml +++ /dev/null @@ -1,6 +0,0 @@ -# This test deploys on terraform and migrates to direct. Terraform deployments are not supported -# with deployment-history recording, so it only runs without it. -EnvMatrix.DMS = [""] - -RecordRequests = true -IncludeRequestHeaders = ["User-Agent"] diff --git a/acceptance/bundle/summary/missing-libraries-file-path/out.test.toml b/acceptance/bundle/summary/missing-libraries-file-path/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/summary/missing-libraries-file-path/out.test.toml +++ b/acceptance/bundle/summary/missing-libraries-file-path/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/summary/modified_status/out.test.toml b/acceptance/bundle/summary/modified_status/out.test.toml index c2eddd75c24..81fed133e17 100644 --- a/acceptance/bundle/summary/modified_status/out.test.toml +++ b/acceptance/bundle/summary/modified_status/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] EnvMatrix.VARIANT = ["empty_resources.yml", "no_resources.yml"] diff --git a/acceptance/bundle/sync-default-output/out.test.toml b/acceptance/bundle/sync-default-output/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/sync-default-output/out.test.toml +++ b/acceptance/bundle/sync-default-output/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/sync/dryrun/out.test.toml b/acceptance/bundle/sync/dryrun/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/sync/dryrun/out.test.toml +++ b/acceptance/bundle/sync/dryrun/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/sync/out.test.toml b/acceptance/bundle/sync/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/sync/out.test.toml +++ b/acceptance/bundle/sync/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/syncroot/dotdot-git/out.test.toml b/acceptance/bundle/syncroot/dotdot-git/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/syncroot/dotdot-git/out.test.toml +++ b/acceptance/bundle/syncroot/dotdot-git/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/syncroot/dotdot-nogit/out.test.toml b/acceptance/bundle/syncroot/dotdot-nogit/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/syncroot/dotdot-nogit/out.test.toml +++ b/acceptance/bundle/syncroot/dotdot-nogit/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/telemetry/config-remote-sync-error/databricks.yml b/acceptance/bundle/telemetry/config-remote-sync-error/databricks.yml deleted file mode 100644 index c0c9f880163..00000000000 --- a/acceptance/bundle/telemetry/config-remote-sync-error/databricks.yml +++ /dev/null @@ -1,11 +0,0 @@ -bundle: - name: config-remote-sync-telemetry-error - -resources: - jobs: - foo: - name: test job - tasks: - - task_key: main - notebook_task: - notebook_path: /Workspace/Users/tester@databricks.com/notebook diff --git a/acceptance/bundle/telemetry/config-remote-sync-error/out.test.toml b/acceptance/bundle/telemetry/config-remote-sync-error/out.test.toml deleted file mode 100644 index 500d0290dda..00000000000 --- a/acceptance/bundle/telemetry/config-remote-sync-error/out.test.toml +++ /dev/null @@ -1,4 +0,0 @@ -Cloud = false -GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/config-remote-sync-error/output.txt b/acceptance/bundle/telemetry/config-remote-sync-error/output.txt deleted file mode 100644 index 6dd1e517dec..00000000000 --- a/acceptance/bundle/telemetry/config-remote-sync-error/output.txt +++ /dev/null @@ -1,14 +0,0 @@ - ->>> errcode [CLI] bundle config-remote-sync -Error: state snapshot not available: resources state snapshot not found remotely at resources-config-sync-snapshot.json: state snapshot not found - -Exit code: 1 - ->>> cat [OUTPUT_DIR]/out.requests.txt -{ - "engine": "terraform", - "state_source": "local", - "states_available_count": 0, - "error_message": "state snapshot not available: resources state snapshot not found remotely at resources-config-sync-snapshot.json: state snapshot not found", - "error_category": "STATE_NOT_FOUND" -} diff --git a/acceptance/bundle/telemetry/config-remote-sync-error/script b/acceptance/bundle/telemetry/config-remote-sync-error/script deleted file mode 100644 index c47010b543f..00000000000 --- a/acceptance/bundle/telemetry/config-remote-sync-error/script +++ /dev/null @@ -1,7 +0,0 @@ -# Running config-remote-sync without a prior deploy: the state snapshot does -# not exist, so the command fails and telemetry reports STATE_NOT_FOUND. -trace errcode $CLI bundle config-remote-sync - -trace cat "$OUT_REQUESTS" | jq 'select(has("path") and .path == "/telemetry-ext") | .body.protoLogs[] | fromjson | .entry.databricks_cli_log.bundle_config_remote_sync_event | select(. != null)' - -rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/telemetry/config-remote-sync-error/test.toml b/acceptance/bundle/telemetry/config-remote-sync-error/test.toml deleted file mode 100644 index 1f760fd3b73..00000000000 --- a/acceptance/bundle/telemetry/config-remote-sync-error/test.toml +++ /dev/null @@ -1,7 +0,0 @@ -# config-remote-sync is not supported on Windows. -GOOS.windows = false - -# STATE_NOT_FOUND is a terraform-only path: the terraform engine pulls a config -# snapshot that doesn't exist without a prior deploy, while the direct engine -# does not. Pin the engine so the test exercises that specific failure. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] diff --git a/acceptance/bundle/telemetry/config-remote-sync-recreate/out.test.toml b/acceptance/bundle/telemetry/config-remote-sync-recreate/out.test.toml index 47a2f0c8b42..aadf9e4a151 100644 --- a/acceptance/bundle/telemetry/config-remote-sync-recreate/out.test.toml +++ b/acceptance/bundle/telemetry/config-remote-sync-recreate/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/config-remote-sync-recreate/test.toml b/acceptance/bundle/telemetry/config-remote-sync-recreate/test.toml index 02fa4545173..da2ddce254e 100644 --- a/acceptance/bundle/telemetry/config-remote-sync-recreate/test.toml +++ b/acceptance/bundle/telemetry/config-remote-sync-recreate/test.toml @@ -4,4 +4,3 @@ GOOS.windows = false # Pinned to the direct engine (see config-remote-sync/test.toml): telemetry is # engine-agnostic above the state layer, and recreate_forcing_changes is derived # from the resource lifecycle metadata, not from which engine read the state. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/telemetry/config-remote-sync-save/out.test.toml b/acceptance/bundle/telemetry/config-remote-sync-save/out.test.toml index 47a2f0c8b42..aadf9e4a151 100644 --- a/acceptance/bundle/telemetry/config-remote-sync-save/out.test.toml +++ b/acceptance/bundle/telemetry/config-remote-sync-save/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/config-remote-sync-save/test.toml b/acceptance/bundle/telemetry/config-remote-sync-save/test.toml index 1e78077ec4b..a25e7b5b36f 100644 --- a/acceptance/bundle/telemetry/config-remote-sync-save/test.toml +++ b/acceptance/bundle/telemetry/config-remote-sync-save/test.toml @@ -6,4 +6,3 @@ GOOS.windows = false # overwritten_local_edits is computed from the per-field deployed base, which # only the direct engine materializes (the terraform sync snapshot is empty). -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/telemetry/config-remote-sync-skipped-state/databricks.yml b/acceptance/bundle/telemetry/config-remote-sync-skipped-state/databricks.yml deleted file mode 100644 index 5d666546ce2..00000000000 --- a/acceptance/bundle/telemetry/config-remote-sync-skipped-state/databricks.yml +++ /dev/null @@ -1,11 +0,0 @@ -bundle: - name: config-remote-sync-skipped-state - -resources: - jobs: - foo: - name: test job - tasks: - - task_key: main - notebook_task: - notebook_path: /Workspace/Users/tester@databricks.com/notebook diff --git a/acceptance/bundle/telemetry/config-remote-sync-skipped-state/out.test.toml b/acceptance/bundle/telemetry/config-remote-sync-skipped-state/out.test.toml deleted file mode 100644 index 500d0290dda..00000000000 --- a/acceptance/bundle/telemetry/config-remote-sync-skipped-state/out.test.toml +++ /dev/null @@ -1,4 +0,0 @@ -Cloud = false -GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] -EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/config-remote-sync-skipped-state/output.txt b/acceptance/bundle/telemetry/config-remote-sync-skipped-state/output.txt deleted file mode 100644 index 35a1512c44f..00000000000 --- a/acceptance/bundle/telemetry/config-remote-sync-skipped-state/output.txt +++ /dev/null @@ -1,17 +0,0 @@ - ->>> errcode [CLI] bundle config-remote-sync -o json -{ - "status": "skipped", - "error": "state snapshot not available: resources state snapshot not found remotely at resources-config-sync-snapshot.json: state snapshot not found", - "files": null, - "changes": {} -} - ->>> cat [OUTPUT_DIR]/out.requests.txt -{ - "engine": "terraform", - "state_source": "local", - "states_available_count": 0, - "error_message": "state snapshot not available: resources state snapshot not found remotely at resources-config-sync-snapshot.json: state snapshot not found", - "error_category": "STATE_NOT_FOUND" -} diff --git a/acceptance/bundle/telemetry/config-remote-sync-skipped-state/script b/acceptance/bundle/telemetry/config-remote-sync-skipped-state/script deleted file mode 100644 index 6fe42a52411..00000000000 --- a/acceptance/bundle/telemetry/config-remote-sync-skipped-state/script +++ /dev/null @@ -1,8 +0,0 @@ -# Running config-remote-sync -o json without a prior deploy: the state snapshot -# does not exist. In JSON mode the command exits 0 and reports the outcome as -# skipped, but telemetry still records the STATE_NOT_FOUND error payload. -trace errcode $CLI bundle config-remote-sync -o json - -trace cat "$OUT_REQUESTS" | jq 'select(has("path") and .path == "/telemetry-ext") | .body.protoLogs[] | fromjson | .entry.databricks_cli_log.bundle_config_remote_sync_event | select(. != null)' - -rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/telemetry/config-remote-sync-skipped-state/test.toml b/acceptance/bundle/telemetry/config-remote-sync-skipped-state/test.toml deleted file mode 100644 index 6936e889127..00000000000 --- a/acceptance/bundle/telemetry/config-remote-sync-skipped-state/test.toml +++ /dev/null @@ -1,7 +0,0 @@ -# config-remote-sync is not supported on Windows. -GOOS.windows = false - -# STATE_NOT_FOUND is a terraform-only path: the terraform engine pulls a config -# snapshot that doesn't exist without a prior deploy, while the direct engine -# does not. Pin the engine so the test exercises that specific outcome. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] diff --git a/acceptance/bundle/telemetry/config-remote-sync/out.test.toml b/acceptance/bundle/telemetry/config-remote-sync/out.test.toml index 47a2f0c8b42..aadf9e4a151 100644 --- a/acceptance/bundle/telemetry/config-remote-sync/out.test.toml +++ b/acceptance/bundle/telemetry/config-remote-sync/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/config-remote-sync/test.toml b/acceptance/bundle/telemetry/config-remote-sync/test.toml index 1de7c8266f0..9f16a3927fe 100644 --- a/acceptance/bundle/telemetry/config-remote-sync/test.toml +++ b/acceptance/bundle/telemetry/config-remote-sync/test.toml @@ -6,4 +6,3 @@ GOOS.windows = false # supports (all terraform config-remote-sync coverage lives in the Cloud=true # acceptance/bundle/config-remote-sync tests). Direct is the default engine for # new bundles, and the telemetry is engine-agnostic above the state layer. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/telemetry/deploy-ai-runtime-task/out.test.toml b/acceptance/bundle/telemetry/deploy-ai-runtime-task/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-ai-runtime-task/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-ai-runtime-task/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-app-lifecycle-started/out.test.toml b/acceptance/bundle/telemetry/deploy-app-lifecycle-started/out.test.toml index 27ec2a7fcd6..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-app-lifecycle-started/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-app-lifecycle-started/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-app-lifecycle-started/output.txt b/acceptance/bundle/telemetry/deploy-app-lifecycle-started/output.txt index db642ef17c3..145912a90bd 100644 --- a/acceptance/bundle/telemetry/deploy-app-lifecycle-started/output.txt +++ b/acceptance/bundle/telemetry/deploy-app-lifecycle-started/output.txt @@ -3,7 +3,7 @@ Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files... ✓ Deployment succeeded Created apps.myapp -Files: 3 uploaded, 0 deleted +Files: 2 uploaded, 0 deleted Resources: 1 created, 0 changed, 0 deleted, 0 unchanged >>> cat [OUTPUT_DIR]/out.requests.txt diff --git a/acceptance/bundle/telemetry/deploy-app-lifecycle-started/test.toml b/acceptance/bundle/telemetry/deploy-app-lifecycle-started/test.toml deleted file mode 100644 index 9609e1af299..00000000000 --- a/acceptance/bundle/telemetry/deploy-app-lifecycle-started/test.toml +++ /dev/null @@ -1 +0,0 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/telemetry/deploy-artifact-path-type/out.test.toml b/acceptance/bundle/telemetry/deploy-artifact-path-type/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-artifact-path-type/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-artifact-path-type/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-artifacts-variables/out.test.toml b/acceptance/bundle/telemetry/deploy-artifacts-variables/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-artifacts-variables/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-artifacts-variables/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-compute-type/out.drymigrate.direct.txt b/acceptance/bundle/telemetry/deploy-compute-type/out.drymigrate.direct.txt deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/acceptance/bundle/telemetry/deploy-compute-type/out.drymigrate.terraform.txt b/acceptance/bundle/telemetry/deploy-compute-type/out.drymigrate.terraform.txt deleted file mode 100644 index d788ea96e0b..00000000000 --- a/acceptance/bundle/telemetry/deploy-compute-type/out.drymigrate.terraform.txt +++ /dev/null @@ -1,4 +0,0 @@ -direct_drymigrate_success true -direct_drymigrate_success true -direct_drymigrate_warnings false -direct_drymigrate_warnings false diff --git a/acceptance/bundle/resources/permissions/pipelines/empty_list/out.requests.deploy.direct.json b/acceptance/bundle/telemetry/deploy-compute-type/out.drymigrate.txt similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/empty_list/out.requests.deploy.direct.json rename to acceptance/bundle/telemetry/deploy-compute-type/out.drymigrate.txt diff --git a/acceptance/bundle/telemetry/deploy-compute-type/out.test.toml b/acceptance/bundle/telemetry/deploy-compute-type/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-compute-type/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-compute-type/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-compute-type/script b/acceptance/bundle/telemetry/deploy-compute-type/script index 38d14733f68..e94d531749c 100644 --- a/acceptance/bundle/telemetry/deploy-compute-type/script +++ b/acceptance/bundle/telemetry/deploy-compute-type/script @@ -4,6 +4,6 @@ trace $CLI bundle deploy -t two # Common bool_values are engine-agnostic; the terraform-only direct_drymigrate_* # entries go to a per-engine file so output.txt stays shared. trace print_telemetry_bool_values | grep -v direct_drymigrate -print_telemetry_bool_values | grep direct_drymigrate > out.drymigrate.$DATABRICKS_BUNDLE_ENGINE.txt || true +print_telemetry_bool_values | grep direct_drymigrate > out.drymigrate.txt || true rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/telemetry/deploy-config-file-count/out.test.toml b/acceptance/bundle/telemetry/deploy-config-file-count/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-config-file-count/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-config-file-count/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-error-message/out.test.toml b/acceptance/bundle/telemetry/deploy-error-message/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-error-message/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-error-message/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-error/out.test.toml b/acceptance/bundle/telemetry/deploy-error/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-error/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-error/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-experimental/out.drymigrate.direct.txt b/acceptance/bundle/telemetry/deploy-experimental/out.drymigrate.direct.txt deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/acceptance/bundle/telemetry/deploy-experimental/out.drymigrate.terraform.txt b/acceptance/bundle/telemetry/deploy-experimental/out.drymigrate.terraform.txt deleted file mode 100644 index d7fac6e7778..00000000000 --- a/acceptance/bundle/telemetry/deploy-experimental/out.drymigrate.terraform.txt +++ /dev/null @@ -1,2 +0,0 @@ -direct_drymigrate_success true -direct_drymigrate_warnings false diff --git a/acceptance/bundle/resources/permissions/pipelines/empty_list/out.requests.deploy.terraform.json b/acceptance/bundle/telemetry/deploy-experimental/out.drymigrate.txt similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/empty_list/out.requests.deploy.terraform.json rename to acceptance/bundle/telemetry/deploy-experimental/out.drymigrate.txt diff --git a/acceptance/bundle/telemetry/deploy-experimental/out.test.toml b/acceptance/bundle/telemetry/deploy-experimental/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-experimental/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-experimental/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-experimental/script b/acceptance/bundle/telemetry/deploy-experimental/script index 0510777f9a6..bef19c1fbce 100644 --- a/acceptance/bundle/telemetry/deploy-experimental/script +++ b/acceptance/bundle/telemetry/deploy-experimental/script @@ -3,6 +3,6 @@ trace $CLI bundle deploy # Common bool_values are engine-agnostic; the terraform-only direct_drymigrate_* # entries go to a per-engine file so output.txt stays shared. trace print_telemetry_bool_values | grep -v direct_drymigrate -print_telemetry_bool_values | grep direct_drymigrate > out.drymigrate.$DATABRICKS_BUNDLE_ENGINE.txt || true +print_telemetry_bool_values | grep direct_drymigrate > out.drymigrate.txt || true rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/telemetry/deploy-failed-engine-unknown/out.resources_metadata.terraform.txt b/acceptance/bundle/telemetry/deploy-failed-engine-unknown/out.resources_metadata.terraform.txt deleted file mode 100644 index 655db8c5497..00000000000 --- a/acceptance/bundle/telemetry/deploy-failed-engine-unknown/out.resources_metadata.terraform.txt +++ /dev/null @@ -1,9 +0,0 @@ -{ - "state_engine": "terraform", - "resources": [ - { - "resource_type": "jobs", - "count": 1 - } - ] -} diff --git a/acceptance/bundle/telemetry/deploy-failed-engine-unknown/out.resources_metadata.direct.txt b/acceptance/bundle/telemetry/deploy-failed-engine-unknown/out.resources_metadata.txt similarity index 100% rename from acceptance/bundle/telemetry/deploy-failed-engine-unknown/out.resources_metadata.direct.txt rename to acceptance/bundle/telemetry/deploy-failed-engine-unknown/out.resources_metadata.txt diff --git a/acceptance/bundle/telemetry/deploy-failed-engine-unknown/out.test.toml b/acceptance/bundle/telemetry/deploy-failed-engine-unknown/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-failed-engine-unknown/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-failed-engine-unknown/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-failed-engine-unknown/script b/acceptance/bundle/telemetry/deploy-failed-engine-unknown/script index fe47d66df25..2031cba0e21 100644 --- a/acceptance/bundle/telemetry/deploy-failed-engine-unknown/script +++ b/acceptance/bundle/telemetry/deploy-failed-engine-unknown/script @@ -7,7 +7,7 @@ cat "$OUT_REQUESTS" | jq 'select(has("path") and .path == "/telemetry-ext") | .b # set as soon as the deployment state is pulled, not only inside deployCore. Before # that fix state_engine was empty on this path, which the dashboard showed as # engine="unknown". state_engine is engine-specific, so capture it per-engine. -cat telemetry.json | jq '.entry.databricks_cli_log.bundle_deploy_event.resources_metadata' > out.resources_metadata.$DATABRICKS_BUNDLE_ENGINE.txt +cat telemetry.json | jq '.entry.databricks_cli_log.bundle_deploy_event.resources_metadata' > out.resources_metadata.txt rm "$OUT_REQUESTS" rm telemetry.json diff --git a/acceptance/bundle/telemetry/deploy-failed-state-pull/out.resources_metadata.terraform.txt b/acceptance/bundle/telemetry/deploy-failed-state-pull/out.resources_metadata.terraform.txt deleted file mode 100644 index 655db8c5497..00000000000 --- a/acceptance/bundle/telemetry/deploy-failed-state-pull/out.resources_metadata.terraform.txt +++ /dev/null @@ -1,9 +0,0 @@ -{ - "state_engine": "terraform", - "resources": [ - { - "resource_type": "jobs", - "count": 1 - } - ] -} diff --git a/acceptance/bundle/telemetry/deploy-failed-state-pull/out.resources_metadata.direct.txt b/acceptance/bundle/telemetry/deploy-failed-state-pull/out.resources_metadata.txt similarity index 100% rename from acceptance/bundle/telemetry/deploy-failed-state-pull/out.resources_metadata.direct.txt rename to acceptance/bundle/telemetry/deploy-failed-state-pull/out.resources_metadata.txt diff --git a/acceptance/bundle/telemetry/deploy-failed-state-pull/out.test.toml b/acceptance/bundle/telemetry/deploy-failed-state-pull/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-failed-state-pull/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-failed-state-pull/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-failed-state-pull/script b/acceptance/bundle/telemetry/deploy-failed-state-pull/script index 4ecebdc9d5e..82dbddd40f5 100644 --- a/acceptance/bundle/telemetry/deploy-failed-state-pull/script +++ b/acceptance/bundle/telemetry/deploy-failed-state-pull/script @@ -7,7 +7,7 @@ cat "$OUT_REQUESTS" | jq 'select(has("path") and .path == "/telemetry-ext") | .b # state_engine is engine-specific, so capture it per-engine. state_file_size_bytes is # dropped: it is os.Stat of the (committed) resources.json, whose byte count can shift # with line-ending conversion across platforms. -cat telemetry.json | jq '.entry.databricks_cli_log.bundle_deploy_event.resources_metadata | if . then del(.state_file_size_bytes) else . end' > out.resources_metadata.$DATABRICKS_BUNDLE_ENGINE.txt +cat telemetry.json | jq '.entry.databricks_cli_log.bundle_deploy_event.resources_metadata | if . then del(.state_file_size_bytes) else . end' > out.resources_metadata.txt rm "$OUT_REQUESTS" rm telemetry.json diff --git a/acceptance/bundle/telemetry/deploy-mode/out.test.toml b/acceptance/bundle/telemetry/deploy-mode/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-mode/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-mode/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-name-prefix/custom/out.drymigrate.direct.txt b/acceptance/bundle/telemetry/deploy-name-prefix/custom/out.drymigrate.direct.txt deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/acceptance/bundle/telemetry/deploy-name-prefix/custom/out.drymigrate.terraform.txt b/acceptance/bundle/telemetry/deploy-name-prefix/custom/out.drymigrate.terraform.txt deleted file mode 100644 index d7fac6e7778..00000000000 --- a/acceptance/bundle/telemetry/deploy-name-prefix/custom/out.drymigrate.terraform.txt +++ /dev/null @@ -1,2 +0,0 @@ -direct_drymigrate_success true -direct_drymigrate_warnings false diff --git a/acceptance/bundle/resources/permissions/pipelines/empty_list/out.requests.destroy.direct.json b/acceptance/bundle/telemetry/deploy-name-prefix/custom/out.drymigrate.txt similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/empty_list/out.requests.destroy.direct.json rename to acceptance/bundle/telemetry/deploy-name-prefix/custom/out.drymigrate.txt diff --git a/acceptance/bundle/telemetry/deploy-name-prefix/custom/out.test.toml b/acceptance/bundle/telemetry/deploy-name-prefix/custom/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-name-prefix/custom/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-name-prefix/custom/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-name-prefix/custom/script b/acceptance/bundle/telemetry/deploy-name-prefix/custom/script index 0510777f9a6..bef19c1fbce 100644 --- a/acceptance/bundle/telemetry/deploy-name-prefix/custom/script +++ b/acceptance/bundle/telemetry/deploy-name-prefix/custom/script @@ -3,6 +3,6 @@ trace $CLI bundle deploy # Common bool_values are engine-agnostic; the terraform-only direct_drymigrate_* # entries go to a per-engine file so output.txt stays shared. trace print_telemetry_bool_values | grep -v direct_drymigrate -print_telemetry_bool_values | grep direct_drymigrate > out.drymigrate.$DATABRICKS_BUNDLE_ENGINE.txt || true +print_telemetry_bool_values | grep direct_drymigrate > out.drymigrate.txt || true rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/telemetry/deploy-name-prefix/mode-development/out.drymigrate.direct.txt b/acceptance/bundle/telemetry/deploy-name-prefix/mode-development/out.drymigrate.direct.txt deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/acceptance/bundle/telemetry/deploy-name-prefix/mode-development/out.drymigrate.terraform.txt b/acceptance/bundle/telemetry/deploy-name-prefix/mode-development/out.drymigrate.terraform.txt deleted file mode 100644 index d7fac6e7778..00000000000 --- a/acceptance/bundle/telemetry/deploy-name-prefix/mode-development/out.drymigrate.terraform.txt +++ /dev/null @@ -1,2 +0,0 @@ -direct_drymigrate_success true -direct_drymigrate_warnings false diff --git a/acceptance/bundle/resources/permissions/pipelines/empty_list/out.requests.destroy.terraform.json b/acceptance/bundle/telemetry/deploy-name-prefix/mode-development/out.drymigrate.txt similarity index 100% rename from acceptance/bundle/resources/permissions/pipelines/empty_list/out.requests.destroy.terraform.json rename to acceptance/bundle/telemetry/deploy-name-prefix/mode-development/out.drymigrate.txt diff --git a/acceptance/bundle/telemetry/deploy-name-prefix/mode-development/out.test.toml b/acceptance/bundle/telemetry/deploy-name-prefix/mode-development/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-name-prefix/mode-development/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-name-prefix/mode-development/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-name-prefix/mode-development/script b/acceptance/bundle/telemetry/deploy-name-prefix/mode-development/script index 0510777f9a6..bef19c1fbce 100644 --- a/acceptance/bundle/telemetry/deploy-name-prefix/mode-development/script +++ b/acceptance/bundle/telemetry/deploy-name-prefix/mode-development/script @@ -3,6 +3,6 @@ trace $CLI bundle deploy # Common bool_values are engine-agnostic; the terraform-only direct_drymigrate_* # entries go to a per-engine file so output.txt stays shared. trace print_telemetry_bool_values | grep -v direct_drymigrate -print_telemetry_bool_values | grep direct_drymigrate > out.drymigrate.$DATABRICKS_BUNDLE_ENGINE.txt || true +print_telemetry_bool_values | grep direct_drymigrate > out.drymigrate.txt || true rm "$OUT_REQUESTS" diff --git a/acceptance/bundle/telemetry/deploy-no-uuid/out.test.toml b/acceptance/bundle/telemetry/deploy-no-uuid/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-no-uuid/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-no-uuid/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-run-as/out.test.toml b/acceptance/bundle/telemetry/deploy-run-as/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-run-as/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-run-as/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-target-count/out.test.toml b/acceptance/bundle/telemetry/deploy-target-count/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-target-count/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-target-count/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-variable-count/out.test.toml b/acceptance/bundle/telemetry/deploy-variable-count/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-variable-count/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-variable-count/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-whl-artifacts/out.test.toml b/acceptance/bundle/telemetry/deploy-whl-artifacts/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-whl-artifacts/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-whl-artifacts/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy-workspace-folder-permissions/out.test.toml b/acceptance/bundle/telemetry/deploy-workspace-folder-permissions/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy-workspace-folder-permissions/out.test.toml +++ b/acceptance/bundle/telemetry/deploy-workspace-folder-permissions/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy/out.engine.terraform.txt b/acceptance/bundle/telemetry/deploy/out.engine.terraform.txt deleted file mode 100644 index 60cb8fdc893..00000000000 --- a/acceptance/bundle/telemetry/deploy/out.engine.terraform.txt +++ /dev/null @@ -1,6 +0,0 @@ -[ - { - "key": "engine_terraform_env", - "value": true - } -] diff --git a/acceptance/bundle/telemetry/deploy/out.engine.direct.txt b/acceptance/bundle/telemetry/deploy/out.engine.txt similarity index 100% rename from acceptance/bundle/telemetry/deploy/out.engine.direct.txt rename to acceptance/bundle/telemetry/deploy/out.engine.txt diff --git a/acceptance/bundle/telemetry/deploy/out.migration.terraform.txt b/acceptance/bundle/telemetry/deploy/out.migration.terraform.txt deleted file mode 100644 index c503d0fb40b..00000000000 --- a/acceptance/bundle/telemetry/deploy/out.migration.terraform.txt +++ /dev/null @@ -1,10 +0,0 @@ -[ - { - "key": "direct_drymigrate_success", - "value": true - }, - { - "key": "direct_drymigrate_warnings", - "value": false - } -] diff --git a/acceptance/bundle/telemetry/deploy/out.migration.direct.txt b/acceptance/bundle/telemetry/deploy/out.migration.txt similarity index 100% rename from acceptance/bundle/telemetry/deploy/out.migration.direct.txt rename to acceptance/bundle/telemetry/deploy/out.migration.txt diff --git a/acceptance/bundle/telemetry/deploy/out.resources_metadata.terraform.txt b/acceptance/bundle/telemetry/deploy/out.resources_metadata.terraform.txt deleted file mode 100644 index 0b1ce4ca7ac..00000000000 --- a/acceptance/bundle/telemetry/deploy/out.resources_metadata.terraform.txt +++ /dev/null @@ -1,13 +0,0 @@ -{ - "state_engine": "terraform", - "resources": [ - { - "resource_type": "jobs", - "count": 3 - }, - { - "resource_type": "pipelines", - "count": 2 - } - ] -} diff --git a/acceptance/bundle/telemetry/deploy/out.resources_metadata.direct.txt b/acceptance/bundle/telemetry/deploy/out.resources_metadata.txt similarity index 100% rename from acceptance/bundle/telemetry/deploy/out.resources_metadata.direct.txt rename to acceptance/bundle/telemetry/deploy/out.resources_metadata.txt diff --git a/acceptance/bundle/telemetry/deploy/out.test.toml b/acceptance/bundle/telemetry/deploy/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/telemetry/deploy/out.test.toml +++ b/acceptance/bundle/telemetry/deploy/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/telemetry/deploy/script b/acceptance/bundle/telemetry/deploy/script index a3aa4c46df2..dc50997fb58 100644 --- a/acceptance/bundle/telemetry/deploy/script +++ b/acceptance/bundle/telemetry/deploy/script @@ -14,21 +14,21 @@ trace cat telemetry.json | jq ' .entry.databricks_cli_log.bundle_deploy_event.ex # for a fixed config and asserted exactly. state_file_size_bytes is dropped because # it is os.Stat of resources.json, whose header embeds the CLI version string # (-dev+ on linux/macos vs -dev on windows). -cat telemetry.json | jq '.entry.databricks_cli_log.bundle_deploy_event.resources_metadata | if . then del(.state_file_size_bytes) else . end' > out.resources_metadata.$DATABRICKS_BUNDLE_ENGINE.txt +cat telemetry.json | jq '.entry.databricks_cli_log.bundle_deploy_event.resources_metadata | if . then del(.state_file_size_bytes) else . end' > out.resources_metadata.txt # The dry-run migration to the direct engine runs only after a terraform deploy, # so its bool_values entries (direct_drymigrate_*) diverge across the # DATABRICKS_BUNDLE_ENGINE matrix (absent for direct). Capture them per-engine and # drop them from the engine-agnostic out.telemetry.txt below. title "Assert the dry-run migration to the direct engine is reported" -cat telemetry.json | jq '[.entry.databricks_cli_log.bundle_deploy_event.experimental.bool_values[] | select(.key | startswith("direct_drymigrate_"))]' > out.migration.$DATABRICKS_BUNDLE_ENGINE.txt +cat telemetry.json | jq '[.entry.databricks_cli_log.bundle_deploy_event.experimental.bool_values[] | select(.key | startswith("direct_drymigrate_"))]' > out.migration.txt # engine_terraform_env reflects DATABRICKS_BUNDLE_ENGINE, which the acceptance # matrix sets per variant, so it diverges across the matrix. Capture the # engine_terraform_* keys per-engine and drop them from the engine-agnostic # out.telemetry.txt below. title "Assert the terraform engine opt-in is reported" -cat telemetry.json | jq '[.entry.databricks_cli_log.bundle_deploy_event.experimental.bool_values[] | select(.key | startswith("engine_terraform_"))]' > out.engine.$DATABRICKS_BUNDLE_ENGINE.txt +cat telemetry.json | jq '[.entry.databricks_cli_log.bundle_deploy_event.experimental.bool_values[] | select(.key | startswith("engine_terraform_"))]' > out.engine.txt # bundle_mutator_execution_time_ms can have variable number of entries depending upon the runtime of the mutators. Thus we omit it from # being asserted here. diff --git a/acceptance/bundle/templates-machinery/helper_upper_lower/out.test.toml b/acceptance/bundle/templates-machinery/helper_upper_lower/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/templates-machinery/helper_upper_lower/out.test.toml +++ b/acceptance/bundle/templates-machinery/helper_upper_lower/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/templates-machinery/helper_username/out.test.toml b/acceptance/bundle/templates-machinery/helper_username/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/templates-machinery/helper_username/out.test.toml +++ b/acceptance/bundle/templates-machinery/helper_username/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/templates-machinery/helpers-error/out.test.toml b/acceptance/bundle/templates-machinery/helpers-error/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/templates-machinery/helpers-error/out.test.toml +++ b/acceptance/bundle/templates-machinery/helpers-error/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/templates-machinery/number-precision/out.test.toml b/acceptance/bundle/templates-machinery/number-precision/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/templates-machinery/number-precision/out.test.toml +++ b/acceptance/bundle/templates-machinery/number-precision/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/templates-machinery/supported-url/out.test.toml b/acceptance/bundle/templates-machinery/supported-url/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/templates-machinery/supported-url/out.test.toml +++ b/acceptance/bundle/templates-machinery/supported-url/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/templates-machinery/unsupported-url/out.test.toml b/acceptance/bundle/templates-machinery/unsupported-url/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/templates-machinery/unsupported-url/out.test.toml +++ b/acceptance/bundle/templates-machinery/unsupported-url/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/templates-machinery/wrong-path/out.test.toml b/acceptance/bundle/templates-machinery/wrong-path/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/templates-machinery/wrong-path/out.test.toml +++ b/acceptance/bundle/templates-machinery/wrong-path/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/templates-machinery/wrong-url/out.test.toml b/acceptance/bundle/templates-machinery/wrong-url/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/templates-machinery/wrong-url/out.test.toml +++ b/acceptance/bundle/templates-machinery/wrong-url/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/templates/dbt-sql-classic/out.test.toml b/acceptance/bundle/templates/dbt-sql-classic/out.test.toml index 86234a2fd03..bbd44e1b741 100644 --- a/acceptance/bundle/templates/dbt-sql-classic/out.test.toml +++ b/acceptance/bundle/templates/dbt-sql-classic/out.test.toml @@ -1,4 +1,3 @@ Cloud = false Phase = 1 -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/dbt-sql/out.test.toml b/acceptance/bundle/templates/dbt-sql/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/dbt-sql/out.test.toml +++ b/acceptance/bundle/templates/dbt-sql/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/default-minimal/python/out.test.toml b/acceptance/bundle/templates/default-minimal/python/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/default-minimal/python/out.test.toml +++ b/acceptance/bundle/templates/default-minimal/python/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/default-minimal/skip/out.test.toml b/acceptance/bundle/templates/default-minimal/skip/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/default-minimal/skip/out.test.toml +++ b/acceptance/bundle/templates/default-minimal/skip/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/default-minimal/sql/out.test.toml b/acceptance/bundle/templates/default-minimal/sql/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/default-minimal/sql/out.test.toml +++ b/acceptance/bundle/templates/default-minimal/sql/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/default-python/azure-government/out.test.toml b/acceptance/bundle/templates/default-python/azure-government/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/default-python/azure-government/out.test.toml +++ b/acceptance/bundle/templates/default-python/azure-government/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/default-python/classic/out.plan_after_deploy_dev.direct.json b/acceptance/bundle/templates/default-python/classic/out.plan_after_deploy_dev.json similarity index 100% rename from acceptance/bundle/templates/default-python/classic/out.plan_after_deploy_dev.direct.json rename to acceptance/bundle/templates/default-python/classic/out.plan_after_deploy_dev.json diff --git a/acceptance/bundle/templates/default-python/classic/out.plan_after_deploy_dev.terraform.json b/acceptance/bundle/templates/default-python/classic/out.plan_after_deploy_dev.terraform.json deleted file mode 100644 index d6d291785a6..00000000000 --- a/acceptance/bundle/templates/default-python/classic/out.plan_after_deploy_dev.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.sample_job": { - "action": "update" - }, - "resources.pipelines.my_default_python_etl": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/templates/default-python/classic/out.plan_after_deploy_prod.direct.json b/acceptance/bundle/templates/default-python/classic/out.plan_after_deploy_prod.json similarity index 100% rename from acceptance/bundle/templates/default-python/classic/out.plan_after_deploy_prod.direct.json rename to acceptance/bundle/templates/default-python/classic/out.plan_after_deploy_prod.json diff --git a/acceptance/bundle/templates/default-python/classic/out.plan_after_deploy_prod.terraform.json b/acceptance/bundle/templates/default-python/classic/out.plan_after_deploy_prod.terraform.json deleted file mode 100644 index 6a603440949..00000000000 --- a/acceptance/bundle/templates/default-python/classic/out.plan_after_deploy_prod.terraform.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.sample_job": { - "action": "skip" - }, - "resources.jobs.sample_job.permissions": { - "action": "skip" - }, - "resources.pipelines.my_default_python_etl": { - "action": "skip" - }, - "resources.pipelines.my_default_python_etl.permissions": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/templates/default-python/classic/out.plan_dev.direct.json b/acceptance/bundle/templates/default-python/classic/out.plan_dev.json similarity index 100% rename from acceptance/bundle/templates/default-python/classic/out.plan_dev.direct.json rename to acceptance/bundle/templates/default-python/classic/out.plan_dev.json diff --git a/acceptance/bundle/templates/default-python/classic/out.plan_dev.terraform.json b/acceptance/bundle/templates/default-python/classic/out.plan_dev.terraform.json deleted file mode 100644 index 9394f9faeb6..00000000000 --- a/acceptance/bundle/templates/default-python/classic/out.plan_dev.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.sample_job": { - "action": "create" - }, - "resources.pipelines.my_default_python_etl": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/templates/default-python/classic/out.plan_prod.direct.json b/acceptance/bundle/templates/default-python/classic/out.plan_prod.json similarity index 100% rename from acceptance/bundle/templates/default-python/classic/out.plan_prod.direct.json rename to acceptance/bundle/templates/default-python/classic/out.plan_prod.json diff --git a/acceptance/bundle/templates/default-python/classic/out.plan_prod.terraform.json b/acceptance/bundle/templates/default-python/classic/out.plan_prod.terraform.json deleted file mode 100644 index dd5e846c557..00000000000 --- a/acceptance/bundle/templates/default-python/classic/out.plan_prod.terraform.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.sample_job": { - "action": "create" - }, - "resources.jobs.sample_job.permissions": { - "action": "create" - }, - "resources.pipelines.my_default_python_etl": { - "action": "create" - }, - "resources.pipelines.my_default_python_etl.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/templates/default-python/classic/out.requests.dev.terraform.txt b/acceptance/bundle/templates/default-python/classic/out.requests.dev.terraform.txt deleted file mode 100644 index 6791806a752..00000000000 --- a/acceptance/bundle/templates/default-python/classic/out.requests.dev.terraform.txt +++ /dev/null @@ -1,196 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/pipelines", - "body": { - "channel": "CURRENT", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/state/metadata.json" - }, - "development": true, - "edition": "ADVANCED", - "environment": { - "dependencies": [ - "--editable /Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files" - ] - }, - "libraries": [ - { - "glob": { - "include": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/my_default_python_etl/transformations/**" - } - } - ], - "name": "[dev [USERNAME]] my_default_python_etl", - "root_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/my_default_python_etl", - "schema": "[USERNAME]", - "tags": { - "dev": "[USERNAME]" - } - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/delete", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal", - "recursive": true - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/.vscode" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/fixtures" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/resources" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/my_default_python" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/my_default_python_etl/transformations" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/tests" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/state" - } -} -{ - "method": "POST", - "path": "/api/2.2/jobs/create", - "body": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "job_clusters": [ - { - "job_cluster_key": "job_cluster", - "new_cluster": { - "autoscale": { - "max_workers": 4, - "min_workers": 1 - }, - "data_security_mode": "DATA_SECURITY_MODE_AUTO", - "node_type_id": "[NODE_TYPE_ID]", - "spark_version": "16.4.x-scala2.12" - } - } - ], - "max_concurrent_runs": 4, - "name": "[dev [USERNAME]] sample_job", - "parameters": [ - { - "default": "hive_metastore", - "name": "catalog" - }, - { - "default": "[USERNAME]", - "name": "schema" - } - ], - "queue": { - "enabled": true - }, - "tags": { - "dev": "[USERNAME]" - }, - "tasks": [ - { - "job_cluster_key": "job_cluster", - "libraries": [ - { - "whl": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl" - } - ], - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/sample_notebook", - "source": "WORKSPACE" - }, - "task_key": "notebook_task" - }, - { - "depends_on": [ - { - "task_key": "notebook_task" - } - ], - "job_cluster_key": "job_cluster", - "libraries": [ - { - "whl": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1+[UNIX_TIME_NANOS][0]-py3-none-any.whl" - } - ], - "python_wheel_task": { - "entry_point": "main", - "package_name": "my_default_python", - "parameters": [ - "--catalog", - "hive_metastore", - "--schema", - "[USERNAME]" - ] - }, - "task_key": "python_wheel_task" - }, - { - "depends_on": [ - { - "task_key": "notebook_task" - } - ], - "pipeline_task": { - "pipeline_id": "[UUID]" - }, - "task_key": "refresh_pipeline" - } - ], - "trigger": { - "pause_status": "PAUSED", - "periodic": { - "interval": 1, - "unit": "DAYS" - } - } - } -} diff --git a/acceptance/bundle/templates/default-python/classic/out.requests.dev.direct.txt b/acceptance/bundle/templates/default-python/classic/out.requests.dev.txt similarity index 100% rename from acceptance/bundle/templates/default-python/classic/out.requests.dev.direct.txt rename to acceptance/bundle/templates/default-python/classic/out.requests.dev.txt diff --git a/acceptance/bundle/templates/default-python/classic/out.requests.prod.terraform.txt b/acceptance/bundle/templates/default-python/classic/out.requests.prod.terraform.txt deleted file mode 100644 index 4726a39536a..00000000000 --- a/acceptance/bundle/templates/default-python/classic/out.requests.prod.terraform.txt +++ /dev/null @@ -1,232 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/pipelines", - "body": { - "channel": "CURRENT", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/state/metadata.json" - }, - "edition": "ADVANCED", - "environment": { - "dependencies": [ - "--editable /Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files" - ] - }, - "libraries": [ - { - "glob": { - "include": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files/src/my_default_python_etl/transformations/**" - } - } - ], - "name": "my_default_python_etl", - "root_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files/src/my_default_python_etl", - "schema": "prod" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/delete", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/artifacts/.internal", - "recursive": true - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/delete", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/state/deploy.lock" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/artifacts/.internal" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files/.vscode" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files/fixtures" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files/resources" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files/src/my_default_python" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files/src/my_default_python_etl/transformations" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files/tests" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/state" - } -} -{ - "method": "POST", - "path": "/api/2.2/jobs/create", - "body": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "format": "MULTI_TASK", - "job_clusters": [ - { - "job_cluster_key": "job_cluster", - "new_cluster": { - "autoscale": { - "max_workers": 4, - "min_workers": 1 - }, - "data_security_mode": "DATA_SECURITY_MODE_AUTO", - "node_type_id": "[NODE_TYPE_ID]", - "spark_version": "16.4.x-scala2.12" - } - } - ], - "max_concurrent_runs": 1, - "name": "sample_job", - "parameters": [ - { - "default": "hive_metastore", - "name": "catalog" - }, - { - "default": "prod", - "name": "schema" - } - ], - "queue": { - "enabled": true - }, - "tasks": [ - { - "job_cluster_key": "job_cluster", - "libraries": [ - { - "whl": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/artifacts/.internal/my_default_python-0.0.1-py3-none-any.whl" - } - ], - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files/src/sample_notebook", - "source": "WORKSPACE" - }, - "task_key": "notebook_task" - }, - { - "depends_on": [ - { - "task_key": "notebook_task" - } - ], - "job_cluster_key": "job_cluster", - "libraries": [ - { - "whl": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/artifacts/.internal/my_default_python-0.0.1-py3-none-any.whl" - } - ], - "python_wheel_task": { - "entry_point": "main", - "package_name": "my_default_python", - "parameters": [ - "--catalog", - "hive_metastore", - "--schema", - "prod" - ] - }, - "task_key": "python_wheel_task" - }, - { - "depends_on": [ - { - "task_key": "notebook_task" - } - ], - "pipeline_task": { - "pipeline_id": "[UUID]" - }, - "task_key": "refresh_pipeline" - } - ], - "trigger": { - "pause_status": "UNPAUSED", - "periodic": { - "interval": 1, - "unit": "DAYS" - } - } - } -} -{ - "method": "PUT", - "path": "/api/2.0/permissions/directories/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - } - ] - } -} -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} -{ - "method": "PUT", - "path": "/api/2.0/permissions/pipelines/[UUID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/templates/default-python/classic/out.requests.prod.direct.txt b/acceptance/bundle/templates/default-python/classic/out.requests.prod.txt similarity index 100% rename from acceptance/bundle/templates/default-python/classic/out.requests.prod.direct.txt rename to acceptance/bundle/templates/default-python/classic/out.requests.prod.txt diff --git a/acceptance/bundle/templates/default-python/classic/out.test.toml b/acceptance/bundle/templates/default-python/classic/out.test.toml index f0134140e64..df52b105a0d 100644 --- a/acceptance/bundle/templates/default-python/classic/out.test.toml +++ b/acceptance/bundle/templates/default-python/classic/out.test.toml @@ -1,5 +1,4 @@ Cloud = false Phase = 1 -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] EnvMatrix.READPLAN = ["", "1"] diff --git a/acceptance/bundle/templates/default-python/classic/script b/acceptance/bundle/templates/default-python/classic/script index ee494960ec9..13726d70cd0 100644 --- a/acceptance/bundle/templates/default-python/classic/script +++ b/acceptance/bundle/templates/default-python/classic/script @@ -7,20 +7,20 @@ trace $CLI bundle validate -t prod trace $CLI bundle plan -t dev trace $CLI bundle plan -t prod -$CLI bundle plan -o json -t dev | nostamp > ../../out.plan_dev.$DATABRICKS_BUNDLE_ENGINE.json -$CLI bundle plan -o json -t prod | nostamp > ../../out.plan_prod.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json -t dev | nostamp > ../../out.plan_dev.json +$CLI bundle plan -o json -t prod | nostamp > ../../out.plan_prod.json rm "$OUT_REQUESTS" # With --plan variant we don't build artifacts, so we can filter out relevant log lines -$CLI bundle deploy -t dev $(readplanarg ../../out.plan_dev.direct.json) 2>&1 | grep -vE '^Building python_artifact|^Uploading .databricks' -print_requests.py --sort '^//import-file/' '^//telemetry-ext' > ../../out.requests.dev.$DATABRICKS_BUNDLE_ENGINE.txt +$CLI bundle deploy -t dev $(readplanarg ../../out.plan_dev.json) 2>&1 | grep -vE '^Building python_artifact|^Uploading .databricks' +print_requests.py --sort '^//import-file/' '^//telemetry-ext' > ../../out.requests.dev.txt trace $CLI bundle plan -t dev # check if if there is drift -trace $CLI bundle plan -t dev -o json | nostamp > ../../out.plan_after_deploy_dev.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -t dev -o json | nostamp > ../../out.plan_after_deploy_dev.json -$CLI bundle deploy -t prod $(readplanarg ../../out.plan_prod.direct.json) 2>&1 | grep -vE '^Building python_artifact|^Uploading dist' -print_requests.py --sort '^//import-file/' '^//telemetry-ext' > ../../out.requests.prod.$DATABRICKS_BUNDLE_ENGINE.txt +$CLI bundle deploy -t prod $(readplanarg ../../out.plan_prod.json) 2>&1 | grep -vE '^Building python_artifact|^Uploading dist' +print_requests.py --sort '^//import-file/' '^//telemetry-ext' > ../../out.requests.prod.txt trace $CLI bundle plan -t prod # check if there is drift -trace $CLI bundle plan -t prod -o json | nostamp > ../../out.plan_after_deploy_prod.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -t prod -o json | nostamp > ../../out.plan_after_deploy_prod.json # Do not affect this repository's git behaviour #2318 mv .gitignore out.gitignore diff --git a/acceptance/bundle/templates/default-python/combinations/classic/out.test.toml b/acceptance/bundle/templates/default-python/combinations/classic/out.test.toml index ec2e3a20680..c63e2f59510 100644 --- a/acceptance/bundle/templates/default-python/combinations/classic/out.test.toml +++ b/acceptance/bundle/templates/default-python/combinations/classic/out.test.toml @@ -1,5 +1,4 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DLT = ["yes", "no"] EnvMatrix.DMS = [""] EnvMatrix.NBOOK = ["yes", "no"] diff --git a/acceptance/bundle/templates/default-python/combinations/serverless/out.test.toml b/acceptance/bundle/templates/default-python/combinations/serverless/out.test.toml index ec2e3a20680..c63e2f59510 100644 --- a/acceptance/bundle/templates/default-python/combinations/serverless/out.test.toml +++ b/acceptance/bundle/templates/default-python/combinations/serverless/out.test.toml @@ -1,5 +1,4 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DLT = ["yes", "no"] EnvMatrix.DMS = [""] EnvMatrix.NBOOK = ["yes", "no"] diff --git a/acceptance/bundle/templates/default-python/fail-missing-uv/out.test.toml b/acceptance/bundle/templates/default-python/fail-missing-uv/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/default-python/fail-missing-uv/out.test.toml +++ b/acceptance/bundle/templates/default-python/fail-missing-uv/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/default-python/integration_classic/out.plan_dev.direct.json b/acceptance/bundle/templates/default-python/integration_classic/out.plan_dev.json similarity index 100% rename from acceptance/bundle/templates/default-python/integration_classic/out.plan_dev.direct.json rename to acceptance/bundle/templates/default-python/integration_classic/out.plan_dev.json diff --git a/acceptance/bundle/templates/default-python/integration_classic/out.plan_dev.terraform.json b/acceptance/bundle/templates/default-python/integration_classic/out.plan_dev.terraform.json deleted file mode 100644 index d9a166852b8..00000000000 --- a/acceptance/bundle/templates/default-python/integration_classic/out.plan_dev.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.sample_job": { - "action": "create" - }, - "resources.pipelines.project_name_[UNIQUE_NAME]_etl": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/templates/default-python/integration_classic/out.plan_prod.direct.json b/acceptance/bundle/templates/default-python/integration_classic/out.plan_prod.json similarity index 100% rename from acceptance/bundle/templates/default-python/integration_classic/out.plan_prod.direct.json rename to acceptance/bundle/templates/default-python/integration_classic/out.plan_prod.json diff --git a/acceptance/bundle/templates/default-python/integration_classic/out.plan_prod.terraform.json b/acceptance/bundle/templates/default-python/integration_classic/out.plan_prod.terraform.json deleted file mode 100644 index 6d3186fa47b..00000000000 --- a/acceptance/bundle/templates/default-python/integration_classic/out.plan_prod.terraform.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.sample_job": { - "action": "create" - }, - "resources.jobs.sample_job.permissions": { - "action": "create" - }, - "resources.pipelines.project_name_[UNIQUE_NAME]_etl": { - "action": "create" - }, - "resources.pipelines.project_name_[UNIQUE_NAME]_etl.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/templates/default-python/integration_classic/out.test.toml b/acceptance/bundle/templates/default-python/integration_classic/out.test.toml index 8767816210c..f80b30b9403 100644 --- a/acceptance/bundle/templates/default-python/integration_classic/out.test.toml +++ b/acceptance/bundle/templates/default-python/integration_classic/out.test.toml @@ -1,5 +1,4 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] EnvMatrix.UV_PYTHON = [ "3.9", diff --git a/acceptance/bundle/templates/default-python/integration_classic/script b/acceptance/bundle/templates/default-python/integration_classic/script index 8e38a196fab..f68e675832c 100644 --- a/acceptance/bundle/templates/default-python/integration_classic/script +++ b/acceptance/bundle/templates/default-python/integration_classic/script @@ -17,7 +17,7 @@ trap "trace $CLI bundle destroy -t dev --auto-approve" EXIT trace $CLI bundle validate -t dev trace $CLI bundle validate -t dev -o json | jq -S "del($JQ_DELETE)" > ../out.validate.dev.json -$CLI bundle plan -o json -t dev | nostamp > ../out.plan_dev.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json -t dev | nostamp > ../out.plan_dev.json trace $CLI bundle deploy -t dev trace $CLI bundle summary -t dev trace $CLI bundle summary -t dev -o json | jq -S "del($JQ_DELETE)" > ../out.summary.dev.json @@ -30,7 +30,7 @@ trace $CLI bundle validate -t prod trace $CLI bundle validate -t prod -o json | jq -S "del($JQ_DELETE)" > ../out.validate.prod.json trace diff.py ../out.validate.dev.json ../out.validate.prod.json rm ../out.validate.prod.json -$CLI bundle plan -o json -t prod | nostamp > ../out.plan_prod.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json -t prod | nostamp > ../out.plan_prod.json trace $CLI bundle deploy -t prod trace $CLI bundle summary -t prod trace $CLI bundle summary -t prod -o json | jq -S "del($JQ_DELETE)" > ../out.summary.prod.json diff --git a/acceptance/bundle/templates/default-python/no-uc/out.test.toml b/acceptance/bundle/templates/default-python/no-uc/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/default-python/no-uc/out.test.toml +++ b/acceptance/bundle/templates/default-python/no-uc/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/default-python/serverless-customcatalog/out.test.toml b/acceptance/bundle/templates/default-python/serverless-customcatalog/out.test.toml index 86234a2fd03..bbd44e1b741 100644 --- a/acceptance/bundle/templates/default-python/serverless-customcatalog/out.test.toml +++ b/acceptance/bundle/templates/default-python/serverless-customcatalog/out.test.toml @@ -1,4 +1,3 @@ Cloud = false Phase = 1 -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/default-python/serverless/out.plan_after_deploy_dev.direct.json b/acceptance/bundle/templates/default-python/serverless/out.plan_after_deploy_dev.json similarity index 100% rename from acceptance/bundle/templates/default-python/serverless/out.plan_after_deploy_dev.direct.json rename to acceptance/bundle/templates/default-python/serverless/out.plan_after_deploy_dev.json diff --git a/acceptance/bundle/templates/default-python/serverless/out.plan_after_deploy_dev.terraform.json b/acceptance/bundle/templates/default-python/serverless/out.plan_after_deploy_dev.terraform.json deleted file mode 100644 index d7b397399cf..00000000000 --- a/acceptance/bundle/templates/default-python/serverless/out.plan_after_deploy_dev.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.sample_job": { - "action": "skip" - }, - "resources.pipelines.my_default_python_etl": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/templates/default-python/serverless/out.plan_after_deploy_prod.direct.json b/acceptance/bundle/templates/default-python/serverless/out.plan_after_deploy_prod.json similarity index 100% rename from acceptance/bundle/templates/default-python/serverless/out.plan_after_deploy_prod.direct.json rename to acceptance/bundle/templates/default-python/serverless/out.plan_after_deploy_prod.json diff --git a/acceptance/bundle/templates/default-python/serverless/out.plan_after_deploy_prod.terraform.json b/acceptance/bundle/templates/default-python/serverless/out.plan_after_deploy_prod.terraform.json deleted file mode 100644 index 6a603440949..00000000000 --- a/acceptance/bundle/templates/default-python/serverless/out.plan_after_deploy_prod.terraform.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.sample_job": { - "action": "skip" - }, - "resources.jobs.sample_job.permissions": { - "action": "skip" - }, - "resources.pipelines.my_default_python_etl": { - "action": "skip" - }, - "resources.pipelines.my_default_python_etl.permissions": { - "action": "skip" - } - } -} diff --git a/acceptance/bundle/templates/default-python/serverless/out.plan_dev.direct.json b/acceptance/bundle/templates/default-python/serverless/out.plan_dev.json similarity index 100% rename from acceptance/bundle/templates/default-python/serverless/out.plan_dev.direct.json rename to acceptance/bundle/templates/default-python/serverless/out.plan_dev.json diff --git a/acceptance/bundle/templates/default-python/serverless/out.plan_dev.terraform.json b/acceptance/bundle/templates/default-python/serverless/out.plan_dev.terraform.json deleted file mode 100644 index 9394f9faeb6..00000000000 --- a/acceptance/bundle/templates/default-python/serverless/out.plan_dev.terraform.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.sample_job": { - "action": "create" - }, - "resources.pipelines.my_default_python_etl": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/templates/default-python/serverless/out.plan_prod.direct.json b/acceptance/bundle/templates/default-python/serverless/out.plan_prod.json similarity index 100% rename from acceptance/bundle/templates/default-python/serverless/out.plan_prod.direct.json rename to acceptance/bundle/templates/default-python/serverless/out.plan_prod.json diff --git a/acceptance/bundle/templates/default-python/serverless/out.plan_prod.terraform.json b/acceptance/bundle/templates/default-python/serverless/out.plan_prod.terraform.json deleted file mode 100644 index dd5e846c557..00000000000 --- a/acceptance/bundle/templates/default-python/serverless/out.plan_prod.terraform.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "cli_version": "[CLI_VERSION]", - "plan": { - "resources.jobs.sample_job": { - "action": "create" - }, - "resources.jobs.sample_job.permissions": { - "action": "create" - }, - "resources.pipelines.my_default_python_etl": { - "action": "create" - }, - "resources.pipelines.my_default_python_etl.permissions": { - "action": "create" - } - } -} diff --git a/acceptance/bundle/templates/default-python/serverless/out.requests.dev.terraform.txt b/acceptance/bundle/templates/default-python/serverless/out.requests.dev.terraform.txt deleted file mode 100644 index a8cf0acc2d5..00000000000 --- a/acceptance/bundle/templates/default-python/serverless/out.requests.dev.terraform.txt +++ /dev/null @@ -1,184 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/pipelines", - "body": { - "catalog": "main", - "channel": "CURRENT", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/state/metadata.json" - }, - "development": true, - "edition": "ADVANCED", - "environment": { - "dependencies": [ - "--editable /Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files" - ] - }, - "libraries": [ - { - "glob": { - "include": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/my_default_python_etl/transformations/**" - } - } - ], - "name": "[dev [USERNAME]] my_default_python_etl", - "root_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/my_default_python_etl", - "schema": "[USERNAME]", - "serverless": true, - "tags": { - "dev": "[USERNAME]" - } - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/delete", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal", - "recursive": true - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/.vscode" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/fixtures" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/resources" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/my_default_python" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/my_default_python_etl/transformations" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/tests" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/state" - } -} -{ - "method": "POST", - "path": "/api/2.2/jobs/create", - "body": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "environments": [ - { - "environment_key": "default", - "spec": { - "dependencies": [ - "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/artifacts/.internal/my_default_python-0.0.1-py3-none-any.whl" - ], - "environment_version": "5" - } - } - ], - "format": "MULTI_TASK", - "max_concurrent_runs": 4, - "name": "[dev [USERNAME]] sample_job", - "parameters": [ - { - "default": "hive_metastore", - "name": "catalog" - }, - { - "default": "[USERNAME]", - "name": "schema" - } - ], - "queue": { - "enabled": true - }, - "tags": { - "dev": "[USERNAME]" - }, - "tasks": [ - { - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/dev/files/src/sample_notebook", - "source": "WORKSPACE" - }, - "task_key": "notebook_task" - }, - { - "depends_on": [ - { - "task_key": "notebook_task" - } - ], - "environment_key": "default", - "python_wheel_task": { - "entry_point": "main", - "package_name": "my_default_python", - "parameters": [ - "--catalog", - "hive_metastore", - "--schema", - "[USERNAME]" - ] - }, - "task_key": "python_wheel_task" - }, - { - "depends_on": [ - { - "task_key": "notebook_task" - } - ], - "pipeline_task": { - "pipeline_id": "[UUID]" - }, - "task_key": "refresh_pipeline" - } - ], - "trigger": { - "pause_status": "PAUSED", - "periodic": { - "interval": 1, - "unit": "DAYS" - } - } - } -} diff --git a/acceptance/bundle/templates/default-python/serverless/out.requests.dev.direct.txt b/acceptance/bundle/templates/default-python/serverless/out.requests.dev.txt similarity index 100% rename from acceptance/bundle/templates/default-python/serverless/out.requests.dev.direct.txt rename to acceptance/bundle/templates/default-python/serverless/out.requests.dev.txt diff --git a/acceptance/bundle/templates/default-python/serverless/out.requests.prod.terraform.txt b/acceptance/bundle/templates/default-python/serverless/out.requests.prod.terraform.txt deleted file mode 100644 index e667d80971d..00000000000 --- a/acceptance/bundle/templates/default-python/serverless/out.requests.prod.terraform.txt +++ /dev/null @@ -1,220 +0,0 @@ -{ - "method": "POST", - "path": "/api/2.0/pipelines", - "body": { - "catalog": "main", - "channel": "CURRENT", - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/state/metadata.json" - }, - "edition": "ADVANCED", - "environment": { - "dependencies": [ - "--editable /Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files" - ] - }, - "libraries": [ - { - "glob": { - "include": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files/src/my_default_python_etl/transformations/**" - } - } - ], - "name": "my_default_python_etl", - "root_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files/src/my_default_python_etl", - "schema": "prod", - "serverless": true - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/delete", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/artifacts/.internal", - "recursive": true - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/delete", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/state/deploy.lock" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/artifacts/.internal" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files/.vscode" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files/fixtures" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files/resources" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files/src/my_default_python" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files/src/my_default_python_etl/transformations" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files/tests" - } -} -{ - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/state" - } -} -{ - "method": "POST", - "path": "/api/2.2/jobs/create", - "body": { - "deployment": { - "kind": "BUNDLE", - "metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/state/metadata.json" - }, - "edit_mode": "UI_LOCKED", - "environments": [ - { - "environment_key": "default", - "spec": { - "dependencies": [ - "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/artifacts/.internal/my_default_python-0.0.1-py3-none-any.whl" - ], - "environment_version": "5" - } - } - ], - "format": "MULTI_TASK", - "max_concurrent_runs": 1, - "name": "sample_job", - "parameters": [ - { - "default": "hive_metastore", - "name": "catalog" - }, - { - "default": "prod", - "name": "schema" - } - ], - "queue": { - "enabled": true - }, - "tasks": [ - { - "notebook_task": { - "notebook_path": "/Workspace/Users/[USERNAME]/.bundle/my_default_python/prod/files/src/sample_notebook", - "source": "WORKSPACE" - }, - "task_key": "notebook_task" - }, - { - "depends_on": [ - { - "task_key": "notebook_task" - } - ], - "environment_key": "default", - "python_wheel_task": { - "entry_point": "main", - "package_name": "my_default_python", - "parameters": [ - "--catalog", - "hive_metastore", - "--schema", - "prod" - ] - }, - "task_key": "python_wheel_task" - }, - { - "depends_on": [ - { - "task_key": "notebook_task" - } - ], - "pipeline_task": { - "pipeline_id": "[UUID]" - }, - "task_key": "refresh_pipeline" - } - ], - "trigger": { - "pause_status": "UNPAUSED", - "periodic": { - "interval": 1, - "unit": "DAYS" - } - } - } -} -{ - "method": "PUT", - "path": "/api/2.0/permissions/directories/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "CAN_MANAGE", - "user_name": "[USERNAME]" - } - ] - } -} -{ - "method": "PUT", - "path": "/api/2.0/permissions/jobs/[NUMID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} -{ - "method": "PUT", - "path": "/api/2.0/permissions/pipelines/[UUID]", - "body": { - "access_control_list": [ - { - "permission_level": "IS_OWNER", - "user_name": "[USERNAME]" - } - ] - } -} diff --git a/acceptance/bundle/templates/default-python/serverless/out.requests.prod.direct.txt b/acceptance/bundle/templates/default-python/serverless/out.requests.prod.txt similarity index 100% rename from acceptance/bundle/templates/default-python/serverless/out.requests.prod.direct.txt rename to acceptance/bundle/templates/default-python/serverless/out.requests.prod.txt diff --git a/acceptance/bundle/templates/default-python/serverless/out.test.toml b/acceptance/bundle/templates/default-python/serverless/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/default-python/serverless/out.test.toml +++ b/acceptance/bundle/templates/default-python/serverless/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/default-python/serverless/script b/acceptance/bundle/templates/default-python/serverless/script index 59230a27880..dc0c328c711 100644 --- a/acceptance/bundle/templates/default-python/serverless/script +++ b/acceptance/bundle/templates/default-python/serverless/script @@ -7,19 +7,19 @@ trace $CLI bundle validate -t prod trace $CLI bundle plan -t dev trace $CLI bundle plan -t prod -$CLI bundle plan -o json -t dev | nostamp > ../../out.plan_dev.$DATABRICKS_BUNDLE_ENGINE.json -$CLI bundle plan -o json -t prod | nostamp > ../../out.plan_prod.$DATABRICKS_BUNDLE_ENGINE.json +$CLI bundle plan -o json -t dev | nostamp > ../../out.plan_dev.json +$CLI bundle plan -o json -t prod | nostamp > ../../out.plan_prod.json rm "$OUT_REQUESTS" trace $CLI bundle deploy -t dev -print_requests.py --sort '^//import-file/' '^//telemetry-ext' > ../../out.requests.dev.$DATABRICKS_BUNDLE_ENGINE.txt +print_requests.py --sort '^//import-file/' '^//telemetry-ext' > ../../out.requests.dev.txt trace $CLI bundle plan -t dev # check if if there is drift -trace $CLI bundle plan -t dev -o json | nostamp > ../../out.plan_after_deploy_dev.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -t dev -o json | nostamp > ../../out.plan_after_deploy_dev.json trace $CLI bundle deploy -t prod -print_requests.py --sort '^//import-file/' '^//telemetry-ext' > ../../out.requests.prod.$DATABRICKS_BUNDLE_ENGINE.txt +print_requests.py --sort '^//import-file/' '^//telemetry-ext' > ../../out.requests.prod.txt trace $CLI bundle plan -t prod # check if there is drift -trace $CLI bundle plan -t prod -o json | nostamp > ../../out.plan_after_deploy_prod.$DATABRICKS_BUNDLE_ENGINE.json +trace $CLI bundle plan -t prod -o json | nostamp > ../../out.plan_after_deploy_prod.json # Do not affect this repository's git behaviour #2318 mv .gitignore out.gitignore diff --git a/acceptance/bundle/templates/default-scala-classic/out.test.toml b/acceptance/bundle/templates/default-scala-classic/out.test.toml index 86234a2fd03..bbd44e1b741 100644 --- a/acceptance/bundle/templates/default-scala-classic/out.test.toml +++ b/acceptance/bundle/templates/default-scala-classic/out.test.toml @@ -1,4 +1,3 @@ Cloud = false Phase = 1 -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/default-scala/out.test.toml b/acceptance/bundle/templates/default-scala/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/default-scala/out.test.toml +++ b/acceptance/bundle/templates/default-scala/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/default-sql-catalog-dash/out.test.toml b/acceptance/bundle/templates/default-sql-catalog-dash/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/default-sql-catalog-dash/out.test.toml +++ b/acceptance/bundle/templates/default-sql-catalog-dash/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/default-sql/out.test.toml b/acceptance/bundle/templates/default-sql/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/default-sql/out.test.toml +++ b/acceptance/bundle/templates/default-sql/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/deployment-history/out.test.toml b/acceptance/bundle/templates/deployment-history/out.test.toml index 9921e91a794..88e6fbd847c 100644 --- a/acceptance/bundle/templates/deployment-history/out.test.toml +++ b/acceptance/bundle/templates/deployment-history/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/templates/deployment-history/test.toml b/acceptance/bundle/templates/deployment-history/test.toml index 3db5cdb90f5..62ba92d2b61 100644 --- a/acceptance/bundle/templates/deployment-history/test.toml +++ b/acceptance/bundle/templates/deployment-history/test.toml @@ -1,6 +1,5 @@ Env.DATABRICKS_BUNDLE_INIT_DEPLOYMENT_HISTORY = "true" # What is under test is what `bundle init` writes, so one engine is enough. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["true"] diff --git a/acceptance/bundle/templates/lakeflow-integrations/out.test.toml b/acceptance/bundle/templates/lakeflow-integrations/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/lakeflow-integrations/out.test.toml +++ b/acceptance/bundle/templates/lakeflow-integrations/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/lakeflow-pipelines/python/out.test.toml b/acceptance/bundle/templates/lakeflow-pipelines/python/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/lakeflow-pipelines/python/out.test.toml +++ b/acceptance/bundle/templates/lakeflow-pipelines/python/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/lakeflow-pipelines/sql/out.test.toml b/acceptance/bundle/templates/lakeflow-pipelines/sql/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/lakeflow-pipelines/sql/out.test.toml +++ b/acceptance/bundle/templates/lakeflow-pipelines/sql/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/nested-output/out.test.toml b/acceptance/bundle/templates/nested-output/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/nested-output/out.test.toml +++ b/acceptance/bundle/templates/nested-output/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/pydabs/check-consistency/out.test.toml b/acceptance/bundle/templates/pydabs/check-consistency/out.test.toml index d063dccb932..60811c86cb4 100644 --- a/acceptance/bundle/templates/pydabs/check-consistency/out.test.toml +++ b/acceptance/bundle/templates/pydabs/check-consistency/out.test.toml @@ -1,5 +1,4 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] EnvMatrix.INCLUDE_JOB = ["yes", "no"] EnvMatrix.INCLUDE_PIPELINE = ["yes", "no"] diff --git a/acceptance/bundle/templates/pydabs/check-formatting/out.test.toml b/acceptance/bundle/templates/pydabs/check-formatting/out.test.toml index d063dccb932..60811c86cb4 100644 --- a/acceptance/bundle/templates/pydabs/check-formatting/out.test.toml +++ b/acceptance/bundle/templates/pydabs/check-formatting/out.test.toml @@ -1,5 +1,4 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] EnvMatrix.INCLUDE_JOB = ["yes", "no"] EnvMatrix.INCLUDE_PIPELINE = ["yes", "no"] diff --git a/acceptance/bundle/templates/pydabs/deploy-classic/out.test.toml b/acceptance/bundle/templates/pydabs/deploy-classic/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/pydabs/deploy-classic/out.test.toml +++ b/acceptance/bundle/templates/pydabs/deploy-classic/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/pydabs/init-classic/out.test.toml b/acceptance/bundle/templates/pydabs/init-classic/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/pydabs/init-classic/out.test.toml +++ b/acceptance/bundle/templates/pydabs/init-classic/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/telemetry/custom-template/out.test.toml b/acceptance/bundle/templates/telemetry/custom-template/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/telemetry/custom-template/out.test.toml +++ b/acceptance/bundle/templates/telemetry/custom-template/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/telemetry/dbt-sql/out.test.toml b/acceptance/bundle/templates/telemetry/dbt-sql/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/telemetry/dbt-sql/out.test.toml +++ b/acceptance/bundle/templates/telemetry/dbt-sql/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/telemetry/default-python/out.test.toml b/acceptance/bundle/templates/telemetry/default-python/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/telemetry/default-python/out.test.toml +++ b/acceptance/bundle/templates/telemetry/default-python/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/templates/telemetry/default-sql/out.test.toml b/acceptance/bundle/templates/telemetry/default-sql/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/templates/telemetry/default-sql/out.test.toml +++ b/acceptance/bundle/templates/telemetry/default-sql/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/test.toml b/acceptance/bundle/test.toml index 1de51b931b9..20200b31ab9 100644 --- a/acceptance/bundle/test.toml +++ b/acceptance/bundle/test.toml @@ -1,16 +1,10 @@ -# This allows recording per-deployment output files, e.g. $CLI bundle deploy > out.$DATABRICKS_BUNDLE_ENGINE.txt -EnvVaryOutput = "DATABRICKS_BUNDLE_ENGINE" - # Runs the whole bundle suite with deployment history recording on, so the deployment metadata -# service (DMS) is exercised by every test rather than only the handful under bundle/dms. Empty -# is the default pair of engine runs. CI gives this variant its own cell ("directdms"), so the -# direct cell still runs each test once; a local run covers both. +# service (DMS) is exercised by every test rather than only the handful under bundle/dms. CI gives +# the DMS=true variant its own cell ("directdms"), so the plain cell still runs each test once; a +# local run covers both. EnvMatrix.DMS = ["", "true"] -# DMS recording is only supported by the direct engine; it is a no-op on terraform. -EnvMatrixExclude.dms_needs_direct = ["DMS=true", "DATABRICKS_BUNDLE_ENGINE=terraform"] - -# The DMS run asserts the same golden files as the engine runs. +# The DMS run asserts the same golden files as the plain run. EnvRepl.DMS = false Ignore = ["databricks.yml"] diff --git a/acceptance/bundle/trampoline/warning_message/out.test.toml b/acceptance/bundle/trampoline/warning_message/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/trampoline/warning_message/out.test.toml +++ b/acceptance/bundle/trampoline/warning_message/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/trampoline/warning_message_with_new_spark/out.test.toml b/acceptance/bundle/trampoline/warning_message_with_new_spark/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/trampoline/warning_message_with_new_spark/out.test.toml +++ b/acceptance/bundle/trampoline/warning_message_with_new_spark/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/trampoline/warning_message_with_old_spark/out.test.toml b/acceptance/bundle/trampoline/warning_message_with_old_spark/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/trampoline/warning_message_with_old_spark/out.test.toml +++ b/acceptance/bundle/trampoline/warning_message_with_old_spark/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/undefined_resources/out.test.toml b/acceptance/bundle/undefined_resources/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/undefined_resources/out.test.toml +++ b/acceptance/bundle/undefined_resources/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/upload/internal_server_error/out.test.toml b/acceptance/bundle/upload/internal_server_error/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/upload/internal_server_error/out.test.toml +++ b/acceptance/bundle/upload/internal_server_error/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/upload/timeout/out.test.toml b/acceptance/bundle/upload/timeout/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/upload/timeout/out.test.toml +++ b/acceptance/bundle/upload/timeout/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/user_agent/out.test.toml b/acceptance/bundle/user_agent/out.test.toml index 86234a2fd03..bbd44e1b741 100644 --- a/acceptance/bundle/user_agent/out.test.toml +++ b/acceptance/bundle/user_agent/out.test.toml @@ -1,4 +1,3 @@ Cloud = false Phase = 1 -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/user_agent/output.txt b/acceptance/bundle/user_agent/output.txt index 318ccc3ff3c..e69de29bb2d 100644 --- a/acceptance/bundle/user_agent/output.txt +++ b/acceptance/bundle/user_agent/output.txt @@ -1,142 +0,0 @@ -MISS deploy.direct /api/2.0/preview/scim/v2/Me 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none auth/pat' -MISS deploy.direct /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none auth/pat' -MISS deploy.direct /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none auth/pat' -OK deploy.direct /api/2.0/workspace/export engine/direct -OK deploy.direct /api/2.0/workspace/export engine/direct -OK deploy.direct /api/2.0/workspace/get-status engine/direct -OK deploy.direct /api/2.0/workspace/get-status engine/direct -OK deploy.direct /api/2.0/workspace/get-status engine/direct -OK deploy.direct /api/2.0/workspace/get-status engine/direct -OK deploy.direct /api/2.0/workspace/get-status engine/direct -OK deploy.direct /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files/empty.py engine/direct -OK deploy.direct /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock engine/direct -OK deploy.direct /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock engine/direct -OK deploy.direct /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deployment.json engine/direct -OK deploy.direct /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json engine/direct -OK deploy.direct /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/resources.json engine/direct -OK deploy.direct /api/2.0/workspace/delete engine/direct -OK deploy.direct /api/2.0/workspace/delete engine/direct -OK deploy.direct /api/2.0/workspace/mkdirs engine/direct -OK deploy.direct /api/2.0/workspace/mkdirs engine/direct -OK deploy.direct /api/2.1/unity-catalog/schemas engine/direct -MISS deploy.direct /.well-known/databricks-config 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]' -MISS deploy.terraform /api/2.0/preview/scim/v2/Me 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none auth/pat' -MISS deploy.terraform /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none auth/pat' -MISS deploy.terraform /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none auth/pat' -OK deploy.terraform /api/2.0/workspace/export engine/terraform -OK deploy.terraform /api/2.0/workspace/export engine/terraform -OK deploy.terraform /api/2.0/workspace/get-status engine/terraform -OK deploy.terraform /api/2.0/workspace/get-status engine/terraform -OK deploy.terraform /api/2.0/workspace/get-status engine/terraform -OK deploy.terraform /api/2.0/workspace/get-status engine/terraform -OK deploy.terraform /api/2.0/workspace/get-status engine/terraform -OK deploy.terraform /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files/empty.py engine/terraform -OK deploy.terraform /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock engine/terraform -OK deploy.terraform /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock engine/terraform -OK deploy.terraform /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deployment.json engine/terraform -OK deploy.terraform /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json engine/terraform -OK deploy.terraform /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/terraform.tfstate engine/terraform -OK deploy.terraform /api/2.0/workspace/delete engine/terraform -OK deploy.terraform /api/2.0/workspace/delete engine/terraform -OK deploy.terraform /api/2.0/workspace/mkdirs engine/terraform -OK deploy.terraform /api/2.0/workspace/mkdirs engine/terraform -MISS deploy.terraform /.well-known/databricks-config 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]' -MISS deploy.terraform /api/2.1/unity-catalog/schemas/mycatalog.myschema 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5 sdk/sdkv2 resource/schema auth/pat' -MISS deploy.terraform /api/2.1/unity-catalog/schemas 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5 sdk/sdkv2 resource/schema auth/pat' -MISS deploy.terraform /.well-known/databricks-config 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5' -MISS deploy.terraform /.well-known/databricks-config 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5' -MISS deploy.terraform /.well-known/databricks-config 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5' -MISS deploy.terraform /.well-known/databricks-config 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5' -MISS destroy.direct /api/2.0/preview/scim/v2/Me 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none auth/pat' -MISS destroy.direct /api/2.0/workspace/export 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none auth/pat' -MISS destroy.direct /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none auth/pat' -MISS destroy.direct /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none auth/pat' -OK destroy.direct /api/2.1/unity-catalog/schemas/mycatalog.myschema engine/direct -OK destroy.direct /api/2.0/workspace/export engine/direct -OK destroy.direct /api/2.0/workspace/get-status engine/direct -OK destroy.direct /api/2.0/workspace/get-status engine/direct -OK destroy.direct /api/2.0/workspace/get-status engine/direct -OK destroy.direct /api/2.1/unity-catalog/schemas/mycatalog.myschema engine/direct -OK destroy.direct /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock engine/direct -OK destroy.direct /api/2.0/workspace/delete engine/direct -OK destroy.direct /api/2.0/workspace/delete engine/direct -MISS destroy.direct /.well-known/databricks-config 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]' -MISS destroy.terraform /api/2.0/preview/scim/v2/Me 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none auth/pat' -MISS destroy.terraform /api/2.0/workspace/export 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none auth/pat' -MISS destroy.terraform /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none auth/pat' -MISS destroy.terraform /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none auth/pat' -OK destroy.terraform /api/2.0/workspace/export engine/terraform -OK destroy.terraform /api/2.0/workspace/get-status engine/terraform -OK destroy.terraform /api/2.0/workspace/get-status engine/terraform -OK destroy.terraform /api/2.0/workspace/get-status engine/terraform -OK destroy.terraform /api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock engine/terraform -OK destroy.terraform /api/2.0/workspace/delete engine/terraform -OK destroy.terraform /api/2.0/workspace/delete engine/terraform -MISS destroy.terraform /.well-known/databricks-config 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]' -MISS destroy.terraform /api/2.1/unity-catalog/schemas/mycatalog.myschema 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5 sdk/sdkv2 resource/schema auth/pat' -MISS destroy.terraform /api/2.1/unity-catalog/current-metastore-assignment 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5 sdk/sdkv2 resource/schema auth/pat' -MISS destroy.terraform /api/2.1/unity-catalog/schemas/mycatalog.myschema 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5 sdk/sdkv2 resource/schema auth/pat' -MISS destroy.terraform /.well-known/databricks-config 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5' -MISS destroy.terraform /.well-known/databricks-config 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5' -MISS destroy.terraform /.well-known/databricks-config 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5' -MISS destroy.terraform /.well-known/databricks-config 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5' -MISS destroy.terraform /.well-known/databricks-config 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5' -MISS destroy.terraform /.well-known/databricks-config 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5' -MISS plan.direct /api/2.0/preview/scim/v2/Me 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat' -MISS plan.direct /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat' -MISS plan.direct /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat' -OK plan.direct /api/2.0/workspace/get-status engine/direct -MISS plan.direct /.well-known/databricks-config 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]' -MISS plan.terraform /api/2.0/preview/scim/v2/Me 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat' -MISS plan.terraform /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat' -MISS plan.terraform /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat' -OK plan.terraform /api/2.0/workspace/get-status engine/terraform -MISS plan.terraform /.well-known/databricks-config 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]' -MISS plan.terraform /.well-known/databricks-config 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5' -MISS plan.terraform /.well-known/databricks-config 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5' -MISS plan2.direct /api/2.0/preview/scim/v2/Me 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat' -MISS plan2.direct /api/2.0/workspace/export 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat' -MISS plan2.direct /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat' -MISS plan2.direct /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat' -OK plan2.direct /api/2.0/workspace/export engine/direct -OK plan2.direct /api/2.0/workspace/get-status engine/direct -OK plan2.direct /api/2.1/unity-catalog/schemas/mycatalog.myschema engine/direct -MISS plan2.direct /.well-known/databricks-config 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]' -MISS plan2.terraform /api/2.0/preview/scim/v2/Me 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat' -MISS plan2.terraform /api/2.0/workspace/export 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat' -MISS plan2.terraform /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat' -MISS plan2.terraform /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat' -OK plan2.terraform /api/2.0/workspace/export engine/terraform -OK plan2.terraform /api/2.0/workspace/get-status engine/terraform -MISS plan2.terraform /.well-known/databricks-config 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]' -MISS plan2.terraform /api/2.1/unity-catalog/schemas/mycatalog.myschema 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5 sdk/sdkv2 resource/schema auth/pat' -MISS plan2.terraform /.well-known/databricks-config 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5' -MISS plan2.terraform /.well-known/databricks-config 'databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5' -MISS run.direct /api/2.0/preview/scim/v2/Me 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_run cmd-exec-id/[UUID] interactive/none auth/pat' -MISS run.direct /api/2.0/workspace/export 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_run cmd-exec-id/[UUID] interactive/none auth/pat' -MISS run.direct /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_run cmd-exec-id/[UUID] interactive/none auth/pat' -MISS run.direct /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_run cmd-exec-id/[UUID] interactive/none auth/pat' -MISS run.direct /.well-known/databricks-config 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]' -MISS run.terraform /api/2.0/preview/scim/v2/Me 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_run cmd-exec-id/[UUID] interactive/none auth/pat' -MISS run.terraform /api/2.0/workspace/export 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_run cmd-exec-id/[UUID] interactive/none auth/pat' -MISS run.terraform /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_run cmd-exec-id/[UUID] interactive/none auth/pat' -MISS run.terraform /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_run cmd-exec-id/[UUID] interactive/none auth/pat' -MISS run.terraform /.well-known/databricks-config 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]' -MISS summary.direct /api/2.0/preview/scim/v2/Me 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_summary cmd-exec-id/[UUID] interactive/none auth/pat' -MISS summary.direct /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_summary cmd-exec-id/[UUID] interactive/none auth/pat' -MISS summary.direct /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_summary cmd-exec-id/[UUID] interactive/none auth/pat' -MISS summary.direct /.well-known/databricks-config 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]' -MISS summary.terraform /api/2.0/preview/scim/v2/Me 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_summary cmd-exec-id/[UUID] interactive/none auth/pat' -MISS summary.terraform /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_summary cmd-exec-id/[UUID] interactive/none auth/pat' -MISS summary.terraform /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_summary cmd-exec-id/[UUID] interactive/none auth/pat' -MISS summary.terraform /.well-known/databricks-config 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]' -MISS validate.direct /api/2.0/preview/scim/v2/Me 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_validate cmd-exec-id/[UUID] interactive/none auth/pat' -MISS validate.direct /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_validate cmd-exec-id/[UUID] interactive/none auth/pat' -MISS validate.direct /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_validate cmd-exec-id/[UUID] interactive/none auth/pat' -MISS validate.direct /api/2.0/workspace/mkdirs 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_validate cmd-exec-id/[UUID] interactive/none auth/pat' -MISS validate.direct /.well-known/databricks-config 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]' -MISS validate.terraform /api/2.0/preview/scim/v2/Me 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_validate cmd-exec-id/[UUID] interactive/none auth/pat' -MISS validate.terraform /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_validate cmd-exec-id/[UUID] interactive/none auth/pat' -MISS validate.terraform /api/2.0/workspace/get-status 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_validate cmd-exec-id/[UUID] interactive/none auth/pat' -MISS validate.terraform /api/2.0/workspace/mkdirs 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_validate cmd-exec-id/[UUID] interactive/none auth/pat' -MISS validate.terraform /.well-known/databricks-config 'cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]' diff --git a/acceptance/bundle/user_agent/simple/out.requests.deploy.direct.json b/acceptance/bundle/user_agent/simple/out.requests.deploy.json similarity index 100% rename from acceptance/bundle/user_agent/simple/out.requests.deploy.direct.json rename to acceptance/bundle/user_agent/simple/out.requests.deploy.json diff --git a/acceptance/bundle/user_agent/simple/out.requests.deploy.terraform.json b/acceptance/bundle/user_agent/simple/out.requests.deploy.terraform.json deleted file mode 100644 index cb67aafe1b4..00000000000 --- a/acceptance/bundle/user_agent/simple/out.requests.deploy.terraform.json +++ /dev/null @@ -1,399 +0,0 @@ -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/preview/scim/v2/Me" -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/resources.json", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/terraform.tfstate", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/export", - "q": { - "direct_download": "true", - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/export", - "q": { - "direct_download": "true", - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deployment.json", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files/empty.py", - "q": { - "overwrite": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock", - "q": { - "overwrite": "false" - }, - "body": { - "ID": "[UUID]", - "AcquisitionTime": "[TIMESTAMP]", - "IsForced": false, - "User": "[USERNAME]" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock", - "q": { - "overwrite": "false" - }, - "body": { - "ID": "[UUID]", - "AcquisitionTime": "[TIMESTAMP]", - "IsForced": false, - "User": "[USERNAME]" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deployment.json", - "q": { - "overwrite": "true" - }, - "body": { - "version": 1, - "seq": 1, - "cli_version": "[CLI_VERSION]", - "timestamp": "[TIMESTAMP]", - "files": [ - { - "local_path": "empty.py", - "is_notebook": false - } - ], - "id": "[UUID]" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json", - "q": { - "overwrite": "true" - }, - "body": { - "version": 1, - "config": { - "bundle": { - "name": "test-bundle", - "target": "default", - "git": { - "bundle_root_path": "." - } - }, - "workspace": { - "file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files" - }, - "resources": {}, - "presets": { - "source_linked_deployment": false - } - }, - "extra": {} - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/terraform.tfstate", - "q": { - "overwrite": "true" - }, - "body": { - "version": 4, - "terraform_version": "1.5.5", - "serial": 1, - "lineage": "[UUID]", - "outputs": {}, - "resources": [ - { - "mode": "managed", - "type": "databricks_schema", - "name": "foo", - "provider": "provider[\"registry.terraform.io/databricks/databricks\"]", - "instances": [ - { - "schema_version": 0, - "attributes": { - "catalog_name": "mycatalog", - "comment": null, - "enable_predictive_optimization": "INHERIT", - "force_destroy": true, - "id": "mycatalog.myschema", - "metastore_id": "[UUID]", - "name": "myschema", - "owner": "[USERNAME]", - "properties": null, - "provider_config": [ - { - "workspace_id": "[NUMID]" - } - ], - "schema_id": "[UUID]", - "storage_root": null - }, - "sensitive_attributes": [], - "private": "bnVsbA==" - } - ] - } - ], - "check_results": null - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.0/workspace/delete", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/artifacts/.internal", - "recursive": true - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.0/workspace/delete", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/artifacts/.internal" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_deploy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5 sdk/sdkv2 resource/schema auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.1/unity-catalog/schemas/mycatalog.myschema" -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5 sdk/sdkv2 resource/schema auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.1/unity-catalog/schemas", - "body": { - "catalog_name": "mycatalog", - "name": "myschema" - } -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} diff --git a/acceptance/bundle/user_agent/simple/out.requests.destroy.direct.json b/acceptance/bundle/user_agent/simple/out.requests.destroy.json similarity index 100% rename from acceptance/bundle/user_agent/simple/out.requests.destroy.direct.json rename to acceptance/bundle/user_agent/simple/out.requests.destroy.json diff --git a/acceptance/bundle/user_agent/simple/out.requests.destroy.terraform.json b/acceptance/bundle/user_agent/simple/out.requests.destroy.terraform.json deleted file mode 100644 index 619c1335fb3..00000000000 --- a/acceptance/bundle/user_agent/simple/out.requests.destroy.terraform.json +++ /dev/null @@ -1,235 +0,0 @@ -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/preview/scim/v2/Me" -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/export", - "q": { - "direct_download": "true", - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/terraform.tfstate" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/resources.json", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/terraform.tfstate", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/export", - "q": { - "direct_download": "true", - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.0/workspace-files/import-file/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deploy.lock", - "q": { - "overwrite": "false" - }, - "body": { - "ID": "[UUID]", - "AcquisitionTime": "[TIMESTAMP]", - "IsForced": false, - "User": "[USERNAME]" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.0/workspace/delete", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_destroy cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.0/workspace/delete", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default", - "recursive": true - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5 sdk/sdkv2 resource/schema auth/pat" - ] - }, - "method": "DELETE", - "path": "/api/2.1/unity-catalog/schemas/mycatalog.myschema", - "q": { - "force": "true" - } -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5 sdk/sdkv2 resource/schema auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.1/unity-catalog/current-metastore-assignment" -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5 sdk/sdkv2 resource/schema auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.1/unity-catalog/schemas/mycatalog.myschema" -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} diff --git a/acceptance/bundle/user_agent/simple/out.requests.plan.direct.json b/acceptance/bundle/user_agent/simple/out.requests.plan.json similarity index 100% rename from acceptance/bundle/user_agent/simple/out.requests.plan.direct.json rename to acceptance/bundle/user_agent/simple/out.requests.plan.json diff --git a/acceptance/bundle/user_agent/simple/out.requests.plan.terraform.json b/acceptance/bundle/user_agent/simple/out.requests.plan.terraform.json deleted file mode 100644 index ba790f18a0a..00000000000 --- a/acceptance/bundle/user_agent/simple/out.requests.plan.terraform.json +++ /dev/null @@ -1,75 +0,0 @@ -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/preview/scim/v2/Me" -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/resources.json", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/terraform.tfstate", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deployment.json", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} diff --git a/acceptance/bundle/user_agent/simple/out.requests.plan2.direct.json b/acceptance/bundle/user_agent/simple/out.requests.plan2.json similarity index 100% rename from acceptance/bundle/user_agent/simple/out.requests.plan2.direct.json rename to acceptance/bundle/user_agent/simple/out.requests.plan2.json diff --git a/acceptance/bundle/user_agent/simple/out.requests.plan2.terraform.json b/acceptance/bundle/user_agent/simple/out.requests.plan2.terraform.json deleted file mode 100644 index d8612181d59..00000000000 --- a/acceptance/bundle/user_agent/simple/out.requests.plan2.terraform.json +++ /dev/null @@ -1,110 +0,0 @@ -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/preview/scim/v2/Me" -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/export", - "q": { - "direct_download": "true", - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/terraform.tfstate" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/resources.json", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/terraform.tfstate", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/export", - "q": { - "direct_download": "true", - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deployment.json" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_plan cmd-exec-id/[UUID] interactive/none engine/terraform auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/deployment.json", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5 sdk/sdkv2 resource/schema auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.1/unity-catalog/schemas/mycatalog.myschema" -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} -{ - "headers": { - "User-Agent": [ - "databricks-tf-provider/[TF_PROVIDER_VERSION] databricks-sdk-go/[SDK_VERSION] go/1.25.8 os/[OS] cli/[CLI_VERSION] terraform/1.5.5" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} diff --git a/acceptance/bundle/user_agent/simple/out.requests.run.direct.json b/acceptance/bundle/user_agent/simple/out.requests.run.json similarity index 100% rename from acceptance/bundle/user_agent/simple/out.requests.run.direct.json rename to acceptance/bundle/user_agent/simple/out.requests.run.json diff --git a/acceptance/bundle/user_agent/simple/out.requests.run.terraform.json b/acceptance/bundle/user_agent/simple/out.requests.run.terraform.json deleted file mode 100644 index fd33d57a70a..00000000000 --- a/acceptance/bundle/user_agent/simple/out.requests.run.terraform.json +++ /dev/null @@ -1,57 +0,0 @@ -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_run cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/preview/scim/v2/Me" -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_run cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/export", - "q": { - "direct_download": "true", - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/terraform.tfstate" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_run cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/resources.json", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_run cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/terraform.tfstate", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} diff --git a/acceptance/bundle/user_agent/simple/out.requests.summary.direct.json b/acceptance/bundle/user_agent/simple/out.requests.summary.json similarity index 100% rename from acceptance/bundle/user_agent/simple/out.requests.summary.direct.json rename to acceptance/bundle/user_agent/simple/out.requests.summary.json diff --git a/acceptance/bundle/user_agent/simple/out.requests.summary.terraform.json b/acceptance/bundle/user_agent/simple/out.requests.summary.terraform.json deleted file mode 100644 index 76cf7173b4f..00000000000 --- a/acceptance/bundle/user_agent/simple/out.requests.summary.terraform.json +++ /dev/null @@ -1,44 +0,0 @@ -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_summary cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/preview/scim/v2/Me" -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_summary cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/resources.json", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_summary cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/terraform.tfstate", - "return_export_info": "true" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} diff --git a/acceptance/bundle/user_agent/simple/out.requests.validate.direct.json b/acceptance/bundle/user_agent/simple/out.requests.validate.json similarity index 100% rename from acceptance/bundle/user_agent/simple/out.requests.validate.direct.json rename to acceptance/bundle/user_agent/simple/out.requests.validate.json diff --git a/acceptance/bundle/user_agent/simple/out.requests.validate.terraform.json b/acceptance/bundle/user_agent/simple/out.requests.validate.terraform.json deleted file mode 100644 index 5750f79f473..00000000000 --- a/acceptance/bundle/user_agent/simple/out.requests.validate.terraform.json +++ /dev/null @@ -1,54 +0,0 @@ -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_validate cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/preview/scim/v2/Me" -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_validate cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_validate cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "GET", - "path": "/api/2.0/workspace/get-status", - "q": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/bundle_validate cmd-exec-id/[UUID] interactive/none auth/pat" - ] - }, - "method": "POST", - "path": "/api/2.0/workspace/mkdirs", - "body": { - "path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/files" - } -} -{ - "headers": { - "User-Agent": [ - "cli/[CLI_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]" - ] - }, - "method": "GET", - "path": "/.well-known/databricks-config" -} diff --git a/acceptance/bundle/user_agent/simple/out.test.toml b/acceptance/bundle/user_agent/simple/out.test.toml index ae800809893..19b5b15d11f 100644 --- a/acceptance/bundle/user_agent/simple/out.test.toml +++ b/acceptance/bundle/user_agent/simple/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = [""] diff --git a/acceptance/bundle/user_agent/simple/script b/acceptance/bundle/user_agent/simple/script index b1458b4a4c5..88f9d90cf81 100644 --- a/acceptance/bundle/user_agent/simple/script +++ b/acceptance/bundle/user_agent/simple/script @@ -1,20 +1,20 @@ trace $CLI bundle validate -trace print_requests.py --sort --get > out.requests.validate.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --sort --get > out.requests.validate.json trace $CLI bundle summary -trace print_requests.py --sort --get > out.requests.summary.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --sort --get > out.requests.summary.json trace $CLI bundle plan -trace print_requests.py --sort --get > out.requests.plan.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --sort --get > out.requests.plan.json trace $CLI bundle deploy -trace print_requests.py --sort --get '^//telemetry-ext' > out.requests.deploy.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --sort --get '^//telemetry-ext' > out.requests.deploy.json trace $CLI bundle plan -trace print_requests.py --sort --get > out.requests.plan2.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --sort --get > out.requests.plan2.json musterr trace $CLI bundle run foo -trace print_requests.py --sort --get > out.requests.run.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --sort --get > out.requests.run.json trace $CLI bundle destroy --auto-approve -trace print_requests.py --sort --get > out.requests.destroy.$DATABRICKS_BUNDLE_ENGINE.json +trace print_requests.py --sort --get > out.requests.destroy.json diff --git a/acceptance/bundle/user_agent/simple/test.toml b/acceptance/bundle/user_agent/simple/test.toml index 70a5e106d9a..a92f32d6760 100644 --- a/acceptance/bundle/user_agent/simple/test.toml +++ b/acceptance/bundle/user_agent/simple/test.toml @@ -1,5 +1,3 @@ RecordRequests = true IncludeRequestHeaders = ["User-Agent"] Ignore = [".databricks"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/bundle/validate/anchor_containers/out.test.toml b/acceptance/bundle/validate/anchor_containers/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/anchor_containers/out.test.toml +++ b/acceptance/bundle/validate/anchor_containers/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/catalog_requires_direct_mode/databricks.yml b/acceptance/bundle/validate/catalog_requires_direct_mode/databricks.yml deleted file mode 100644 index d215964bb77..00000000000 --- a/acceptance/bundle/validate/catalog_requires_direct_mode/databricks.yml +++ /dev/null @@ -1,8 +0,0 @@ -bundle: - name: "catalog_validation_test" - -resources: - catalogs: - test_catalog: - name: "test_catalog" - comment: "This should fail in Terraform mode" diff --git a/acceptance/bundle/validate/catalog_requires_direct_mode/out.test.toml b/acceptance/bundle/validate/catalog_requires_direct_mode/out.test.toml deleted file mode 100644 index 5d0f3e4aac2..00000000000 --- a/acceptance/bundle/validate/catalog_requires_direct_mode/out.test.toml +++ /dev/null @@ -1,3 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] -EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/catalog_requires_direct_mode/output.txt b/acceptance/bundle/validate/catalog_requires_direct_mode/output.txt deleted file mode 100644 index c110f0aa7f9..00000000000 --- a/acceptance/bundle/validate/catalog_requires_direct_mode/output.txt +++ /dev/null @@ -1,8 +0,0 @@ -Error: Catalog resources are only supported with direct deployment mode - in databricks.yml:6:5 - -Catalog resources require direct deployment mode. Please set the DATABRICKS_BUNDLE_ENGINE environment variable to 'direct' or set 'bundle.engine: direct' in your databricks.yml to use catalog resources. -Learn more at https://docs.databricks.com/dev-tools/bundles/direct - - -Exit code: 1 diff --git a/acceptance/bundle/validate/catalog_requires_direct_mode/script b/acceptance/bundle/validate/catalog_requires_direct_mode/script deleted file mode 100755 index b260e836a71..00000000000 --- a/acceptance/bundle/validate/catalog_requires_direct_mode/script +++ /dev/null @@ -1 +0,0 @@ -$CLI bundle plan diff --git a/acceptance/bundle/validate/catalog_requires_direct_mode/test.toml b/acceptance/bundle/validate/catalog_requires_direct_mode/test.toml deleted file mode 100644 index cb048ce6faf..00000000000 --- a/acceptance/bundle/validate/catalog_requires_direct_mode/test.toml +++ /dev/null @@ -1,5 +0,0 @@ -Cloud = false - -Ignore = [".databricks"] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] diff --git a/acceptance/bundle/validate/dashboard_defaults/out.test.toml b/acceptance/bundle/validate/dashboard_defaults/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/dashboard_defaults/out.test.toml +++ b/acceptance/bundle/validate/dashboard_defaults/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/dashboard_required_name/out.test.toml b/acceptance/bundle/validate/dashboard_required_name/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/dashboard_required_name/out.test.toml +++ b/acceptance/bundle/validate/dashboard_required_name/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/dashboard_required_warehouse_id/out.test.toml b/acceptance/bundle/validate/dashboard_required_warehouse_id/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/dashboard_required_warehouse_id/out.test.toml +++ b/acceptance/bundle/validate/dashboard_required_warehouse_id/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/definitions_yaml_anchors/out.test.toml b/acceptance/bundle/validate/definitions_yaml_anchors/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/definitions_yaml_anchors/out.test.toml +++ b/acceptance/bundle/validate/definitions_yaml_anchors/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/duplicate_yaml_merge_key/out.test.toml b/acceptance/bundle/validate/duplicate_yaml_merge_key/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/duplicate_yaml_merge_key/out.test.toml +++ b/acceptance/bundle/validate/duplicate_yaml_merge_key/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/empty_resources/empty_def/out.test.toml b/acceptance/bundle/validate/empty_resources/empty_def/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/empty_resources/empty_def/out.test.toml +++ b/acceptance/bundle/validate/empty_resources/empty_def/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/empty_resources/empty_dict/out.test.toml b/acceptance/bundle/validate/empty_resources/empty_dict/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/empty_resources/empty_dict/out.test.toml +++ b/acceptance/bundle/validate/empty_resources/empty_dict/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/empty_resources/null/out.test.toml b/acceptance/bundle/validate/empty_resources/null/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/empty_resources/null/out.test.toml +++ b/acceptance/bundle/validate/empty_resources/null/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/empty_resources/with_grants/out.test.toml b/acceptance/bundle/validate/empty_resources/with_grants/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/empty_resources/with_grants/out.test.toml +++ b/acceptance/bundle/validate/empty_resources/with_grants/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/empty_resources/with_permissions/out.test.toml b/acceptance/bundle/validate/empty_resources/with_permissions/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/empty_resources/with_permissions/out.test.toml +++ b/acceptance/bundle/validate/empty_resources/with_permissions/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/empty_tasks/out.test.toml b/acceptance/bundle/validate/empty_tasks/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/empty_tasks/out.test.toml +++ b/acceptance/bundle/validate/empty_tasks/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/engine-config-valid/out.test.toml b/acceptance/bundle/validate/engine-config-valid/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/engine-config-valid/out.test.toml +++ b/acceptance/bundle/validate/engine-config-valid/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/engine-config-valid/output.txt b/acceptance/bundle/validate/engine-config-valid/output.txt index 253bb571cd6..c2b0c133643 100644 --- a/acceptance/bundle/validate/engine-config-valid/output.txt +++ b/acceptance/bundle/validate/engine-config-valid/output.txt @@ -9,15 +9,14 @@ Workspace: Validation OK! >>> [CLI] bundle validate -t terraform-target -Warning: the terraform deployment engine is deprecated and will stop working in a future version of the CLI +Error: the Terraform deployment engine has been removed in Databricks CLI v1.19.0 in databricks.yml:10:15 -See https://docs.databricks.com/aws/en/dev-tools/bundles/direct for how to migrate to the direct deployment engine +Remove the "engine" setting (or set it to "direct") to deploy with the direct engine; existing Terraform state is migrated automatically. To keep using Terraform, downgrade to CLI v1.18.x. See https://docs.databricks.com/dev-tools/bundles/direct for details. Name: test-engine-config-valid Target: terraform-target -Workspace: - User: [USERNAME] - Path: /Workspace/Users/[USERNAME]/.bundle/test-engine-config-valid/terraform-target -Found 1 warning +Found 1 error + +Exit code: 1 diff --git a/acceptance/bundle/validate/enum/out.test.toml b/acceptance/bundle/validate/enum/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/enum/out.test.toml +++ b/acceptance/bundle/validate/enum/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/enum_resource_refs/out.test.toml b/acceptance/bundle/validate/enum_resource_refs/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/enum_resource_refs/out.test.toml +++ b/acceptance/bundle/validate/enum_resource_refs/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/genie_space_complex/out.test.toml b/acceptance/bundle/validate/genie_space_complex/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/genie_space_complex/out.test.toml +++ b/acceptance/bundle/validate/genie_space_complex/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/genie_space_defaults/out.test.toml b/acceptance/bundle/validate/genie_space_defaults/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/genie_space_defaults/out.test.toml +++ b/acceptance/bundle/validate/genie_space_defaults/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/genie_space_file_path_and_inline/out.test.toml b/acceptance/bundle/validate/genie_space_file_path_and_inline/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/genie_space_file_path_and_inline/out.test.toml +++ b/acceptance/bundle/validate/genie_space_file_path_and_inline/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/grants_required_principal/out.test.toml b/acceptance/bundle/validate/grants_required_principal/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/validate/grants_required_principal/out.test.toml +++ b/acceptance/bundle/validate/grants_required_principal/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/grants_required_principal/test.toml b/acceptance/bundle/validate/grants_required_principal/test.toml index c9eaec04000..b8dcf0b131e 100644 --- a/acceptance/bundle/validate/grants_required_principal/test.toml +++ b/acceptance/bundle/validate/grants_required_principal/test.toml @@ -1,4 +1,3 @@ RecordRequests = true # Catalogs and schemas are only supported by the direct engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/validate/immutable_workspace_paths/out.test.toml b/acceptance/bundle/validate/immutable_workspace_paths/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/immutable_workspace_paths/out.test.toml +++ b/acceptance/bundle/validate/immutable_workspace_paths/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/include_locations/out.test.toml b/acceptance/bundle/validate/include_locations/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/include_locations/out.test.toml +++ b/acceptance/bundle/validate/include_locations/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/invalid-engine-bundle/out.test.toml b/acceptance/bundle/validate/invalid-engine-bundle/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/invalid-engine-bundle/out.test.toml +++ b/acceptance/bundle/validate/invalid-engine-bundle/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/invalid-engine-bundle/output.txt b/acceptance/bundle/validate/invalid-engine-bundle/output.txt index 8784614498a..e76e18b693b 100644 --- a/acceptance/bundle/validate/invalid-engine-bundle/output.txt +++ b/acceptance/bundle/validate/invalid-engine-bundle/output.txt @@ -1,6 +1,6 @@ >>> [CLI] bundle validate -Error: invalid value "invalid_engine" for bundle.engine (expected "terraform" or "direct") +Error: invalid value "invalid_engine" for bundle.engine (expected "direct") in databricks.yml:3:11 Name: test-engine-config diff --git a/acceptance/bundle/validate/invalid-engine-target/out.test.toml b/acceptance/bundle/validate/invalid-engine-target/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/invalid-engine-target/out.test.toml +++ b/acceptance/bundle/validate/invalid-engine-target/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/invalid-engine-target/output.txt b/acceptance/bundle/validate/invalid-engine-target/output.txt index f0607b47c3e..c44d9dea7b6 100644 --- a/acceptance/bundle/validate/invalid-engine-target/output.txt +++ b/acceptance/bundle/validate/invalid-engine-target/output.txt @@ -1,6 +1,6 @@ >>> [CLI] bundle validate -Error: invalid value "invalid_engine" for bundle.engine (expected "terraform" or "direct") +Error: invalid value "invalid_engine" for bundle.engine (expected "direct") in databricks.yml:7:15 Name: test-engine-config diff --git a/acceptance/bundle/validate/job-references/out.test.toml b/acceptance/bundle/validate/job-references/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/job-references/out.test.toml +++ b/acceptance/bundle/validate/job-references/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/model_serving_both_fields_error/out.test.toml b/acceptance/bundle/validate/model_serving_both_fields_error/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/model_serving_both_fields_error/out.test.toml +++ b/acceptance/bundle/validate/model_serving_both_fields_error/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/model_serving_conversion/out.test.toml b/acceptance/bundle/validate/model_serving_conversion/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/model_serving_conversion/out.test.toml +++ b/acceptance/bundle/validate/model_serving_conversion/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/models/missing_name/out.test.toml b/acceptance/bundle/validate/models/missing_name/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/models/missing_name/out.test.toml +++ b/acceptance/bundle/validate/models/missing_name/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/models/user_id/out.test.toml b/acceptance/bundle/validate/models/user_id/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/models/user_id/out.test.toml +++ b/acceptance/bundle/validate/models/user_id/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/no_dashboard_etag/out.test.toml b/acceptance/bundle/validate/no_dashboard_etag/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/no_dashboard_etag/out.test.toml +++ b/acceptance/bundle/validate/no_dashboard_etag/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/no_genie_space_etag/out.test.toml b/acceptance/bundle/validate/no_genie_space_etag/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/validate/no_genie_space_etag/out.test.toml +++ b/acceptance/bundle/validate/no_genie_space_etag/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/no_genie_space_etag/test.toml b/acceptance/bundle/validate/no_genie_space_etag/test.toml deleted file mode 100644 index d573410a054..00000000000 --- a/acceptance/bundle/validate/no_genie_space_etag/test.toml +++ /dev/null @@ -1,3 +0,0 @@ -# Genie spaces are only supported by the direct deployment engine; under -# terraform the direct-only validation error would diverge the output. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/validate/permissions/out.test.toml b/acceptance/bundle/validate/permissions/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/permissions/out.test.toml +++ b/acceptance/bundle/validate/permissions/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/permissions_overlap/out.test.toml b/acceptance/bundle/validate/permissions_overlap/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/permissions_overlap/out.test.toml +++ b/acceptance/bundle/validate/permissions_overlap/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/presets_max_concurrent_runs/out.test.toml b/acceptance/bundle/validate/presets_max_concurrent_runs/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/presets_max_concurrent_runs/out.test.toml +++ b/acceptance/bundle/validate/presets_max_concurrent_runs/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/presets_name_prefix/out.test.toml b/acceptance/bundle/validate/presets_name_prefix/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/presets_name_prefix/out.test.toml +++ b/acceptance/bundle/validate/presets_name_prefix/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/presets_name_prefix_dev/out.test.toml b/acceptance/bundle/validate/presets_name_prefix_dev/out.test.toml index 59b56a2037c..a927a5fbc06 100644 --- a/acceptance/bundle/validate/presets_name_prefix_dev/out.test.toml +++ b/acceptance/bundle/validate/presets_name_prefix_dev/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/presets_name_prefix_dev/test.toml b/acceptance/bundle/validate/presets_name_prefix_dev/test.toml index b51c615678e..570413a5d19 100644 --- a/acceptance/bundle/validate/presets_name_prefix_dev/test.toml +++ b/acceptance/bundle/validate/presets_name_prefix_dev/test.toml @@ -9,4 +9,3 @@ Badness = "Setting name_prefix to empty string has no effect, setting to nil rai # + } # }, # Disabling terraform since we're not planning or deploying there, one is enough. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/bundle/validate/presets_tags/out.test.toml b/acceptance/bundle/validate/presets_tags/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/presets_tags/out.test.toml +++ b/acceptance/bundle/validate/presets_tags/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/required/out.test.toml b/acceptance/bundle/validate/required/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/required/out.test.toml +++ b/acceptance/bundle/validate/required/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/reserved_deployment_fields/out.test.toml b/acceptance/bundle/validate/reserved_deployment_fields/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/reserved_deployment_fields/out.test.toml +++ b/acceptance/bundle/validate/reserved_deployment_fields/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/reserved_job_run_idempotency_token/out.test.toml b/acceptance/bundle/validate/reserved_job_run_idempotency_token/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/reserved_job_run_idempotency_token/out.test.toml +++ b/acceptance/bundle/validate/reserved_job_run_idempotency_token/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/secret_scope_invalid_permission_level/out.test.toml b/acceptance/bundle/validate/secret_scope_invalid_permission_level/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/secret_scope_invalid_permission_level/out.test.toml +++ b/acceptance/bundle/validate/secret_scope_invalid_permission_level/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/secret_scope_required_principal/out.test.toml b/acceptance/bundle/validate/secret_scope_required_principal/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/secret_scope_required_principal/out.test.toml +++ b/acceptance/bundle/validate/secret_scope_required_principal/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/snapshot_resource_not_allowed/out.test.toml b/acceptance/bundle/validate/snapshot_resource_not_allowed/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/snapshot_resource_not_allowed/out.test.toml +++ b/acceptance/bundle/validate/snapshot_resource_not_allowed/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/sql_warehouse_required_name/out.test.toml b/acceptance/bundle/validate/sql_warehouse_required_name/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/sql_warehouse_required_name/out.test.toml +++ b/acceptance/bundle/validate/sql_warehouse_required_name/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/strict/out.test.toml b/acceptance/bundle/validate/strict/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/strict/out.test.toml +++ b/acceptance/bundle/validate/strict/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/sync_patterns/out.test.toml b/acceptance/bundle/validate/sync_patterns/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/sync_patterns/out.test.toml +++ b/acceptance/bundle/validate/sync_patterns/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/var_in_bundle_name/out.test.toml b/acceptance/bundle/validate/var_in_bundle_name/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/var_in_bundle_name/out.test.toml +++ b/acceptance/bundle/validate/var_in_bundle_name/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/validate/volume_defaults/out.test.toml b/acceptance/bundle/validate/volume_defaults/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/validate/volume_defaults/out.test.toml +++ b/acceptance/bundle/validate/volume_defaults/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/arg-repeat/out.test.toml b/acceptance/bundle/variables/arg-repeat/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/arg-repeat/out.test.toml +++ b/acceptance/bundle/variables/arg-repeat/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/complex-cross-ref/out.test.toml b/acceptance/bundle/variables/complex-cross-ref/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/complex-cross-ref/out.test.toml +++ b/acceptance/bundle/variables/complex-cross-ref/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/complex-cycle-self/out.test.toml b/acceptance/bundle/variables/complex-cycle-self/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/complex-cycle-self/out.test.toml +++ b/acceptance/bundle/variables/complex-cycle-self/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/complex-cycle/out.test.toml b/acceptance/bundle/variables/complex-cycle/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/complex-cycle/out.test.toml +++ b/acceptance/bundle/variables/complex-cycle/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/complex-simple/out.test.toml b/acceptance/bundle/variables/complex-simple/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/complex-simple/out.test.toml +++ b/acceptance/bundle/variables/complex-simple/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/complex-transitive-deep/out.test.toml b/acceptance/bundle/variables/complex-transitive-deep/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/complex-transitive-deep/out.test.toml +++ b/acceptance/bundle/variables/complex-transitive-deep/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/complex-transitive-deeper/out.test.toml b/acceptance/bundle/variables/complex-transitive-deeper/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/complex-transitive-deeper/out.test.toml +++ b/acceptance/bundle/variables/complex-transitive-deeper/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/complex-transitive/out.test.toml b/acceptance/bundle/variables/complex-transitive/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/complex-transitive/out.test.toml +++ b/acceptance/bundle/variables/complex-transitive/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/complex-with-var-reference/out.test.toml b/acceptance/bundle/variables/complex-with-var-reference/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/complex-with-var-reference/out.test.toml +++ b/acceptance/bundle/variables/complex-with-var-reference/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/complex-within-complex/out.test.toml b/acceptance/bundle/variables/complex-within-complex/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/complex-within-complex/out.test.toml +++ b/acceptance/bundle/variables/complex-within-complex/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/complex/out.test.toml b/acceptance/bundle/variables/complex/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/complex/out.test.toml +++ b/acceptance/bundle/variables/complex/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/complex_multiple_files/out.test.toml b/acceptance/bundle/variables/complex_multiple_files/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/complex_multiple_files/out.test.toml +++ b/acceptance/bundle/variables/complex_multiple_files/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/cycle/out.test.toml b/acceptance/bundle/variables/cycle/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/cycle/out.test.toml +++ b/acceptance/bundle/variables/cycle/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/double_underscore/out.test.toml b/acceptance/bundle/variables/double_underscore/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/double_underscore/out.test.toml +++ b/acceptance/bundle/variables/double_underscore/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/empty/out.test.toml b/acceptance/bundle/variables/empty/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/empty/out.test.toml +++ b/acceptance/bundle/variables/empty/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/env_overrides/out.test.toml b/acceptance/bundle/variables/env_overrides/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/env_overrides/out.test.toml +++ b/acceptance/bundle/variables/env_overrides/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/file-defaults/out.test.toml b/acceptance/bundle/variables/file-defaults/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/file-defaults/out.test.toml +++ b/acceptance/bundle/variables/file-defaults/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/git-branch/out.test.toml b/acceptance/bundle/variables/git-branch/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/git-branch/out.test.toml +++ b/acceptance/bundle/variables/git-branch/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/host/out.test.toml b/acceptance/bundle/variables/host/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/host/out.test.toml +++ b/acceptance/bundle/variables/host/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/int/out.test.toml b/acceptance/bundle/variables/int/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/int/out.test.toml +++ b/acceptance/bundle/variables/int/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/issue_2436/out.test.toml b/acceptance/bundle/variables/issue_2436/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/issue_2436/out.test.toml +++ b/acceptance/bundle/variables/issue_2436/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/issue_3039_lookup_with_ref/out.test.toml b/acceptance/bundle/variables/issue_3039_lookup_with_ref/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/issue_3039_lookup_with_ref/out.test.toml +++ b/acceptance/bundle/variables/issue_3039_lookup_with_ref/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/lookup/out.test.toml b/acceptance/bundle/variables/lookup/out.test.toml index cef45fe553a..0f167effef1 100644 --- a/acceptance/bundle/variables/lookup/out.test.toml +++ b/acceptance/bundle/variables/lookup/out.test.toml @@ -1,3 +1,2 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/prepend-workspace-var/out.test.toml b/acceptance/bundle/variables/prepend-workspace-var/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/prepend-workspace-var/out.test.toml +++ b/acceptance/bundle/variables/prepend-workspace-var/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/reference-typo/out.test.toml b/acceptance/bundle/variables/reference-typo/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/reference-typo/out.test.toml +++ b/acceptance/bundle/variables/reference-typo/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/resolve-builtin/out.test.toml b/acceptance/bundle/variables/resolve-builtin/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/resolve-builtin/out.test.toml +++ b/acceptance/bundle/variables/resolve-builtin/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/resolve-empty/out.test.toml b/acceptance/bundle/variables/resolve-empty/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/resolve-empty/out.test.toml +++ b/acceptance/bundle/variables/resolve-empty/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/resolve-field-within-complex/out.test.toml b/acceptance/bundle/variables/resolve-field-within-complex/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/resolve-field-within-complex/out.test.toml +++ b/acceptance/bundle/variables/resolve-field-within-complex/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/resolve-nonstrings/out.test.toml b/acceptance/bundle/variables/resolve-nonstrings/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/resolve-nonstrings/out.test.toml +++ b/acceptance/bundle/variables/resolve-nonstrings/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/resolve-resources-fields/out.test.toml b/acceptance/bundle/variables/resolve-resources-fields/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/resolve-resources-fields/out.test.toml +++ b/acceptance/bundle/variables/resolve-resources-fields/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/resolve-vars-in-root-path/out.test.toml b/acceptance/bundle/variables/resolve-vars-in-root-path/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/resolve-vars-in-root-path/out.test.toml +++ b/acceptance/bundle/variables/resolve-vars-in-root-path/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/unicode_reference/out.test.toml b/acceptance/bundle/variables/unicode_reference/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/unicode_reference/out.test.toml +++ b/acceptance/bundle/variables/unicode_reference/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/vanilla/out.test.toml b/acceptance/bundle/variables/vanilla/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/vanilla/out.test.toml +++ b/acceptance/bundle/variables/vanilla/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/var_in_var/out.test.toml b/acceptance/bundle/variables/var_in_var/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/var_in_var/out.test.toml +++ b/acceptance/bundle/variables/var_in_var/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/variable_in_resource_key/out.test.toml b/acceptance/bundle/variables/variable_in_resource_key/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/variable_in_resource_key/out.test.toml +++ b/acceptance/bundle/variables/variable_in_resource_key/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/variable_overrides_in_target/out.test.toml b/acceptance/bundle/variables/variable_overrides_in_target/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/variable_overrides_in_target/out.test.toml +++ b/acceptance/bundle/variables/variable_overrides_in_target/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/variables/without_definition/out.test.toml b/acceptance/bundle/variables/without_definition/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/variables/without_definition/out.test.toml +++ b/acceptance/bundle/variables/without_definition/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/volume_path/invalid_file/out.test.toml b/acceptance/bundle/volume_path/invalid_file/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/volume_path/invalid_file/out.test.toml +++ b/acceptance/bundle/volume_path/invalid_file/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/volume_path/invalid_resource/out.test.toml b/acceptance/bundle/volume_path/invalid_resource/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/volume_path/invalid_resource/out.test.toml +++ b/acceptance/bundle/volume_path/invalid_resource/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/volume_path/invalid_root/out.test.toml b/acceptance/bundle/volume_path/invalid_root/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/volume_path/invalid_root/out.test.toml +++ b/acceptance/bundle/volume_path/invalid_root/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/volume_path/invalid_state/out.test.toml b/acceptance/bundle/volume_path/invalid_state/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/volume_path/invalid_state/out.test.toml +++ b/acceptance/bundle/volume_path/invalid_state/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/bundle/volume_path/valid/out.test.toml b/acceptance/bundle/volume_path/valid/out.test.toml index e1af1a235ad..a927a5fbc06 100644 --- a/acceptance/bundle/volume_path/valid/out.test.toml +++ b/acceptance/bundle/volume_path/valid/out.test.toml @@ -1,3 +1,2 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.DMS = ["", "true"] diff --git a/acceptance/cache/clear/out.test.toml b/acceptance/cache/clear/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cache/clear/out.test.toml +++ b/acceptance/cache/clear/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cache/simple/out.test.toml b/acceptance/cache/simple/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cache/simple/out.test.toml +++ b/acceptance/cache/simple/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/account/account-help/out.test.toml b/acceptance/cmd/account/account-help/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/account/account-help/out.test.toml +++ b/acceptance/cmd/account/account-help/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/api/account-flag/out.test.toml b/acceptance/cmd/api/account-flag/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/api/account-flag/out.test.toml +++ b/acceptance/cmd/api/account-flag/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/api/account-path/out.test.toml b/acceptance/cmd/api/account-path/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/api/account-path/out.test.toml +++ b/acceptance/cmd/api/account-path/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/api/default-profile-vs-env/out.test.toml b/acceptance/cmd/api/default-profile-vs-env/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/api/default-profile-vs-env/out.test.toml +++ b/acceptance/cmd/api/default-profile-vs-env/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/api/default-profile/out.test.toml b/acceptance/cmd/api/default-profile/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/api/default-profile/out.test.toml +++ b/acceptance/cmd/api/default-profile/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/api/profile-overrides-env/out.test.toml b/acceptance/cmd/api/profile-overrides-env/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/api/profile-overrides-env/out.test.toml +++ b/acceptance/cmd/api/profile-overrides-env/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/api/workspace-id-flag/out.test.toml b/acceptance/cmd/api/workspace-id-flag/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/api/workspace-id-flag/out.test.toml +++ b/acceptance/cmd/api/workspace-id-flag/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/api/workspace-id-from-query/out.test.toml b/acceptance/cmd/api/workspace-id-from-query/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/api/workspace-id-from-query/out.test.toml +++ b/acceptance/cmd/api/workspace-id-from-query/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/api/workspace-id-from-w-query/out.test.toml b/acceptance/cmd/api/workspace-id-from-w-query/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/api/workspace-id-from-w-query/out.test.toml +++ b/acceptance/cmd/api/workspace-id-from-w-query/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/api/workspace-id-none/out.test.toml b/acceptance/cmd/api/workspace-id-none/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/api/workspace-id-none/out.test.toml +++ b/acceptance/cmd/api/workspace-id-none/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/api/workspace-path/out.test.toml b/acceptance/cmd/api/workspace-path/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/api/workspace-path/out.test.toml +++ b/acceptance/cmd/api/workspace-path/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/api/workspace-proxy-regression/out.test.toml b/acceptance/cmd/api/workspace-proxy-regression/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/api/workspace-proxy-regression/out.test.toml +++ b/acceptance/cmd/api/workspace-proxy-regression/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/describe/account-host-with-workspace-id/out.test.toml b/acceptance/cmd/auth/describe/account-host-with-workspace-id/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/describe/account-host-with-workspace-id/out.test.toml +++ b/acceptance/cmd/auth/describe/account-host-with-workspace-id/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/describe/bundle-profile-env/out.test.toml b/acceptance/cmd/auth/describe/bundle-profile-env/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/describe/bundle-profile-env/out.test.toml +++ b/acceptance/cmd/auth/describe/bundle-profile-env/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/describe/default-profile/out.test.toml b/acceptance/cmd/auth/describe/default-profile/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/describe/default-profile/out.test.toml +++ b/acceptance/cmd/auth/describe/default-profile/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/describe/profile-overrides-env/out.test.toml b/acceptance/cmd/auth/describe/profile-overrides-env/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/describe/profile-overrides-env/out.test.toml +++ b/acceptance/cmd/auth/describe/profile-overrides-env/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/describe/u2m-json-output/out.test.toml b/acceptance/cmd/auth/describe/u2m-json-output/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/describe/u2m-json-output/out.test.toml +++ b/acceptance/cmd/auth/describe/u2m-json-output/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/describe/u2m-plaintext-config/out.test.toml b/acceptance/cmd/auth/describe/u2m-plaintext-config/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/describe/u2m-plaintext-config/out.test.toml +++ b/acceptance/cmd/auth/describe/u2m-plaintext-config/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/describe/u2m-plaintext-env/out.test.toml b/acceptance/cmd/auth/describe/u2m-plaintext-env/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/describe/u2m-plaintext-env/out.test.toml +++ b/acceptance/cmd/auth/describe/u2m-plaintext-env/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/describe/u2m-secure-default/out.test.toml b/acceptance/cmd/auth/describe/u2m-secure-default/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/describe/u2m-secure-default/out.test.toml +++ b/acceptance/cmd/auth/describe/u2m-secure-default/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/docker/configure/out.test.toml b/acceptance/cmd/auth/docker/configure/out.test.toml index 4cc2d5fdf7e..2e1543aa802 100644 --- a/acceptance/cmd/auth/docker/configure/out.test.toml +++ b/acceptance/cmd/auth/docker/configure/out.test.toml @@ -1,3 +1,2 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/auth/docker/configure/test.toml b/acceptance/cmd/auth/docker/configure/test.toml index 70f11b847d1..62eac3c38e9 100644 --- a/acceptance/cmd/auth/docker/configure/test.toml +++ b/acceptance/cmd/auth/docker/configure/test.toml @@ -2,7 +2,6 @@ Ignore = [ "home", ] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Timeout = "15s" diff --git a/acceptance/cmd/auth/docker/help/out.test.toml b/acceptance/cmd/auth/docker/help/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/docker/help/out.test.toml +++ b/acceptance/cmd/auth/docker/help/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/docker/token/out.test.toml b/acceptance/cmd/auth/docker/token/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/auth/docker/token/out.test.toml +++ b/acceptance/cmd/auth/docker/token/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/auth/docker/token/test.toml b/acceptance/cmd/auth/docker/token/test.toml index c009f8c8e93..4a369d95c46 100644 --- a/acceptance/cmd/auth/docker/token/test.toml +++ b/acceptance/cmd/auth/docker/token/test.toml @@ -2,6 +2,5 @@ Ignore = [ "home", ] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Timeout = "15s" diff --git a/acceptance/cmd/auth/login/configure-serverless/out.test.toml b/acceptance/cmd/auth/login/configure-serverless/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/login/configure-serverless/out.test.toml +++ b/acceptance/cmd/auth/login/configure-serverless/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/login/custom-config-file/out.test.toml b/acceptance/cmd/auth/login/custom-config-file/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/login/custom-config-file/out.test.toml +++ b/acceptance/cmd/auth/login/custom-config-file/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/login/discovery/out.test.toml b/acceptance/cmd/auth/login/discovery/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/login/discovery/out.test.toml +++ b/acceptance/cmd/auth/login/discovery/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/login/host-arg-overrides-profile/out.test.toml b/acceptance/cmd/auth/login/host-arg-overrides-profile/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/login/host-arg-overrides-profile/out.test.toml +++ b/acceptance/cmd/auth/login/host-arg-overrides-profile/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/login/host-from-profile/out.test.toml b/acceptance/cmd/auth/login/host-from-profile/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/auth/login/host-from-profile/out.test.toml +++ b/acceptance/cmd/auth/login/host-from-profile/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/auth/login/host-from-profile/test.toml b/acceptance/cmd/auth/login/host-from-profile/test.toml index eda89653a0e..84786fa60f0 100644 --- a/acceptance/cmd/auth/login/host-from-profile/test.toml +++ b/acceptance/cmd/auth/login/host-from-profile/test.toml @@ -2,4 +2,3 @@ Ignore = [ "home" ] RecordRequests = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/auth/login/nominal/out.test.toml b/acceptance/cmd/auth/login/nominal/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/login/nominal/out.test.toml +++ b/acceptance/cmd/auth/login/nominal/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/login/preserve-fields/out.test.toml b/acceptance/cmd/auth/login/preserve-fields/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/login/preserve-fields/out.test.toml +++ b/acceptance/cmd/auth/login/preserve-fields/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/login/with-scopes/out.test.toml b/acceptance/cmd/auth/login/with-scopes/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/login/with-scopes/out.test.toml +++ b/acceptance/cmd/auth/login/with-scopes/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/logout/default-profile/out.test.toml b/acceptance/cmd/auth/logout/default-profile/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/logout/default-profile/out.test.toml +++ b/acceptance/cmd/auth/logout/default-profile/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/logout/delete-clears-default/out.test.toml b/acceptance/cmd/auth/logout/delete-clears-default/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/logout/delete-clears-default/out.test.toml +++ b/acceptance/cmd/auth/logout/delete-clears-default/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/logout/delete-pat-token-profile/out.test.toml b/acceptance/cmd/auth/logout/delete-pat-token-profile/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/logout/delete-pat-token-profile/out.test.toml +++ b/acceptance/cmd/auth/logout/delete-pat-token-profile/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/logout/error-cases/out.test.toml b/acceptance/cmd/auth/logout/error-cases/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/logout/error-cases/out.test.toml +++ b/acceptance/cmd/auth/logout/error-cases/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/logout/last-non-default/out.test.toml b/acceptance/cmd/auth/logout/last-non-default/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/logout/last-non-default/out.test.toml +++ b/acceptance/cmd/auth/logout/last-non-default/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/logout/ordering-preserved/out.test.toml b/acceptance/cmd/auth/logout/ordering-preserved/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/logout/ordering-preserved/out.test.toml +++ b/acceptance/cmd/auth/logout/ordering-preserved/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/logout/stale-account-id-workspace-host/out.test.toml b/acceptance/cmd/auth/logout/stale-account-id-workspace-host/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/logout/stale-account-id-workspace-host/out.test.toml +++ b/acceptance/cmd/auth/logout/stale-account-id-workspace-host/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/logout/token-only-shared-host/out.test.toml b/acceptance/cmd/auth/logout/token-only-shared-host/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/logout/token-only-shared-host/out.test.toml +++ b/acceptance/cmd/auth/logout/token-only-shared-host/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/logout/token-only/out.test.toml b/acceptance/cmd/auth/logout/token-only/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/logout/token-only/out.test.toml +++ b/acceptance/cmd/auth/logout/token-only/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/profiles/out.test.toml b/acceptance/cmd/auth/profiles/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/profiles/out.test.toml +++ b/acceptance/cmd/auth/profiles/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/profiles/spog-account/out.test.toml b/acceptance/cmd/auth/profiles/spog-account/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/profiles/spog-account/out.test.toml +++ b/acceptance/cmd/auth/profiles/spog-account/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/storage-modes/env-overrides-config/out.test.toml b/acceptance/cmd/auth/storage-modes/env-overrides-config/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/storage-modes/env-overrides-config/out.test.toml +++ b/acceptance/cmd/auth/storage-modes/env-overrides-config/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/storage-modes/invalid-config/out.test.toml b/acceptance/cmd/auth/storage-modes/invalid-config/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/storage-modes/invalid-config/out.test.toml +++ b/acceptance/cmd/auth/storage-modes/invalid-config/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/storage-modes/invalid-env/out.test.toml b/acceptance/cmd/auth/storage-modes/invalid-env/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/storage-modes/invalid-env/out.test.toml +++ b/acceptance/cmd/auth/storage-modes/invalid-env/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/storage-modes/plaintext-env-default/out.test.toml b/acceptance/cmd/auth/storage-modes/plaintext-env-default/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/storage-modes/plaintext-env-default/out.test.toml +++ b/acceptance/cmd/auth/storage-modes/plaintext-env-default/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/switch/nominal/out.test.toml b/acceptance/cmd/auth/switch/nominal/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/switch/nominal/out.test.toml +++ b/acceptance/cmd/auth/switch/nominal/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/token/default-profile/out.test.toml b/acceptance/cmd/auth/token/default-profile/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/token/default-profile/out.test.toml +++ b/acceptance/cmd/auth/token/default-profile/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/token/force-refresh-invalid-refresh-token/out.test.toml b/acceptance/cmd/auth/token/force-refresh-invalid-refresh-token/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/token/force-refresh-invalid-refresh-token/out.test.toml +++ b/acceptance/cmd/auth/token/force-refresh-invalid-refresh-token/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/token/force-refresh-no-cache/out.test.toml b/acceptance/cmd/auth/token/force-refresh-no-cache/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/token/force-refresh-no-cache/out.test.toml +++ b/acceptance/cmd/auth/token/force-refresh-no-cache/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/token/force-refresh-success/out.test.toml b/acceptance/cmd/auth/token/force-refresh-success/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/token/force-refresh-success/out.test.toml +++ b/acceptance/cmd/auth/token/force-refresh-success/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/token/no-args-no-profiles/out.test.toml b/acceptance/cmd/auth/token/no-args-no-profiles/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/token/no-args-no-profiles/out.test.toml +++ b/acceptance/cmd/auth/token/no-args-no-profiles/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/token/no-args-with-profiles/out.test.toml b/acceptance/cmd/auth/token/no-args-with-profiles/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/token/no-args-with-profiles/out.test.toml +++ b/acceptance/cmd/auth/token/no-args-with-profiles/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/auth/token/out.test.toml b/acceptance/cmd/auth/token/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/auth/token/out.test.toml +++ b/acceptance/cmd/auth/token/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/bundle/dms-read-only/out.test.toml b/acceptance/cmd/bundle/dms-read-only/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/bundle/dms-read-only/out.test.toml +++ b/acceptance/cmd/bundle/dms-read-only/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/bundle/dms-read-only/test.toml b/acceptance/cmd/bundle/dms-read-only/test.toml index 59341412835..a335de6a2e8 100644 --- a/acceptance/cmd/bundle/dms-read-only/test.toml +++ b/acceptance/cmd/bundle/dms-read-only/test.toml @@ -11,7 +11,6 @@ Cloud = false # bundle-deployments is a workspace-service command independent of the bundle # deploy engine, so pin to a single value instead of the inherited matrix so # it runs once (empty list would run on both direct and terraform CI runners). -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # Normalize the git commit SHA so the golden output isn't tied to a specific # commit value. diff --git a/acceptance/cmd/completion/out.test.toml b/acceptance/cmd/completion/out.test.toml index d2059b4b5d7..18b1a88417e 100644 --- a/acceptance/cmd/completion/out.test.toml +++ b/acceptance/cmd/completion/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] diff --git a/acceptance/cmd/completion/test.toml b/acceptance/cmd/completion/test.toml index 4930d2bbcf7..437b34a827f 100644 --- a/acceptance/cmd/completion/test.toml +++ b/acceptance/cmd/completion/test.toml @@ -5,4 +5,3 @@ Ignore = [ Cloud = false # Completion tests don't involve bundles, skip the engine matrix. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] diff --git a/acceptance/cmd/configure/clears-oauth-on-pat/out.test.toml b/acceptance/cmd/configure/clears-oauth-on-pat/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/configure/clears-oauth-on-pat/out.test.toml +++ b/acceptance/cmd/configure/clears-oauth-on-pat/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/configure/clears-serverless-when-cluster-from-env/out.test.toml b/acceptance/cmd/configure/clears-serverless-when-cluster-from-env/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/configure/clears-serverless-when-cluster-from-env/out.test.toml +++ b/acceptance/cmd/configure/clears-serverless-when-cluster-from-env/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/fs/cp/dir-to-dir/out.test.toml b/acceptance/cmd/fs/cp/dir-to-dir/out.test.toml index 2a13818c13f..c7c6f58ed6e 100644 --- a/acceptance/cmd/fs/cp/dir-to-dir/out.test.toml +++ b/acceptance/cmd/fs/cp/dir-to-dir/out.test.toml @@ -1,2 +1 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/fs/cp/file-to-dir/out.test.toml b/acceptance/cmd/fs/cp/file-to-dir/out.test.toml index 2a13818c13f..c7c6f58ed6e 100644 --- a/acceptance/cmd/fs/cp/file-to-dir/out.test.toml +++ b/acceptance/cmd/fs/cp/file-to-dir/out.test.toml @@ -1,2 +1 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/fs/cp/file-to-file/out.test.toml b/acceptance/cmd/fs/cp/file-to-file/out.test.toml index 2a13818c13f..c7c6f58ed6e 100644 --- a/acceptance/cmd/fs/cp/file-to-file/out.test.toml +++ b/acceptance/cmd/fs/cp/file-to-file/out.test.toml @@ -1,2 +1 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/fs/cp/file-to-skill/out.test.toml b/acceptance/cmd/fs/cp/file-to-skill/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/fs/cp/file-to-skill/out.test.toml +++ b/acceptance/cmd/fs/cp/file-to-skill/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/fs/input-validation/out.test.toml b/acceptance/cmd/fs/input-validation/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/fs/input-validation/out.test.toml +++ b/acceptance/cmd/fs/input-validation/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/patchwhl/out.test.toml b/acceptance/cmd/patchwhl/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/patchwhl/out.test.toml +++ b/acceptance/cmd/patchwhl/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/psql/argument-errors/out.test.toml b/acceptance/cmd/psql/argument-errors/out.test.toml index 2adb6d63665..2e1543aa802 100644 --- a/acceptance/cmd/psql/argument-errors/out.test.toml +++ b/acceptance/cmd/psql/argument-errors/out.test.toml @@ -1,3 +1,2 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/psql/completions/out.test.toml b/acceptance/cmd/psql/completions/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/psql/completions/out.test.toml +++ b/acceptance/cmd/psql/completions/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/psql/failing-connection/out.test.toml b/acceptance/cmd/psql/failing-connection/out.test.toml index 2adb6d63665..2e1543aa802 100644 --- a/acceptance/cmd/psql/failing-connection/out.test.toml +++ b/acceptance/cmd/psql/failing-connection/out.test.toml @@ -1,3 +1,2 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/psql/not-available/out.test.toml b/acceptance/cmd/psql/not-available/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/psql/not-available/out.test.toml +++ b/acceptance/cmd/psql/not-available/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/psql/postgres/out.test.toml b/acceptance/cmd/psql/postgres/out.test.toml index 2adb6d63665..2e1543aa802 100644 --- a/acceptance/cmd/psql/postgres/out.test.toml +++ b/acceptance/cmd/psql/postgres/out.test.toml @@ -1,3 +1,2 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/psql/simple/out.test.toml b/acceptance/cmd/psql/simple/out.test.toml index 2adb6d63665..2e1543aa802 100644 --- a/acceptance/cmd/psql/simple/out.test.toml +++ b/acceptance/cmd/psql/simple/out.test.toml @@ -1,3 +1,2 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/sandbox/config/idle-timeout-bounds/out.test.toml b/acceptance/cmd/sandbox/config/idle-timeout-bounds/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/config/idle-timeout-bounds/out.test.toml +++ b/acceptance/cmd/sandbox/config/idle-timeout-bounds/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/config/no-flags/out.test.toml b/acceptance/cmd/sandbox/config/no-flags/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/config/no-flags/out.test.toml +++ b/acceptance/cmd/sandbox/config/no-flags/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/config/update-name/out.test.toml b/acceptance/cmd/sandbox/config/update-name/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/config/update-name/out.test.toml +++ b/acceptance/cmd/sandbox/config/update-name/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/create/with-name/out.test.toml b/acceptance/cmd/sandbox/create/with-name/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/create/with-name/out.test.toml +++ b/acceptance/cmd/sandbox/create/with-name/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/default/not-found/out.test.toml b/acceptance/cmd/sandbox/default/not-found/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/default/not-found/out.test.toml +++ b/acceptance/cmd/sandbox/default/not-found/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/default/set/out.test.toml b/acceptance/cmd/sandbox/default/set/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/default/set/out.test.toml +++ b/acceptance/cmd/sandbox/default/set/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/delete/no-tty-no-auto-approve/out.test.toml b/acceptance/cmd/sandbox/delete/no-tty-no-auto-approve/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/delete/no-tty-no-auto-approve/out.test.toml +++ b/acceptance/cmd/sandbox/delete/no-tty-no-auto-approve/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/delete/not-found/out.test.toml b/acceptance/cmd/sandbox/delete/not-found/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/delete/not-found/out.test.toml +++ b/acceptance/cmd/sandbox/delete/not-found/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/delete/success/out.test.toml b/acceptance/cmd/sandbox/delete/success/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/delete/success/out.test.toml +++ b/acceptance/cmd/sandbox/delete/success/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/list/empty/out.test.toml b/acceptance/cmd/sandbox/list/empty/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/list/empty/out.test.toml +++ b/acceptance/cmd/sandbox/list/empty/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/list/json/out.test.toml b/acceptance/cmd/sandbox/list/json/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/list/json/out.test.toml +++ b/acceptance/cmd/sandbox/list/json/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/list/region-unavailable/out.test.toml b/acceptance/cmd/sandbox/list/region-unavailable/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/list/region-unavailable/out.test.toml +++ b/acceptance/cmd/sandbox/list/region-unavailable/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/list/with-entries/out.test.toml b/acceptance/cmd/sandbox/list/with-entries/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/list/with-entries/out.test.toml +++ b/acceptance/cmd/sandbox/list/with-entries/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/register/success/out.test.toml b/acceptance/cmd/sandbox/register/success/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/register/success/out.test.toml +++ b/acceptance/cmd/sandbox/register/success/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/ssh-key/delete/success/out.test.toml b/acceptance/cmd/sandbox/ssh-key/delete/success/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/ssh-key/delete/success/out.test.toml +++ b/acceptance/cmd/sandbox/ssh-key/delete/success/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/ssh-key/list/empty/out.test.toml b/acceptance/cmd/sandbox/ssh-key/list/empty/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/ssh-key/list/empty/out.test.toml +++ b/acceptance/cmd/sandbox/ssh-key/list/empty/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/ssh-key/list/with-entries/out.test.toml b/acceptance/cmd/sandbox/ssh-key/list/with-entries/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/ssh-key/list/with-entries/out.test.toml +++ b/acceptance/cmd/sandbox/ssh-key/list/with-entries/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/start/already-running/out.test.toml b/acceptance/cmd/sandbox/start/already-running/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/start/already-running/out.test.toml +++ b/acceptance/cmd/sandbox/start/already-running/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/status/json/out.test.toml b/acceptance/cmd/sandbox/status/json/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/status/json/out.test.toml +++ b/acceptance/cmd/sandbox/status/json/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/status/not-found/out.test.toml b/acceptance/cmd/sandbox/status/not-found/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/status/not-found/out.test.toml +++ b/acceptance/cmd/sandbox/status/not-found/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/status/running/out.test.toml b/acceptance/cmd/sandbox/status/running/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/status/running/out.test.toml +++ b/acceptance/cmd/sandbox/status/running/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/stop/success/out.test.toml b/acceptance/cmd/sandbox/stop/success/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/sandbox/stop/success/out.test.toml +++ b/acceptance/cmd/sandbox/stop/success/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sandbox/test.toml b/acceptance/cmd/sandbox/test.toml index d1e2b7f3550..10951253d38 100644 --- a/acceptance/cmd/sandbox/test.toml +++ b/acceptance/cmd/sandbox/test.toml @@ -10,4 +10,3 @@ Ignore = [".databricks", ".ssh"] # test — when they did, they raced each other writing to the same # ~/.databricks/sandbox.json file. An empty list would run once locally # but on both direct and terraform CI runners, defeating the point. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/sync-from-file/out.test.toml b/acceptance/cmd/sync-from-file/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/sync-from-file/out.test.toml +++ b/acceptance/cmd/sync-from-file/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/sync-without-args/out.test.toml b/acceptance/cmd/sync-without-args/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/sync-without-args/out.test.toml +++ b/acceptance/cmd/sync-without-args/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/sync/dryrun-missing-remote/out.test.toml b/acceptance/cmd/sync/dryrun-missing-remote/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/sync/dryrun-missing-remote/out.test.toml +++ b/acceptance/cmd/sync/dryrun-missing-remote/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/sync/dryrun/out.test.toml b/acceptance/cmd/sync/dryrun/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/sync/dryrun/out.test.toml +++ b/acceptance/cmd/sync/dryrun/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/sync/out.test.toml b/acceptance/cmd/sync/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/sync/out.test.toml +++ b/acceptance/cmd/sync/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/unknown-subcommand/out.test.toml b/acceptance/cmd/unknown-subcommand/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/unknown-subcommand/out.test.toml +++ b/acceptance/cmd/unknown-subcommand/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/version/out.test.toml b/acceptance/cmd/version/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/version/out.test.toml +++ b/acceptance/cmd/version/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/version/test.toml b/acceptance/cmd/version/test.toml deleted file mode 100644 index 5321e27a6de..00000000000 --- a/acceptance/cmd/version/test.toml +++ /dev/null @@ -1,2 +0,0 @@ -# The update check is not bundle-aware; run it once instead of per-engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/workspace/apps/out.test.toml b/acceptance/cmd/workspace/apps/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/workspace/apps/out.test.toml +++ b/acceptance/cmd/workspace/apps/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/workspace/apps/run-local-node/out.test.toml b/acceptance/cmd/workspace/apps/run-local-node/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/workspace/apps/run-local-node/out.test.toml +++ b/acceptance/cmd/workspace/apps/run-local-node/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/workspace/apps/run-local-node/test.toml b/acceptance/cmd/workspace/apps/run-local-node/test.toml index 97231a8a677..f46c1e68b26 100644 --- a/acceptance/cmd/workspace/apps/run-local-node/test.toml +++ b/acceptance/cmd/workspace/apps/run-local-node/test.toml @@ -9,4 +9,3 @@ Ignore = [ ] # The command is unrelated to bundle deployment, so run it once rather than per engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/workspace/apps/run-local/out.test.toml b/acceptance/cmd/workspace/apps/run-local/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/workspace/apps/run-local/out.test.toml +++ b/acceptance/cmd/workspace/apps/run-local/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/workspace/apps/run-local/test.toml b/acceptance/cmd/workspace/apps/run-local/test.toml index 5a52f76094d..43720d22644 100644 --- a/acceptance/cmd/workspace/apps/run-local/test.toml +++ b/acceptance/cmd/workspace/apps/run-local/test.toml @@ -2,7 +2,6 @@ Cloud = false RecordRequests = false # The command is unrelated to bundle deployment, so run it once rather than per engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # The ports are registered as replacements by the script, which is where they are allocated. diff --git a/acceptance/cmd/workspace/arg-validation/out.test.toml b/acceptance/cmd/workspace/arg-validation/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/workspace/arg-validation/out.test.toml +++ b/acceptance/cmd/workspace/arg-validation/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/workspace/clusters-list/out.test.toml b/acceptance/cmd/workspace/clusters-list/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/workspace/clusters-list/out.test.toml +++ b/acceptance/cmd/workspace/clusters-list/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/workspace/create-scope/out.test.toml b/acceptance/cmd/workspace/create-scope/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/workspace/create-scope/out.test.toml +++ b/acceptance/cmd/workspace/create-scope/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/workspace/database/update-database-instance/out.test.toml b/acceptance/cmd/workspace/database/update-database-instance/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/workspace/database/update-database-instance/out.test.toml +++ b/acceptance/cmd/workspace/database/update-database-instance/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/workspace/export-dir-dashboard/out.test.toml b/acceptance/cmd/workspace/export-dir-dashboard/out.test.toml index ed21c136c6b..4a2cb2bdbdf 100644 --- a/acceptance/cmd/workspace/export-dir-dashboard/out.test.toml +++ b/acceptance/cmd/workspace/export-dir-dashboard/out.test.toml @@ -1,3 +1,2 @@ Cloud = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/workspace/export-dir-dashboard/test.toml b/acceptance/cmd/workspace/export-dir-dashboard/test.toml index 10eaacadea2..db3893d343c 100644 --- a/acceptance/cmd/workspace/export-dir-dashboard/test.toml +++ b/acceptance/cmd/workspace/export-dir-dashboard/test.toml @@ -5,7 +5,6 @@ Cloud = true # so cover it on Linux/macOS only. GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Ignore = [ "export", ] diff --git a/acceptance/cmd/workspace/export-dir-file-size-limit/out.test.toml b/acceptance/cmd/workspace/export-dir-file-size-limit/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/workspace/export-dir-file-size-limit/out.test.toml +++ b/acceptance/cmd/workspace/export-dir-file-size-limit/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/workspace/export-dir-illegal-filename/posix/out.test.toml b/acceptance/cmd/workspace/export-dir-illegal-filename/posix/out.test.toml index 2adb6d63665..2e1543aa802 100644 --- a/acceptance/cmd/workspace/export-dir-illegal-filename/posix/out.test.toml +++ b/acceptance/cmd/workspace/export-dir-illegal-filename/posix/out.test.toml @@ -1,3 +1,2 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/workspace/export-dir-illegal-filename/windows/out.test.toml b/acceptance/cmd/workspace/export-dir-illegal-filename/windows/out.test.toml index a2974cfce49..fd5293d57d1 100644 --- a/acceptance/cmd/workspace/export-dir-illegal-filename/windows/out.test.toml +++ b/acceptance/cmd/workspace/export-dir-illegal-filename/windows/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.darwin = false GOOS.linux = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/workspace/export-dir-skip-experiments/out.test.toml b/acceptance/cmd/workspace/export-dir-skip-experiments/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/workspace/export-dir-skip-experiments/out.test.toml +++ b/acceptance/cmd/workspace/export-dir-skip-experiments/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/workspace/jobs/runs-submit/out.test.toml b/acceptance/cmd/workspace/jobs/runs-submit/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/cmd/workspace/jobs/runs-submit/out.test.toml +++ b/acceptance/cmd/workspace/jobs/runs-submit/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/workspace/jobs/runs-submit/test.toml b/acceptance/cmd/workspace/jobs/runs-submit/test.toml index 3bb4e32bf10..0ddd580a96a 100644 --- a/acceptance/cmd/workspace/jobs/runs-submit/test.toml +++ b/acceptance/cmd/workspace/jobs/runs-submit/test.toml @@ -3,4 +3,3 @@ Cloud = false RecordRequests = true # This command does not touch the bundle engine; run it once. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/cmd/workspace/put-secret/out.test.toml b/acceptance/cmd/workspace/put-secret/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/workspace/put-secret/out.test.toml +++ b/acceptance/cmd/workspace/put-secret/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/workspace/queries/out.test.toml b/acceptance/cmd/workspace/queries/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/workspace/queries/out.test.toml +++ b/acceptance/cmd/workspace/queries/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/workspace/query-history/out.test.toml b/acceptance/cmd/workspace/query-history/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/workspace/query-history/out.test.toml +++ b/acceptance/cmd/workspace/query-history/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/workspace/secrets/out.test.toml b/acceptance/cmd/workspace/secrets/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/workspace/secrets/out.test.toml +++ b/acceptance/cmd/workspace/secrets/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/cmd/workspace/storage-credentials-list/out.test.toml b/acceptance/cmd/workspace/storage-credentials-list/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/cmd/workspace/storage-credentials-list/out.test.toml +++ b/acceptance/cmd/workspace/storage-credentials-list/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/dbr_runner.py b/acceptance/dbr_runner.py index 1ef40a1f5ea..293821dcca6 100644 --- a/acceptance/dbr_runner.py +++ b/acceptance/dbr_runner.py @@ -193,9 +193,9 @@ def run_tests( # Cloud tests: run with CLOUD_ENV set and workspace access env["CLOUD_ENV"] = cloud_env - # Only tests using direct deployment are run on DBR. - # Terraform based tests are out of scope for DBR. - env["ENVFILTER"] = "DATABRICKS_BUNDLE_ENGINE=direct" + # Bundle tests run under the DMS matrix; DBR covers the non-recording variant + # (the deployment-history variant is exercised elsewhere). + env["ENVFILTER"] = "DMS=" if test_default_warehouse_id: env["TEST_DEFAULT_WAREHOUSE_ID"] = test_default_warehouse_id diff --git a/acceptance/experimental/air/cancel/out.test.toml b/acceptance/experimental/air/cancel/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/air/cancel/out.test.toml +++ b/acceptance/experimental/air/cancel/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/air/config-help/out.test.toml b/acceptance/experimental/air/config-help/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/air/config-help/out.test.toml +++ b/acceptance/experimental/air/config-help/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/air/convert-to-dabs/out.test.toml b/acceptance/experimental/air/convert-to-dabs/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/air/convert-to-dabs/out.test.toml +++ b/acceptance/experimental/air/convert-to-dabs/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/air/get-ai-runtime/out.test.toml b/acceptance/experimental/air/get-ai-runtime/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/air/get-ai-runtime/out.test.toml +++ b/acceptance/experimental/air/get-ai-runtime/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/air/get/out.test.toml b/acceptance/experimental/air/get/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/air/get/out.test.toml +++ b/acceptance/experimental/air/get/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/air/help/out.test.toml b/acceptance/experimental/air/help/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/air/help/out.test.toml +++ b/acceptance/experimental/air/help/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/air/list/out.test.toml b/acceptance/experimental/air/list/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/air/list/out.test.toml +++ b/acceptance/experimental/air/list/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/air/logs-download/out.test.toml b/acceptance/experimental/air/logs-download/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/air/logs-download/out.test.toml +++ b/acceptance/experimental/air/logs-download/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/air/logs-mlflow-fallback/out.test.toml b/acceptance/experimental/air/logs-mlflow-fallback/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/air/logs-mlflow-fallback/out.test.toml +++ b/acceptance/experimental/air/logs-mlflow-fallback/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/air/logs/out.test.toml b/acceptance/experimental/air/logs/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/air/logs/out.test.toml +++ b/acceptance/experimental/air/logs/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/air/pools/out.test.toml b/acceptance/experimental/air/pools/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/air/pools/out.test.toml +++ b/acceptance/experimental/air/pools/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/air/run-submit-databricks-ai/out.test.toml b/acceptance/experimental/air/run-submit-databricks-ai/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/air/run-submit-databricks-ai/out.test.toml +++ b/acceptance/experimental/air/run-submit-databricks-ai/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/air/run-submit-deps/out.test.toml b/acceptance/experimental/air/run-submit-deps/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/air/run-submit-deps/out.test.toml +++ b/acceptance/experimental/air/run-submit-deps/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/air/run-submit-overrides/out.test.toml b/acceptance/experimental/air/run-submit-overrides/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/air/run-submit-overrides/out.test.toml +++ b/acceptance/experimental/air/run-submit-overrides/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/air/run-submit/out.test.toml b/acceptance/experimental/air/run-submit/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/air/run-submit/out.test.toml +++ b/acceptance/experimental/air/run-submit/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/air/run/out.test.toml b/acceptance/experimental/air/run/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/air/run/out.test.toml +++ b/acceptance/experimental/air/run/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/air/test.toml b/acceptance/experimental/air/test.toml deleted file mode 100644 index 050cdfa7eff..00000000000 --- a/acceptance/experimental/air/test.toml +++ /dev/null @@ -1,4 +0,0 @@ -# No air command deploys a bundle, so the engine matrix adds no coverage; pin a -# single engine ("direct") so the air tests run once, not across the direct+terraform -# matrix. (An empty list is rejected: it would run on both runners.) -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/aitools/skills/install-experimental-empty/out.test.toml b/acceptance/experimental/aitools/skills/install-experimental-empty/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/aitools/skills/install-experimental-empty/out.test.toml +++ b/acceptance/experimental/aitools/skills/install-experimental-empty/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/aitools/skills/install-experimental-empty/test.toml b/acceptance/experimental/aitools/skills/install-experimental-empty/test.toml index 96fb36a3e73..515d96f494f 100644 --- a/acceptance/experimental/aitools/skills/install-experimental-empty/test.toml +++ b/acceptance/experimental/aitools/skills/install-experimental-empty/test.toml @@ -5,7 +5,6 @@ Ignore = [ "home", ] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # Stable-only manifest (no repo_dir=experimental). [[Server]] diff --git a/acceptance/experimental/aitools/skills/install-output-json-agent-error/out.test.toml b/acceptance/experimental/aitools/skills/install-output-json-agent-error/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/aitools/skills/install-output-json-agent-error/out.test.toml +++ b/acceptance/experimental/aitools/skills/install-output-json-agent-error/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/aitools/skills/install-output-json-agent-error/test.toml b/acceptance/experimental/aitools/skills/install-output-json-agent-error/test.toml index 5b9c683e75e..2bf6ca2cfec 100644 --- a/acceptance/experimental/aitools/skills/install-output-json-agent-error/test.toml +++ b/acceptance/experimental/aitools/skills/install-output-json-agent-error/test.toml @@ -8,7 +8,6 @@ Ignore = [ ".databricks", ] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] [[Server]] Pattern = "GET /test-ref/manifest.json" diff --git a/acceptance/experimental/aitools/skills/install-output-json-agents-skipped/out.test.toml b/acceptance/experimental/aitools/skills/install-output-json-agents-skipped/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/aitools/skills/install-output-json-agents-skipped/out.test.toml +++ b/acceptance/experimental/aitools/skills/install-output-json-agents-skipped/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/aitools/skills/install-output-json-agents-skipped/test.toml b/acceptance/experimental/aitools/skills/install-output-json-agents-skipped/test.toml index 3cbcdf66fc7..96cb960eefd 100644 --- a/acceptance/experimental/aitools/skills/install-output-json-agents-skipped/test.toml +++ b/acceptance/experimental/aitools/skills/install-output-json-agents-skipped/test.toml @@ -6,5 +6,3 @@ Env.DATABRICKS_SKILLS_REF = "test-ref" Ignore = [ "home", ] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/aitools/skills/install-output-json-error/out.test.toml b/acceptance/experimental/aitools/skills/install-output-json-error/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/aitools/skills/install-output-json-error/out.test.toml +++ b/acceptance/experimental/aitools/skills/install-output-json-error/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/aitools/skills/install-output-json-error/test.toml b/acceptance/experimental/aitools/skills/install-output-json-error/test.toml index edf1106ca21..acbaebdb7d8 100644 --- a/acceptance/experimental/aitools/skills/install-output-json-error/test.toml +++ b/acceptance/experimental/aitools/skills/install-output-json-error/test.toml @@ -6,7 +6,6 @@ Ignore = [ "home", ] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # The manifest has one skill; the script asks for a different one so the resolve # fails with a skill-not-found error. diff --git a/acceptance/experimental/aitools/skills/install-output-json-experimental-error/out.test.toml b/acceptance/experimental/aitools/skills/install-output-json-experimental-error/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/aitools/skills/install-output-json-experimental-error/out.test.toml +++ b/acceptance/experimental/aitools/skills/install-output-json-experimental-error/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/aitools/skills/install-output-json-experimental-error/test.toml b/acceptance/experimental/aitools/skills/install-output-json-experimental-error/test.toml index c7f2d6e3fe1..757ae0c2c6a 100644 --- a/acceptance/experimental/aitools/skills/install-output-json-experimental-error/test.toml +++ b/acceptance/experimental/aitools/skills/install-output-json-experimental-error/test.toml @@ -6,7 +6,6 @@ Ignore = [ "home", ] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # The requested skill is experimental (repo_dir=experimental); the script omits # --experimental so resolution fails before any skill file is fetched. diff --git a/acceptance/experimental/aitools/skills/install-output-json/out.test.toml b/acceptance/experimental/aitools/skills/install-output-json/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/aitools/skills/install-output-json/out.test.toml +++ b/acceptance/experimental/aitools/skills/install-output-json/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/aitools/skills/install-output-json/test.toml b/acceptance/experimental/aitools/skills/install-output-json/test.toml index d5267e964ac..bf121f09f93 100644 --- a/acceptance/experimental/aitools/skills/install-output-json/test.toml +++ b/acceptance/experimental/aitools/skills/install-output-json/test.toml @@ -6,7 +6,6 @@ Ignore = [ "home", ] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] [[Server]] Pattern = "GET /test-ref/manifest.json" diff --git a/acceptance/experimental/aitools/skills/install-specific/out.test.toml b/acceptance/experimental/aitools/skills/install-specific/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/aitools/skills/install-specific/out.test.toml +++ b/acceptance/experimental/aitools/skills/install-specific/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/aitools/skills/install-specific/test.toml b/acceptance/experimental/aitools/skills/install-specific/test.toml index 28aa4f13a8b..ab88e65abe1 100644 --- a/acceptance/experimental/aitools/skills/install-specific/test.toml +++ b/acceptance/experimental/aitools/skills/install-specific/test.toml @@ -5,7 +5,6 @@ Ignore = [ "home", ] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] [[Server]] Pattern = "GET /test-ref/manifest.json" diff --git a/acceptance/experimental/aitools/skills/install/out.test.toml b/acceptance/experimental/aitools/skills/install/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/aitools/skills/install/out.test.toml +++ b/acceptance/experimental/aitools/skills/install/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/aitools/skills/install/test.toml b/acceptance/experimental/aitools/skills/install/test.toml index bfc9d34e3e6..40b564bbcb6 100644 --- a/acceptance/experimental/aitools/skills/install/test.toml +++ b/acceptance/experimental/aitools/skills/install/test.toml @@ -6,7 +6,6 @@ Ignore = [ "home", ] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # Stable + experimental skills via repo_dir. [[Server]] diff --git a/acceptance/experimental/aitools/skills/path-dump/out.test.toml b/acceptance/experimental/aitools/skills/path-dump/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/aitools/skills/path-dump/out.test.toml +++ b/acceptance/experimental/aitools/skills/path-dump/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/aitools/skills/path-dump/test.toml b/acceptance/experimental/aitools/skills/path-dump/test.toml index b5e1bc4d625..64f2120ad6a 100644 --- a/acceptance/experimental/aitools/skills/path-dump/test.toml +++ b/acceptance/experimental/aitools/skills/path-dump/test.toml @@ -7,7 +7,6 @@ Ignore = [ "dumped", ] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] [[Server]] Pattern = "GET /test-ref/manifest.json" diff --git a/acceptance/experimental/aitools/skills/update-prune/out.test.toml b/acceptance/experimental/aitools/skills/update-prune/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/aitools/skills/update-prune/out.test.toml +++ b/acceptance/experimental/aitools/skills/update-prune/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/aitools/skills/update-prune/test.toml b/acceptance/experimental/aitools/skills/update-prune/test.toml index 13ac797b451..45998c6495b 100644 --- a/acceptance/experimental/aitools/skills/update-prune/test.toml +++ b/acceptance/experimental/aitools/skills/update-prune/test.toml @@ -6,7 +6,6 @@ Ignore = [ "home", ] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # Initial release: alpha + beta. [[Server]] diff --git a/acceptance/experimental/genie/ask-deprecated/out.test.toml b/acceptance/experimental/genie/ask-deprecated/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/genie/ask-deprecated/out.test.toml +++ b/acceptance/experimental/genie/ask-deprecated/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/genie/ask-deprecated/test.toml b/acceptance/experimental/genie/ask-deprecated/test.toml index fa19f460549..f21e94bea87 100644 --- a/acceptance/experimental/genie/ask-deprecated/test.toml +++ b/acceptance/experimental/genie/ask-deprecated/test.toml @@ -1,5 +1,4 @@ # No bundle engine needed for this command. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # One canned Genie SSE response covers all invocations in the script. The # stream exercises the full pipeline: a reasoning item, a THOUGHT message, an diff --git a/acceptance/experimental/open/out.test.toml b/acceptance/experimental/open/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/experimental/open/out.test.toml +++ b/acceptance/experimental/open/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/experimental/open/test.toml b/acceptance/experimental/open/test.toml deleted file mode 100644 index 7fd7a8d22a3..00000000000 --- a/acceptance/experimental/open/test.toml +++ /dev/null @@ -1,2 +0,0 @@ -# No bundle engine needed for this command. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/fips/out.test.toml b/acceptance/fips/out.test.toml index c502b28221b..c7c6f58ed6e 100644 --- a/acceptance/fips/out.test.toml +++ b/acceptance/fips/out.test.toml @@ -1,2 +1 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/fips/test.toml b/acceptance/fips/test.toml index 36537d78501..c7c6f58ed6e 100644 --- a/acceptance/fips/test.toml +++ b/acceptance/fips/test.toml @@ -1,2 +1 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Cloud = true diff --git a/acceptance/genie/ask-endpoint-gone/out.test.toml b/acceptance/genie/ask-endpoint-gone/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/genie/ask-endpoint-gone/out.test.toml +++ b/acceptance/genie/ask-endpoint-gone/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/genie/ask-endpoint-gone/test.toml b/acceptance/genie/ask-endpoint-gone/test.toml index 9d92fcfb7a1..5beb1a06288 100644 --- a/acceptance/genie/ask-endpoint-gone/test.toml +++ b/acceptance/genie/ask-endpoint-gone/test.toml @@ -1,5 +1,4 @@ # No bundle engine needed for this command. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # The genie route is an undocumented API that can disappear between releases. # This is the wire shape a live workspace gateway returns for a removed route. diff --git a/acceptance/genie/ask-protocol-drift/out.test.toml b/acceptance/genie/ask-protocol-drift/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/genie/ask-protocol-drift/out.test.toml +++ b/acceptance/genie/ask-protocol-drift/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/genie/ask-protocol-drift/test.toml b/acceptance/genie/ask-protocol-drift/test.toml index d604382b1ca..0f11a3b91d9 100644 --- a/acceptance/genie/ask-protocol-drift/test.toml +++ b/acceptance/genie/ask-protocol-drift/test.toml @@ -1,5 +1,4 @@ # No bundle engine needed for this command. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # A protocol change that renames item types (or moves the answer elsewhere) # leaves the stream syntactically valid but free of anything this build can diff --git a/acceptance/genie/ask-request-drift/out.test.toml b/acceptance/genie/ask-request-drift/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/genie/ask-request-drift/out.test.toml +++ b/acceptance/genie/ask-request-drift/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/genie/ask-request-drift/test.toml b/acceptance/genie/ask-request-drift/test.toml index 952f2fdd918..61eaf11aa91 100644 --- a/acceptance/genie/ask-request-drift/test.toml +++ b/acceptance/genie/ask-request-drift/test.toml @@ -1,5 +1,4 @@ # No bundle engine needed for this command. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # Wire shape observed live when the backend cannot interpret the request body # (e.g. the expected request shape changed): a 500 INTERNAL_ERROR with an diff --git a/acceptance/genie/ask/out.test.toml b/acceptance/genie/ask/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/genie/ask/out.test.toml +++ b/acceptance/genie/ask/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/genie/ask/test.toml b/acceptance/genie/ask/test.toml index fa19f460549..f21e94bea87 100644 --- a/acceptance/genie/ask/test.toml +++ b/acceptance/genie/ask/test.toml @@ -1,5 +1,4 @@ # No bundle engine needed for this command. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # One canned Genie SSE response covers all invocations in the script. The # stream exercises the full pipeline: a reasoning item, a THOUGHT message, an diff --git a/acceptance/help/out.test.toml b/acceptance/help/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/help/out.test.toml +++ b/acceptance/help/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/localenv/bundle-multiple-defaults/out.test.toml b/acceptance/localenv/bundle-multiple-defaults/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/bundle-multiple-defaults/out.test.toml +++ b/acceptance/localenv/bundle-multiple-defaults/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/bundle-multiple-defaults/test.toml b/acceptance/localenv/bundle-multiple-defaults/test.toml index 270ce8c5b79..6cdc69ce912 100644 --- a/acceptance/localenv/bundle-multiple-defaults/test.toml +++ b/acceptance/localenv/bundle-multiple-defaults/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] [[Repls]] Old = 'uv uv \S+(?: \([^)]+\))?' diff --git a/acceptance/localenv/cluster-name-ambiguous-json/out.test.toml b/acceptance/localenv/cluster-name-ambiguous-json/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/cluster-name-ambiguous-json/out.test.toml +++ b/acceptance/localenv/cluster-name-ambiguous-json/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/cluster-name-ambiguous-json/test.toml b/acceptance/localenv/cluster-name-ambiguous-json/test.toml index d69a0c990d0..6b79c255ba9 100644 --- a/acceptance/localenv/cluster-name-ambiguous-json/test.toml +++ b/acceptance/localenv/cluster-name-ambiguous-json/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Env.DATABRICKS_LOCALENV_CONSTRAINT_SOURCE_URL_TEST_OVERRIDE = "$DATABRICKS_HOST" # Two active clusters share the same name, so name→ID resolution is genuinely diff --git a/acceptance/localenv/cluster-name-ambiguous/out.test.toml b/acceptance/localenv/cluster-name-ambiguous/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/cluster-name-ambiguous/out.test.toml +++ b/acceptance/localenv/cluster-name-ambiguous/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/cluster-name-ambiguous/test.toml b/acceptance/localenv/cluster-name-ambiguous/test.toml index d69a0c990d0..6b79c255ba9 100644 --- a/acceptance/localenv/cluster-name-ambiguous/test.toml +++ b/acceptance/localenv/cluster-name-ambiguous/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Env.DATABRICKS_LOCALENV_CONSTRAINT_SOURCE_URL_TEST_OVERRIDE = "$DATABRICKS_HOST" # Two active clusters share the same name, so name→ID resolution is genuinely diff --git a/acceptance/localenv/cluster-name-check/out.test.toml b/acceptance/localenv/cluster-name-check/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/cluster-name-check/out.test.toml +++ b/acceptance/localenv/cluster-name-check/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/cluster-name-check/test.toml b/acceptance/localenv/cluster-name-check/test.toml index a0f17ee518a..ecf35b65809 100644 --- a/acceptance/localenv/cluster-name-check/test.toml +++ b/acceptance/localenv/cluster-name-check/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Env.DATABRICKS_LOCALENV_CONSTRAINT_SOURCE_URL_TEST_OVERRIDE = "$DATABRICKS_HOST" # --cluster-name resolves the name to an ID via the Clusters API (which lists diff --git a/acceptance/localenv/cluster-name-unknown/out.test.toml b/acceptance/localenv/cluster-name-unknown/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/cluster-name-unknown/out.test.toml +++ b/acceptance/localenv/cluster-name-unknown/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/cluster-name-unknown/test.toml b/acceptance/localenv/cluster-name-unknown/test.toml index da85e63edd4..5f6ca888909 100644 --- a/acceptance/localenv/cluster-name-unknown/test.toml +++ b/acceptance/localenv/cluster-name-unknown/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Env.DATABRICKS_LOCALENV_CONSTRAINT_SOURCE_URL_TEST_OVERRIDE = "$DATABRICKS_HOST" # No active cluster matches the requested name, so name→ID resolution finds diff --git a/acceptance/localenv/cluster-stale-environment/out.test.toml b/acceptance/localenv/cluster-stale-environment/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/cluster-stale-environment/out.test.toml +++ b/acceptance/localenv/cluster-stale-environment/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/cluster-stale-environment/test.toml b/acceptance/localenv/cluster-stale-environment/test.toml index 8690b410241..8941a273e66 100644 --- a/acceptance/localenv/cluster-stale-environment/test.toml +++ b/acceptance/localenv/cluster-stale-environment/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # The script writes pyproject.toml as the merge input; --dry-run leaves it unchanged. Ignore = ["pyproject.toml"] diff --git a/acceptance/localenv/constraints-only-existing/out.test.toml b/acceptance/localenv/constraints-only-existing/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/constraints-only-existing/out.test.toml +++ b/acceptance/localenv/constraints-only-existing/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/constraints-only-existing/test.toml b/acceptance/localenv/constraints-only-existing/test.toml index 6377a54fca8..31e5ce1777b 100644 --- a/acceptance/localenv/constraints-only-existing/test.toml +++ b/acceptance/localenv/constraints-only-existing/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # The script writes pyproject.toml as the merge input; --dry-run leaves it unchanged. Ignore = ["pyproject.toml"] diff --git a/acceptance/localenv/constraints-only/out.test.toml b/acceptance/localenv/constraints-only/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/constraints-only/out.test.toml +++ b/acceptance/localenv/constraints-only/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/constraints-only/test.toml b/acceptance/localenv/constraints-only/test.toml index 467508f4a03..feeb4e72a56 100644 --- a/acceptance/localenv/constraints-only/test.toml +++ b/acceptance/localenv/constraints-only/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Env.DATABRICKS_LOCALENV_CONSTRAINT_SOURCE_URL_TEST_OVERRIDE = "$DATABRICKS_HOST" diff --git a/acceptance/localenv/dbconnect-compatible-kept-check/out.test.toml b/acceptance/localenv/dbconnect-compatible-kept-check/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/dbconnect-compatible-kept-check/out.test.toml +++ b/acceptance/localenv/dbconnect-compatible-kept-check/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/dbconnect-compatible-kept-check/test.toml b/acceptance/localenv/dbconnect-compatible-kept-check/test.toml index 70bc85b6550..34c9b65811f 100644 --- a/acceptance/localenv/dbconnect-compatible-kept-check/test.toml +++ b/acceptance/localenv/dbconnect-compatible-kept-check/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # The script writes pyproject.toml as the merge input; --dry-run leaves it unchanged. Ignore = ["pyproject.toml"] diff --git a/acceptance/localenv/dbconnect-consolidate-check/out.test.toml b/acceptance/localenv/dbconnect-consolidate-check/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/dbconnect-consolidate-check/out.test.toml +++ b/acceptance/localenv/dbconnect-consolidate-check/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/dbconnect-consolidate-check/test.toml b/acceptance/localenv/dbconnect-consolidate-check/test.toml index 70bc85b6550..34c9b65811f 100644 --- a/acceptance/localenv/dbconnect-consolidate-check/test.toml +++ b/acceptance/localenv/dbconnect-consolidate-check/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # The script writes pyproject.toml as the merge input; --dry-run leaves it unchanged. Ignore = ["pyproject.toml"] diff --git a/acceptance/localenv/env-unsupported/out.test.toml b/acceptance/localenv/env-unsupported/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/env-unsupported/out.test.toml +++ b/acceptance/localenv/env-unsupported/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/env-unsupported/test.toml b/acceptance/localenv/env-unsupported/test.toml index 55541025a53..6e04f655792 100644 --- a/acceptance/localenv/env-unsupported/test.toml +++ b/acceptance/localenv/env-unsupported/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Env.DATABRICKS_LOCALENV_CONSTRAINT_SOURCE_URL_TEST_OVERRIDE = "$DATABRICKS_HOST" diff --git a/acceptance/localenv/flag-conflict-json/out.test.toml b/acceptance/localenv/flag-conflict-json/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/flag-conflict-json/out.test.toml +++ b/acceptance/localenv/flag-conflict-json/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/flag-conflict-json/test.toml b/acceptance/localenv/flag-conflict-json/test.toml deleted file mode 100644 index 9609e1af299..00000000000 --- a/acceptance/localenv/flag-conflict-json/test.toml +++ /dev/null @@ -1 +0,0 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/flag-conflict/out.test.toml b/acceptance/localenv/flag-conflict/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/flag-conflict/out.test.toml +++ b/acceptance/localenv/flag-conflict/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/flag-conflict/test.toml b/acceptance/localenv/flag-conflict/test.toml deleted file mode 100644 index 9609e1af299..00000000000 --- a/acceptance/localenv/flag-conflict/test.toml +++ /dev/null @@ -1 +0,0 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/group-help/out.test.toml b/acceptance/localenv/group-help/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/group-help/out.test.toml +++ b/acceptance/localenv/group-help/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/group-help/test.toml b/acceptance/localenv/group-help/test.toml deleted file mode 100644 index 9609e1af299..00000000000 --- a/acceptance/localenv/group-help/test.toml +++ /dev/null @@ -1 +0,0 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/help/out.test.toml b/acceptance/localenv/help/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/help/out.test.toml +++ b/acceptance/localenv/help/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/help/test.toml b/acceptance/localenv/help/test.toml deleted file mode 100644 index 9609e1af299..00000000000 --- a/acceptance/localenv/help/test.toml +++ /dev/null @@ -1 +0,0 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/job-classic-check/out.test.toml b/acceptance/localenv/job-classic-check/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/job-classic-check/out.test.toml +++ b/acceptance/localenv/job-classic-check/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/job-classic-check/test.toml b/acceptance/localenv/job-classic-check/test.toml index e47f005c445..c3ee8d7cd83 100644 --- a/acceptance/localenv/job-classic-check/test.toml +++ b/acceptance/localenv/job-classic-check/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Env.DATABRICKS_LOCALENV_CONSTRAINT_SOURCE_URL_TEST_OVERRIDE = "$DATABRICKS_HOST" # A classic task carries its own new_cluster, so --job-task . diff --git a/acceptance/localenv/job-serverless-check/out.test.toml b/acceptance/localenv/job-serverless-check/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/job-serverless-check/out.test.toml +++ b/acceptance/localenv/job-serverless-check/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/job-serverless-check/test.toml b/acceptance/localenv/job-serverless-check/test.toml index 55d7b2cc913..e0fe5880549 100644 --- a/acceptance/localenv/job-serverless-check/test.toml +++ b/acceptance/localenv/job-serverless-check/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Env.DATABRICKS_LOCALENV_CONSTRAINT_SOURCE_URL_TEST_OVERRIDE = "$DATABRICKS_HOST" # A serverless task binds an environment_key to one of the job's environments; diff --git a/acceptance/localenv/job-task-foreach/out.test.toml b/acceptance/localenv/job-task-foreach/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/job-task-foreach/out.test.toml +++ b/acceptance/localenv/job-task-foreach/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/job-task-foreach/test.toml b/acceptance/localenv/job-task-foreach/test.toml index e234b7b7954..dd852f14aac 100644 --- a/acceptance/localenv/job-task-foreach/test.toml +++ b/acceptance/localenv/job-task-foreach/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Env.DATABRICKS_LOCALENV_CONSTRAINT_SOURCE_URL_TEST_OVERRIDE = "$DATABRICKS_HOST" # A for_each_task wraps the real per-iteration task; its compute lives on the diff --git a/acceptance/localenv/job-task-jobcluster/out.test.toml b/acceptance/localenv/job-task-jobcluster/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/job-task-jobcluster/out.test.toml +++ b/acceptance/localenv/job-task-jobcluster/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/job-task-jobcluster/test.toml b/acceptance/localenv/job-task-jobcluster/test.toml index 014f5fcc69c..753df232e84 100644 --- a/acceptance/localenv/job-task-jobcluster/test.toml +++ b/acceptance/localenv/job-task-jobcluster/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Env.DATABRICKS_LOCALENV_CONSTRAINT_SOURCE_URL_TEST_OVERRIDE = "$DATABRICKS_HOST" # A classic task references a shared job cluster by job_cluster_key (rather than diff --git a/acceptance/localenv/job-task-missing-key/out.test.toml b/acceptance/localenv/job-task-missing-key/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/job-task-missing-key/out.test.toml +++ b/acceptance/localenv/job-task-missing-key/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/job-task-missing-key/test.toml b/acceptance/localenv/job-task-missing-key/test.toml index 86bb5bbe32d..cd694dfae62 100644 --- a/acceptance/localenv/job-task-missing-key/test.toml +++ b/acceptance/localenv/job-task-missing-key/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Env.DATABRICKS_LOCALENV_CONSTRAINT_SOURCE_URL_TEST_OVERRIDE = "$DATABRICKS_HOST" # A bare --job-task (no .) is a usage error: a job can bind diff --git a/acceptance/localenv/job-task-unknown/out.test.toml b/acceptance/localenv/job-task-unknown/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/job-task-unknown/out.test.toml +++ b/acceptance/localenv/job-task-unknown/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/job-task-unknown/test.toml b/acceptance/localenv/job-task-unknown/test.toml index 656816ba6fb..32f67968069 100644 --- a/acceptance/localenv/job-task-unknown/test.toml +++ b/acceptance/localenv/job-task-unknown/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Env.DATABRICKS_LOCALENV_CONSTRAINT_SOURCE_URL_TEST_OVERRIDE = "$DATABRICKS_HOST" # A --job-task naming a task key that the job does not define fails at resolve diff --git a/acceptance/localenv/job-task-unpinned/out.test.toml b/acceptance/localenv/job-task-unpinned/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/job-task-unpinned/out.test.toml +++ b/acceptance/localenv/job-task-unpinned/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/job-task-unpinned/test.toml b/acceptance/localenv/job-task-unpinned/test.toml index ea1b41df134..7b3e5e8b455 100644 --- a/acceptance/localenv/job-task-unpinned/test.toml +++ b/acceptance/localenv/job-task-unpinned/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Env.DATABRICKS_LOCALENV_CONSTRAINT_SOURCE_URL_TEST_OVERRIDE = "$DATABRICKS_HOST" # A task whose bound serverless environment records no version cannot be resolved: diff --git a/acceptance/localenv/json-error/out.test.toml b/acceptance/localenv/json-error/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/json-error/out.test.toml +++ b/acceptance/localenv/json-error/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/json-error/test.toml b/acceptance/localenv/json-error/test.toml index 270ce8c5b79..6cdc69ce912 100644 --- a/acceptance/localenv/json-error/test.toml +++ b/acceptance/localenv/json-error/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] [[Repls]] Old = 'uv uv \S+(?: \([^)]+\))?' diff --git a/acceptance/localenv/manager-unsupported/out.test.toml b/acceptance/localenv/manager-unsupported/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/manager-unsupported/out.test.toml +++ b/acceptance/localenv/manager-unsupported/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/manager-unsupported/test.toml b/acceptance/localenv/manager-unsupported/test.toml index 270ce8c5b79..6cdc69ce912 100644 --- a/acceptance/localenv/manager-unsupported/test.toml +++ b/acceptance/localenv/manager-unsupported/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] [[Repls]] Old = 'uv uv \S+(?: \([^)]+\))?' diff --git a/acceptance/localenv/merge-warnings-json/out.test.toml b/acceptance/localenv/merge-warnings-json/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/merge-warnings-json/out.test.toml +++ b/acceptance/localenv/merge-warnings-json/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/merge-warnings-json/test.toml b/acceptance/localenv/merge-warnings-json/test.toml index 2662654e4a9..5a4bb9fc095 100644 --- a/acceptance/localenv/merge-warnings-json/test.toml +++ b/acceptance/localenv/merge-warnings-json/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # The script writes pyproject.toml as the merge input; --dry-run leaves it unchanged. Ignore = ["pyproject.toml"] diff --git a/acceptance/localenv/merge-warnings/out.test.toml b/acceptance/localenv/merge-warnings/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/merge-warnings/out.test.toml +++ b/acceptance/localenv/merge-warnings/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/merge-warnings/test.toml b/acceptance/localenv/merge-warnings/test.toml index 2662654e4a9..5a4bb9fc095 100644 --- a/acceptance/localenv/merge-warnings/test.toml +++ b/acceptance/localenv/merge-warnings/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # The script writes pyproject.toml as the merge input; --dry-run leaves it unchanged. Ignore = ["pyproject.toml"] diff --git a/acceptance/localenv/no-constraints/out.test.toml b/acceptance/localenv/no-constraints/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/no-constraints/out.test.toml +++ b/acceptance/localenv/no-constraints/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/no-constraints/test.toml b/acceptance/localenv/no-constraints/test.toml index 6377a54fca8..31e5ce1777b 100644 --- a/acceptance/localenv/no-constraints/test.toml +++ b/acceptance/localenv/no-constraints/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # The script writes pyproject.toml as the merge input; --dry-run leaves it unchanged. Ignore = ["pyproject.toml"] diff --git a/acceptance/localenv/no-dbconnect/out.test.toml b/acceptance/localenv/no-dbconnect/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/no-dbconnect/out.test.toml +++ b/acceptance/localenv/no-dbconnect/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/no-dbconnect/test.toml b/acceptance/localenv/no-dbconnect/test.toml index 6377a54fca8..31e5ce1777b 100644 --- a/acceptance/localenv/no-dbconnect/test.toml +++ b/acceptance/localenv/no-dbconnect/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # The script writes pyproject.toml as the merge input; --dry-run leaves it unchanged. Ignore = ["pyproject.toml"] diff --git a/acceptance/localenv/no-target/out.test.toml b/acceptance/localenv/no-target/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/no-target/out.test.toml +++ b/acceptance/localenv/no-target/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/no-target/test.toml b/acceptance/localenv/no-target/test.toml index 270ce8c5b79..6cdc69ce912 100644 --- a/acceptance/localenv/no-target/test.toml +++ b/acceptance/localenv/no-target/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] [[Repls]] Old = 'uv uv \S+(?: \([^)]+\))?' diff --git a/acceptance/localenv/provision-conflict-sync/out.test.toml b/acceptance/localenv/provision-conflict-sync/out.test.toml index 4cc2d5fdf7e..2e1543aa802 100644 --- a/acceptance/localenv/provision-conflict-sync/out.test.toml +++ b/acceptance/localenv/provision-conflict-sync/out.test.toml @@ -1,3 +1,2 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/provision-conflict-sync/test.toml b/acceptance/localenv/provision-conflict-sync/test.toml index 7a7684bf19b..d87227b4ce8 100644 --- a/acceptance/localenv/provision-conflict-sync/test.toml +++ b/acceptance/localenv/provision-conflict-sync/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # The fake uv is a bash script, so this test cannot run on Windows runners # (mirrors acceptance/cmd/psql). diff --git a/acceptance/localenv/provision-conflict/out.test.toml b/acceptance/localenv/provision-conflict/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/provision-conflict/out.test.toml +++ b/acceptance/localenv/provision-conflict/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/provision-conflict/test.toml b/acceptance/localenv/provision-conflict/test.toml index a9490a9bd2f..06c1351ca2a 100644 --- a/acceptance/localenv/provision-conflict/test.toml +++ b/acceptance/localenv/provision-conflict/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # setup-local writes pyproject.toml through the merge phase (backing up the # committed one) before it reports the conflict; the assertion is the JSON output, diff --git a/acceptance/localenv/serverless-check/out.test.toml b/acceptance/localenv/serverless-check/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/serverless-check/out.test.toml +++ b/acceptance/localenv/serverless-check/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/serverless-check/test.toml b/acceptance/localenv/serverless-check/test.toml index 467508f4a03..feeb4e72a56 100644 --- a/acceptance/localenv/serverless-check/test.toml +++ b/acceptance/localenv/serverless-check/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Env.DATABRICKS_LOCALENV_CONSTRAINT_SOURCE_URL_TEST_OVERRIDE = "$DATABRICKS_HOST" diff --git a/acceptance/localenv/serverless-json-major-pin/out.test.toml b/acceptance/localenv/serverless-json-major-pin/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/serverless-json-major-pin/out.test.toml +++ b/acceptance/localenv/serverless-json-major-pin/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/serverless-json-major-pin/test.toml b/acceptance/localenv/serverless-json-major-pin/test.toml index 21f2fa5a8c8..560352288ea 100644 --- a/acceptance/localenv/serverless-json-major-pin/test.toml +++ b/acceptance/localenv/serverless-json-major-pin/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Env.DATABRICKS_LOCALENV_CONSTRAINT_SOURCE_URL_TEST_OVERRIDE = "$DATABRICKS_HOST" # Serverless pins databricks-connect by major (~=17.0) across every env diff --git a/acceptance/localenv/serverless-json/out.test.toml b/acceptance/localenv/serverless-json/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/serverless-json/out.test.toml +++ b/acceptance/localenv/serverless-json/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/serverless-json/test.toml b/acceptance/localenv/serverless-json/test.toml index 467508f4a03..feeb4e72a56 100644 --- a/acceptance/localenv/serverless-json/test.toml +++ b/acceptance/localenv/serverless-json/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] Env.DATABRICKS_LOCALENV_CONSTRAINT_SOURCE_URL_TEST_OVERRIDE = "$DATABRICKS_HOST" diff --git a/acceptance/localenv/wildcard-constraint-conflict-check/out.test.toml b/acceptance/localenv/wildcard-constraint-conflict-check/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/localenv/wildcard-constraint-conflict-check/out.test.toml +++ b/acceptance/localenv/wildcard-constraint-conflict-check/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/localenv/wildcard-constraint-conflict-check/test.toml b/acceptance/localenv/wildcard-constraint-conflict-check/test.toml index 904458b44a6..06a72e3876f 100644 --- a/acceptance/localenv/wildcard-constraint-conflict-check/test.toml +++ b/acceptance/localenv/wildcard-constraint-conflict-check/test.toml @@ -1,4 +1,3 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # The script writes pyproject.toml as the merge input; --dry-run leaves it unchanged. Ignore = ["pyproject.toml"] diff --git a/acceptance/panic/out.test.toml b/acceptance/panic/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/panic/out.test.toml +++ b/acceptance/panic/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/databricks-cli-help/out.test.toml b/acceptance/pipelines/databricks-cli-help/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/databricks-cli-help/out.test.toml +++ b/acceptance/pipelines/databricks-cli-help/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/deploy/auto-approve/out.test.toml b/acceptance/pipelines/deploy/auto-approve/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/deploy/auto-approve/out.test.toml +++ b/acceptance/pipelines/deploy/auto-approve/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/deploy/create-pipeline/out.test.toml b/acceptance/pipelines/deploy/create-pipeline/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/deploy/create-pipeline/out.test.toml +++ b/acceptance/pipelines/deploy/create-pipeline/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/deploy/fail-on-active-runs/out.test.toml b/acceptance/pipelines/deploy/fail-on-active-runs/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/deploy/fail-on-active-runs/out.test.toml +++ b/acceptance/pipelines/deploy/fail-on-active-runs/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/deploy/force-lock/out.test.toml b/acceptance/pipelines/deploy/force-lock/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/deploy/force-lock/out.test.toml +++ b/acceptance/pipelines/deploy/force-lock/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/deploy/oss-spark-error/out.test.toml b/acceptance/pipelines/deploy/oss-spark-error/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/deploy/oss-spark-error/out.test.toml +++ b/acceptance/pipelines/deploy/oss-spark-error/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/deploy/render-diagnostics-warning/out.test.toml b/acceptance/pipelines/deploy/render-diagnostics-warning/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/deploy/render-diagnostics-warning/out.test.toml +++ b/acceptance/pipelines/deploy/render-diagnostics-warning/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/deploy/var-flag/out.test.toml b/acceptance/pipelines/deploy/var-flag/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/deploy/var-flag/out.test.toml +++ b/acceptance/pipelines/deploy/var-flag/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/destroy/auto-approve/out.test.toml b/acceptance/pipelines/destroy/auto-approve/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/destroy/auto-approve/out.test.toml +++ b/acceptance/pipelines/destroy/auto-approve/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/destroy/cascade-on-destroy-terraform-error/databricks.yml b/acceptance/pipelines/destroy/cascade-on-destroy-terraform-error/databricks.yml deleted file mode 100644 index 0c4f487853b..00000000000 --- a/acceptance/pipelines/destroy/cascade-on-destroy-terraform-error/databricks.yml +++ /dev/null @@ -1,7 +0,0 @@ -bundle: - name: test-cascade-on-destroy-tf-error -resources: - pipelines: - my_pipeline: - name: test-pipeline-cascade-tf - cascade_on_destroy: false diff --git a/acceptance/pipelines/destroy/cascade-on-destroy-terraform-error/out.test.toml b/acceptance/pipelines/destroy/cascade-on-destroy-terraform-error/out.test.toml deleted file mode 100644 index d2059b4b5d7..00000000000 --- a/acceptance/pipelines/destroy/cascade-on-destroy-terraform-error/out.test.toml +++ /dev/null @@ -1,2 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] diff --git a/acceptance/pipelines/destroy/cascade-on-destroy-terraform-error/output.txt b/acceptance/pipelines/destroy/cascade-on-destroy-terraform-error/output.txt deleted file mode 100644 index e1636043a2e..00000000000 --- a/acceptance/pipelines/destroy/cascade-on-destroy-terraform-error/output.txt +++ /dev/null @@ -1,11 +0,0 @@ - -=== pipelines deploy fails with cascade_on_destroy on terraform engine ->>> errcode [CLI] pipelines deploy -Error: cascade_on_destroy is only supported in direct deployment mode - in databricks.yml:7:27 - -cascade_on_destroy is not yet supported by the terraform provider. Set the DATABRICKS_BUNDLE_ENGINE environment variable to 'direct' or set 'bundle.engine: direct' in your databricks.yml to use it. -Learn more at https://docs.databricks.com/dev-tools/bundles/direct - - -Exit code: 1 diff --git a/acceptance/pipelines/destroy/cascade-on-destroy-terraform-error/script b/acceptance/pipelines/destroy/cascade-on-destroy-terraform-error/script deleted file mode 100644 index ba05370f088..00000000000 --- a/acceptance/pipelines/destroy/cascade-on-destroy-terraform-error/script +++ /dev/null @@ -1,2 +0,0 @@ -title "pipelines deploy fails with cascade_on_destroy on terraform engine" -trace errcode $CLI pipelines deploy diff --git a/acceptance/pipelines/destroy/cascade-on-destroy-terraform-error/test.toml b/acceptance/pipelines/destroy/cascade-on-destroy-terraform-error/test.toml deleted file mode 100644 index bffe50aebe1..00000000000 --- a/acceptance/pipelines/destroy/cascade-on-destroy-terraform-error/test.toml +++ /dev/null @@ -1,7 +0,0 @@ -RecordRequests = false - -# Static validation only; no need to run on cloud. -Cloud = false - -# cascade_on_destroy is direct-only; assert the terraform engine rejects it. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform"] diff --git a/acceptance/pipelines/destroy/destroy-pipeline-cascade-state-divergence/out.test.toml b/acceptance/pipelines/destroy/destroy-pipeline-cascade-state-divergence/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/pipelines/destroy/destroy-pipeline-cascade-state-divergence/out.test.toml +++ b/acceptance/pipelines/destroy/destroy-pipeline-cascade-state-divergence/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/pipelines/destroy/destroy-pipeline-cascade-state-divergence/test.toml b/acceptance/pipelines/destroy/destroy-pipeline-cascade-state-divergence/test.toml index 18d7f81b515..82e9fa36571 100644 --- a/acceptance/pipelines/destroy/destroy-pipeline-cascade-state-divergence/test.toml +++ b/acceptance/pipelines/destroy/destroy-pipeline-cascade-state-divergence/test.toml @@ -1,4 +1,3 @@ # cascade_on_destroy only affects the direct engine's delete request; the terraform engine # does not support the attribute yet and rejects it. Restrict this test to direct -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] RecordRequests = true diff --git a/acceptance/pipelines/destroy/destroy-pipeline-cascade/out.test.toml b/acceptance/pipelines/destroy/destroy-pipeline-cascade/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/pipelines/destroy/destroy-pipeline-cascade/out.test.toml +++ b/acceptance/pipelines/destroy/destroy-pipeline-cascade/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/pipelines/destroy/destroy-pipeline-cascade/test.toml b/acceptance/pipelines/destroy/destroy-pipeline-cascade/test.toml index 18d7f81b515..82e9fa36571 100644 --- a/acceptance/pipelines/destroy/destroy-pipeline-cascade/test.toml +++ b/acceptance/pipelines/destroy/destroy-pipeline-cascade/test.toml @@ -1,4 +1,3 @@ # cascade_on_destroy only affects the direct engine's delete request; the terraform engine # does not support the attribute yet and rejects it. Restrict this test to direct -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] RecordRequests = true diff --git a/acceptance/pipelines/destroy/destroy-pipeline/out.test.toml b/acceptance/pipelines/destroy/destroy-pipeline/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/destroy/destroy-pipeline/out.test.toml +++ b/acceptance/pipelines/destroy/destroy-pipeline/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/destroy/force-lock/out.test.toml b/acceptance/pipelines/destroy/force-lock/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/destroy/force-lock/out.test.toml +++ b/acceptance/pipelines/destroy/force-lock/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/dry-run/dry-run-pipeline/out.test.toml b/acceptance/pipelines/dry-run/dry-run-pipeline/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/dry-run/dry-run-pipeline/out.test.toml +++ b/acceptance/pipelines/dry-run/dry-run-pipeline/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/dry-run/no-wait/out.test.toml b/acceptance/pipelines/dry-run/no-wait/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/dry-run/no-wait/out.test.toml +++ b/acceptance/pipelines/dry-run/no-wait/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/dry-run/restart/out.test.toml b/acceptance/pipelines/dry-run/restart/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/dry-run/restart/out.test.toml +++ b/acceptance/pipelines/dry-run/restart/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/e2e/out.test.toml b/acceptance/pipelines/e2e/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/e2e/out.test.toml +++ b/acceptance/pipelines/e2e/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/generate/bad-path/out.test.toml b/acceptance/pipelines/generate/bad-path/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/generate/bad-path/out.test.toml +++ b/acceptance/pipelines/generate/bad-path/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/generate/discover-spark-pipeline-yml/out.test.toml b/acceptance/pipelines/generate/discover-spark-pipeline-yml/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/generate/discover-spark-pipeline-yml/out.test.toml +++ b/acceptance/pipelines/generate/discover-spark-pipeline-yml/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/generate/fail-overwrite/out.test.toml b/acceptance/pipelines/generate/fail-overwrite/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/generate/fail-overwrite/out.test.toml +++ b/acceptance/pipelines/generate/fail-overwrite/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/generate/simple/out.test.toml b/acceptance/pipelines/generate/simple/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/generate/simple/out.test.toml +++ b/acceptance/pipelines/generate/simple/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/generate/unknown-attribute/out.test.toml b/acceptance/pipelines/generate/unknown-attribute/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/generate/unknown-attribute/out.test.toml +++ b/acceptance/pipelines/generate/unknown-attribute/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/init/error-cases/out.test.toml b/acceptance/pipelines/init/error-cases/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/init/error-cases/out.test.toml +++ b/acceptance/pipelines/init/error-cases/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/init/python/out.test.toml b/acceptance/pipelines/init/python/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/init/python/out.test.toml +++ b/acceptance/pipelines/init/python/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/init/sql/out.test.toml b/acceptance/pipelines/init/sql/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/init/sql/out.test.toml +++ b/acceptance/pipelines/init/sql/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/open/completion/out.test.toml b/acceptance/pipelines/open/completion/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/open/completion/out.test.toml +++ b/acceptance/pipelines/open/completion/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/open/open-after-deployment/out.test.toml b/acceptance/pipelines/open/open-after-deployment/out.test.toml index 002d7a5c9cb..2b7754ff98b 100644 --- a/acceptance/pipelines/open/open-after-deployment/out.test.toml +++ b/acceptance/pipelines/open/open-after-deployment/out.test.toml @@ -1,4 +1,3 @@ Cloud = false GOOS.linux = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/run/completion/out.test.toml b/acceptance/pipelines/run/completion/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/run/completion/out.test.toml +++ b/acceptance/pipelines/run/completion/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/run/no-wait/out.test.toml b/acceptance/pipelines/run/no-wait/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/run/no-wait/out.test.toml +++ b/acceptance/pipelines/run/no-wait/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/run/refresh-flags/out.test.toml b/acceptance/pipelines/run/refresh-flags/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/run/refresh-flags/out.test.toml +++ b/acceptance/pipelines/run/refresh-flags/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/run/restart/out.test.toml b/acceptance/pipelines/run/restart/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/run/restart/out.test.toml +++ b/acceptance/pipelines/run/restart/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/run/run-info/out.test.toml b/acceptance/pipelines/run/run-info/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/run/run-info/out.test.toml +++ b/acceptance/pipelines/run/run-info/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/run/run-pipeline/out.test.toml b/acceptance/pipelines/run/run-pipeline/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/run/run-pipeline/out.test.toml +++ b/acceptance/pipelines/run/run-pipeline/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/pipelines/show/basic/out.test.toml b/acceptance/pipelines/show/basic/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/pipelines/show/basic/out.test.toml +++ b/acceptance/pipelines/show/basic/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/pipelines/show/basic/test.toml b/acceptance/pipelines/show/basic/test.toml index 402303373c1..305ab33c4ce 100644 --- a/acceptance/pipelines/show/basic/test.toml +++ b/acceptance/pipelines/show/basic/test.toml @@ -2,7 +2,6 @@ RecordRequests = true Env.DATABRICKS_WAREHOUSE_ID = "wh-test" -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # The testserver's SQL Statement Execution API is matcher-driven and fails # unmatched statements by default; stub a canned result so the golden shows real diff --git a/acceptance/pipelines/show/help/out.test.toml b/acceptance/pipelines/show/help/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/pipelines/show/help/out.test.toml +++ b/acceptance/pipelines/show/help/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/pipelines/show/help/test.toml b/acceptance/pipelines/show/help/test.toml deleted file mode 100644 index fa9e389f4aa..00000000000 --- a/acceptance/pipelines/show/help/test.toml +++ /dev/null @@ -1,2 +0,0 @@ -# --help prints without authenticating, so no server stubs are needed. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/pipelines/show/rendering/out.test.toml b/acceptance/pipelines/show/rendering/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/pipelines/show/rendering/out.test.toml +++ b/acceptance/pipelines/show/rendering/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/pipelines/show/rendering/test.toml b/acceptance/pipelines/show/rendering/test.toml index 0b84e30fb9d..8bf6aaa9437 100644 --- a/acceptance/pipelines/show/rendering/test.toml +++ b/acceptance/pipelines/show/rendering/test.toml @@ -2,7 +2,6 @@ RecordRequests = false Env.DATABRICKS_WAREHOUSE_ID = "wh-test" -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] # Non-alphabetical columns test JSON order preservation; the ragged second row tests # null padding, and the long note tests cell truncation. diff --git a/acceptance/pipelines/stop/out.test.toml b/acceptance/pipelines/stop/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/pipelines/stop/out.test.toml +++ b/acceptance/pipelines/stop/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/quickstart/out.test.toml b/acceptance/quickstart/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/quickstart/out.test.toml +++ b/acceptance/quickstart/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/IsServicePrincipal/out.test.toml b/acceptance/selftest/IsServicePrincipal/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/IsServicePrincipal/out.test.toml +++ b/acceptance/selftest/IsServicePrincipal/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/acc_repls/out.test.toml b/acceptance/selftest/acc_repls/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/acc_repls/out.test.toml +++ b/acceptance/selftest/acc_repls/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/add_repl/out.test.toml b/acceptance/selftest/add_repl/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/add_repl/out.test.toml +++ b/acceptance/selftest/add_repl/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/basic/out.test.toml b/acceptance/selftest/basic/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/basic/out.test.toml +++ b/acceptance/selftest/basic/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/benchmark/out.test.toml b/acceptance/selftest/benchmark/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/benchmark/out.test.toml +++ b/acceptance/selftest/benchmark/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/contains/out.test.toml b/acceptance/selftest/contains/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/contains/out.test.toml +++ b/acceptance/selftest/contains/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/diff/out.test.toml b/acceptance/selftest/diff/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/diff/out.test.toml +++ b/acceptance/selftest/diff/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/envmatrix/inner/out.test.toml b/acceptance/selftest/envmatrix/inner/out.test.toml index f6801cfa8da..71956b450a7 100644 --- a/acceptance/selftest/envmatrix/inner/out.test.toml +++ b/acceptance/selftest/envmatrix/inner/out.test.toml @@ -1,6 +1,5 @@ Cloud = false EnvMatrix.B_REGULAR_VAR = ["hello"] -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.FIRST = ["one111", "two222"] EnvMatrix.SECOND = ["variantA", "variantB"] EnvMatrix.THIRD = ["three $FIRST"] diff --git a/acceptance/selftest/envmatrix/out.test.toml b/acceptance/selftest/envmatrix/out.test.toml index c23b3d76a6e..5940f9c438d 100644 --- a/acceptance/selftest/envmatrix/out.test.toml +++ b/acceptance/selftest/envmatrix/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.FIRST = ["overriden-in-inner"] EnvMatrix.THIRD = ["three $FIRST"] diff --git a/acceptance/selftest/envmatrix_empty/out.test.toml b/acceptance/selftest/envmatrix_empty/out.test.toml deleted file mode 100644 index 8fdd3560ef2..00000000000 --- a/acceptance/selftest/envmatrix_empty/out.test.toml +++ /dev/null @@ -1,2 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = [] diff --git a/acceptance/selftest/envmatrix_empty/output.txt b/acceptance/selftest/envmatrix_empty/output.txt deleted file mode 100644 index ce013625030..00000000000 --- a/acceptance/selftest/envmatrix_empty/output.txt +++ /dev/null @@ -1 +0,0 @@ -hello diff --git a/acceptance/selftest/envmatrix_empty/script b/acceptance/selftest/envmatrix_empty/script deleted file mode 100644 index 2f08be9a029..00000000000 --- a/acceptance/selftest/envmatrix_empty/script +++ /dev/null @@ -1 +0,0 @@ -echo hello diff --git a/acceptance/selftest/envmatrix_empty/test.toml b/acceptance/selftest/envmatrix_empty/test.toml deleted file mode 100644 index c63fe3fe108..00000000000 --- a/acceptance/selftest/envmatrix_empty/test.toml +++ /dev/null @@ -1 +0,0 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = [] diff --git a/acceptance/selftest/envmatrix_mixed/out.test.toml b/acceptance/selftest/envmatrix_mixed/out.test.toml index 12ed804fef0..4b0032027d8 100644 --- a/acceptance/selftest/envmatrix_mixed/out.test.toml +++ b/acceptance/selftest/envmatrix_mixed/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = [] EnvMatrix.FIRST = ["alpha", "beta"] EnvMatrix.SECOND = [] diff --git a/acceptance/selftest/envmatrix_mixed/test.toml b/acceptance/selftest/envmatrix_mixed/test.toml index 4d29f6331de..30938d59e71 100644 --- a/acceptance/selftest/envmatrix_mixed/test.toml +++ b/acceptance/selftest/envmatrix_mixed/test.toml @@ -1,3 +1,2 @@ -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = [] EnvMatrix.FIRST = ["alpha", "beta"] EnvMatrix.SECOND = [] diff --git a/acceptance/selftest/envoutput/out.direct.txt b/acceptance/selftest/envoutput/out.direct.txt deleted file mode 100644 index 84153ad6ccd..00000000000 --- a/acceptance/selftest/envoutput/out.direct.txt +++ /dev/null @@ -1 +0,0 @@ -myvalue=direct diff --git a/acceptance/selftest/envoutput/out.terraform.txt b/acceptance/selftest/envoutput/out.terraform.txt deleted file mode 100644 index 775ce816b1f..00000000000 --- a/acceptance/selftest/envoutput/out.terraform.txt +++ /dev/null @@ -1 +0,0 @@ -myvalue=terraform diff --git a/acceptance/selftest/envoutput/out.test.toml b/acceptance/selftest/envoutput/out.test.toml deleted file mode 100644 index 98ea5040486..00000000000 --- a/acceptance/selftest/envoutput/out.test.toml +++ /dev/null @@ -1,2 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/envoutput/output.txt b/acceptance/selftest/envoutput/output.txt deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/acceptance/selftest/envoutput/script b/acceptance/selftest/envoutput/script deleted file mode 100644 index a9a0f1525f0..00000000000 --- a/acceptance/selftest/envoutput/script +++ /dev/null @@ -1 +0,0 @@ -echo myvalue=$DATABRICKS_BUNDLE_ENGINE > out.$DATABRICKS_BUNDLE_ENGINE.txt diff --git a/acceptance/selftest/envoutput/test.toml b/acceptance/selftest/envoutput/test.toml deleted file mode 100644 index 15287b8b32f..00000000000 --- a/acceptance/selftest/envoutput/test.toml +++ /dev/null @@ -1,3 +0,0 @@ -EnvVaryOutput = "DATABRICKS_BUNDLE_ENGINE" - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/gen_config/out.test.toml b/acceptance/selftest/gen_config/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/gen_config/out.test.toml +++ b/acceptance/selftest/gen_config/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/inject_error/out.test.toml b/acceptance/selftest/inject_error/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/inject_error/out.test.toml +++ b/acceptance/selftest/inject_error/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/kill_caller/currentuser/out.test.toml b/acceptance/selftest/kill_caller/currentuser/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/kill_caller/currentuser/out.test.toml +++ b/acceptance/selftest/kill_caller/currentuser/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/kill_caller/multi_pattern/out.test.toml b/acceptance/selftest/kill_caller/multi_pattern/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/kill_caller/multi_pattern/out.test.toml +++ b/acceptance/selftest/kill_caller/multi_pattern/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/kill_caller/multiple/out.test.toml b/acceptance/selftest/kill_caller/multiple/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/kill_caller/multiple/out.test.toml +++ b/acceptance/selftest/kill_caller/multiple/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/kill_caller/offset/out.test.toml b/acceptance/selftest/kill_caller/offset/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/kill_caller/offset/out.test.toml +++ b/acceptance/selftest/kill_caller/offset/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/kill_caller/workspace/out.test.toml b/acceptance/selftest/kill_caller/workspace/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/kill_caller/workspace/out.test.toml +++ b/acceptance/selftest/kill_caller/workspace/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/log/out.test.toml b/acceptance/selftest/log/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/log/out.test.toml +++ b/acceptance/selftest/log/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/record_cloud/basic/out.test.toml b/acceptance/selftest/record_cloud/basic/out.test.toml index 2a13818c13f..c7c6f58ed6e 100644 --- a/acceptance/selftest/record_cloud/basic/out.test.toml +++ b/acceptance/selftest/record_cloud/basic/out.test.toml @@ -1,2 +1 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/record_cloud/error/out.test.toml b/acceptance/selftest/record_cloud/error/out.test.toml index 2a13818c13f..c7c6f58ed6e 100644 --- a/acceptance/selftest/record_cloud/error/out.test.toml +++ b/acceptance/selftest/record_cloud/error/out.test.toml @@ -1,2 +1 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/record_cloud/pipeline-crud/out.test.toml b/acceptance/selftest/record_cloud/pipeline-crud/out.test.toml index 2a13818c13f..c7c6f58ed6e 100644 --- a/acceptance/selftest/record_cloud/pipeline-crud/out.test.toml +++ b/acceptance/selftest/record_cloud/pipeline-crud/out.test.toml @@ -1,2 +1 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/record_cloud/volume-io/out.test.toml b/acceptance/selftest/record_cloud/volume-io/out.test.toml index 2a13818c13f..c7c6f58ed6e 100644 --- a/acceptance/selftest/record_cloud/volume-io/out.test.toml +++ b/acceptance/selftest/record_cloud/volume-io/out.test.toml @@ -1,2 +1 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/record_cloud/workspace-file-io/out.test.toml b/acceptance/selftest/record_cloud/workspace-file-io/out.test.toml index 2a13818c13f..c7c6f58ed6e 100644 --- a/acceptance/selftest/record_cloud/workspace-file-io/out.test.toml +++ b/acceptance/selftest/record_cloud/workspace-file-io/out.test.toml @@ -1,2 +1 @@ Cloud = true -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/selection/out.test.toml b/acceptance/selftest/selection/out.test.toml index 3c9d695f3b1..2e1543aa802 100644 --- a/acceptance/selftest/selection/out.test.toml +++ b/acceptance/selftest/selection/out.test.toml @@ -1,3 +1,2 @@ Cloud = false GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = [] diff --git a/acceptance/selftest/selection/output.txt b/acceptance/selftest/selection/output.txt index 505dd11316c..f431b56795c 100644 --- a/acceptance/selftest/selection/output.txt +++ b/acceptance/selftest/selection/output.txt @@ -28,39 +28,36 @@ Selected 2 changed tests (limit=50, 0 not selected) === Touching an invariant config runs every invariant test, for that config only >>> selection M:acceptance/bundle/invariant/configs/job.yml.tmpl -Selected 5 changed tests (limit=50, 0 not selected) - 5 ^bundle$/^invariant$/^continue_293$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ - 5 ^bundle$/^invariant$/^delete_idempotent$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ - 5 ^bundle$/^invariant$/^destroy_idempotent$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ - 5 ^bundle$/^invariant$/^migrate$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ - 5 ^bundle$/^invariant$/^no_drift$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ - 5 ^bundle$/^invariant$/^no_drift$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=true$/^INPUT_CONFIG=job\.yml\.tmpl$ +Selected 4 changed tests (limit=50, 0 not selected) + 5 ^bundle$/^invariant$/^continue_293$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ + 5 ^bundle$/^invariant$/^delete_idempotent$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ + 5 ^bundle$/^invariant$/^destroy_idempotent$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ + 5 ^bundle$/^invariant$/^no_drift$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ + 5 ^bundle$/^invariant$/^no_drift$/^DMS=true$/^INPUT_CONFIG=job\.yml\.tmpl$ === Adding one invariant config and touching another: only the new variant is new >>> selection A:acceptance/bundle/invariant/configs/pipeline.yml.tmpl M:acceptance/bundle/invariant/configs/job.yml.tmpl -Selected 10 changed tests (limit=50, 0 not selected) - 10 ^bundle$/^invariant$/^continue_293$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=pipeline\.yml\.tmpl$ - 10 ^bundle$/^invariant$/^delete_idempotent$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=pipeline\.yml\.tmpl$ - 10 ^bundle$/^invariant$/^destroy_idempotent$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=pipeline\.yml\.tmpl$ - 10 ^bundle$/^invariant$/^migrate$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=pipeline\.yml\.tmpl$ - 10 ^bundle$/^invariant$/^no_drift$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=pipeline\.yml\.tmpl$ - 10 ^bundle$/^invariant$/^no_drift$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=true$/^INPUT_CONFIG=pipeline\.yml\.tmpl$ - 5 ^bundle$/^invariant$/^continue_293$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ - 5 ^bundle$/^invariant$/^delete_idempotent$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ - 5 ^bundle$/^invariant$/^destroy_idempotent$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ - 5 ^bundle$/^invariant$/^migrate$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ - 5 ^bundle$/^invariant$/^no_drift$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ - 5 ^bundle$/^invariant$/^no_drift$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=true$/^INPUT_CONFIG=job\.yml\.tmpl$ +Selected 8 changed tests (limit=50, 0 not selected) + 10 ^bundle$/^invariant$/^continue_293$/^DMS=$/^INPUT_CONFIG=pipeline\.yml\.tmpl$ + 10 ^bundle$/^invariant$/^delete_idempotent$/^DMS=$/^INPUT_CONFIG=pipeline\.yml\.tmpl$ + 10 ^bundle$/^invariant$/^destroy_idempotent$/^DMS=$/^INPUT_CONFIG=pipeline\.yml\.tmpl$ + 10 ^bundle$/^invariant$/^no_drift$/^DMS=$/^INPUT_CONFIG=pipeline\.yml\.tmpl$ + 10 ^bundle$/^invariant$/^no_drift$/^DMS=true$/^INPUT_CONFIG=pipeline\.yml\.tmpl$ + 5 ^bundle$/^invariant$/^continue_293$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ + 5 ^bundle$/^invariant$/^delete_idempotent$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ + 5 ^bundle$/^invariant$/^destroy_idempotent$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ + 5 ^bundle$/^invariant$/^no_drift$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ + 5 ^bundle$/^invariant$/^no_drift$/^DMS=true$/^INPUT_CONFIG=job\.yml\.tmpl$ === A config an invariant test excludes does not select that test >>> selection M:acceptance/bundle/invariant/configs/vector_search_index.yml.tmpl Selected 3 changed tests (limit=50, 0 not selected) - 5 ^bundle$/^invariant$/^delete_idempotent$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=vector_search_index\.yml\.tmpl$ - 5 ^bundle$/^invariant$/^destroy_idempotent$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=vector_search_index\.yml\.tmpl$ - 5 ^bundle$/^invariant$/^no_drift$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=vector_search_index\.yml\.tmpl$ - 5 ^bundle$/^invariant$/^no_drift$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=true$/^INPUT_CONFIG=vector_search_index\.yml\.tmpl$ + 5 ^bundle$/^invariant$/^delete_idempotent$/^DMS=$/^INPUT_CONFIG=vector_search_index\.yml\.tmpl$ + 5 ^bundle$/^invariant$/^destroy_idempotent$/^DMS=$/^INPUT_CONFIG=vector_search_index\.yml\.tmpl$ + 5 ^bundle$/^invariant$/^no_drift$/^DMS=$/^INPUT_CONFIG=vector_search_index\.yml\.tmpl$ + 5 ^bundle$/^invariant$/^no_drift$/^DMS=true$/^INPUT_CONFIG=vector_search_index\.yml\.tmpl$ === Renaming a fixture out of a test selects the test that lost it @@ -71,7 +68,7 @@ Selected 1 changed tests (limit=50, 0 not selected) === The limit keeps the highest scoring tests >>> selection -limit 3 A:acceptance/selftest/basic/script M:acceptance/selftest/diff/script M:acceptance/bundle/invariant/configs/job.yml.tmpl -Selected 3 changed tests (limit=3, 4 not selected) +Selected 3 changed tests (limit=3, 3 not selected) 10 ^selftest$/^basic$ - 5 ^bundle$/^invariant$/^continue_293$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ - 5 ^bundle$/^invariant$/^delete_idempotent$/^DATABRICKS_BUNDLE_ENGINE=direct$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ + 5 ^bundle$/^invariant$/^continue_293$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ + 5 ^bundle$/^invariant$/^delete_idempotent$/^DMS=$/^INPUT_CONFIG=job\.yml\.tmpl$ diff --git a/acceptance/selftest/selection/test.toml b/acceptance/selftest/selection/test.toml index 2b18947af0a..573fe55fdc2 100644 --- a/acceptance/selftest/selection/test.toml +++ b/acceptance/selftest/selection/test.toml @@ -1,5 +1,4 @@ # Test selection has nothing to do with the deployment engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = [] # Git Bash rewrites an "A:..." argument as a Windows path (A: reads as a drive letter), # so the statuses would not survive to the command. diff --git a/acceptance/selftest/server/out.test.toml b/acceptance/selftest/server/out.test.toml index f3cf0b0a7fe..3d071780982 100644 --- a/acceptance/selftest/server/out.test.toml +++ b/acceptance/selftest/server/out.test.toml @@ -1,4 +1,3 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] EnvMatrix.VARIABLE_A = ["one", "two"] EnvMatrix.VARIABLE_B = ["HELLO", "WORLD"] diff --git a/acceptance/selftest/skip/out.test.toml b/acceptance/selftest/skip/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/skip/out.test.toml +++ b/acceptance/selftest/skip/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/sortlines/out.test.toml b/acceptance/selftest/sortlines/out.test.toml index 8fdd3560ef2..18b1a88417e 100644 --- a/acceptance/selftest/sortlines/out.test.toml +++ b/acceptance/selftest/sortlines/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = [] diff --git a/acceptance/selftest/sortlines/override/out.test.toml b/acceptance/selftest/sortlines/override/out.test.toml index 8fdd3560ef2..18b1a88417e 100644 --- a/acceptance/selftest/sortlines/override/out.test.toml +++ b/acceptance/selftest/sortlines/override/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = [] diff --git a/acceptance/selftest/sortlines/test.toml b/acceptance/selftest/sortlines/test.toml index 5375590369b..d5b098bb2ed 100644 --- a/acceptance/selftest/sortlines/test.toml +++ b/acceptance/selftest/sortlines/test.toml @@ -1,5 +1,4 @@ # Runs once: the sorting is independent of the deployment engine. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = [] # Only "Fruit:" lines are sorted; every other line delimits the runs. SortLines.fruit = '^Fruit: ' diff --git a/acceptance/selftest/subset_ancestor_engine/_script b/acceptance/selftest/subset_ancestor_engine/_script deleted file mode 100644 index 0836732d6ee..00000000000 --- a/acceptance/selftest/subset_ancestor_engine/_script +++ /dev/null @@ -1 +0,0 @@ -echo "engine=$DATABRICKS_BUNDLE_ENGINE" > "out.$DATABRICKS_BUNDLE_ENGINE.txt" diff --git a/acceptance/selftest/subset_ancestor_engine/child/out.direct.txt b/acceptance/selftest/subset_ancestor_engine/child/out.direct.txt deleted file mode 100644 index 163862caec8..00000000000 --- a/acceptance/selftest/subset_ancestor_engine/child/out.direct.txt +++ /dev/null @@ -1 +0,0 @@ -engine=direct diff --git a/acceptance/selftest/subset_ancestor_engine/child/out.terraform.txt b/acceptance/selftest/subset_ancestor_engine/child/out.terraform.txt deleted file mode 100644 index 2618d93f70d..00000000000 --- a/acceptance/selftest/subset_ancestor_engine/child/out.terraform.txt +++ /dev/null @@ -1 +0,0 @@ -engine=terraform diff --git a/acceptance/selftest/subset_ancestor_engine/child/out.test.toml b/acceptance/selftest/subset_ancestor_engine/child/out.test.toml deleted file mode 100644 index 98ea5040486..00000000000 --- a/acceptance/selftest/subset_ancestor_engine/child/out.test.toml +++ /dev/null @@ -1,2 +0,0 @@ -Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/subset_ancestor_engine/child/output.txt b/acceptance/selftest/subset_ancestor_engine/child/output.txt deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/acceptance/selftest/subset_ancestor_engine/child/script b/acceptance/selftest/subset_ancestor_engine/child/script deleted file mode 100644 index a3c2588f2d8..00000000000 --- a/acceptance/selftest/subset_ancestor_engine/child/script +++ /dev/null @@ -1,4 +0,0 @@ -# This script does not directly reference $DATABRICKS_BUNDLE_ENGINE. -# Engine detection happens via the ancestor _script helper, -# exercising the anyHelperScriptUsesEngine() path in subset selection. -source "$TESTDIR/../_script" diff --git a/acceptance/selftest/subset_ancestor_engine/child/test.toml b/acceptance/selftest/subset_ancestor_engine/child/test.toml deleted file mode 100644 index 9b64b4605a7..00000000000 --- a/acceptance/selftest/subset_ancestor_engine/child/test.toml +++ /dev/null @@ -1 +0,0 @@ -EnvVaryOutput = "DATABRICKS_BUNDLE_ENGINE" diff --git a/acceptance/selftest/testlog/out.test.toml b/acceptance/selftest/testlog/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/testlog/out.test.toml +++ b/acceptance/selftest/testlog/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/timeout/out.test.toml b/acceptance/selftest/timeout/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/timeout/out.test.toml +++ b/acceptance/selftest/timeout/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/timestamp/out.test.toml b/acceptance/selftest/timestamp/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/timestamp/out.test.toml +++ b/acceptance/selftest/timestamp/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/selftest/trap/out.test.toml b/acceptance/selftest/trap/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/selftest/trap/out.test.toml +++ b/acceptance/selftest/trap/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/ssh/bulk-transfer/out.test.toml b/acceptance/ssh/bulk-transfer/out.test.toml index 351c6a96769..0cb6941ca8d 100644 --- a/acceptance/ssh/bulk-transfer/out.test.toml +++ b/acceptance/ssh/bulk-transfer/out.test.toml @@ -2,4 +2,3 @@ Cloud = true GOOS.darwin = false GOOS.linux = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/ssh/bulk-transfer/test.toml b/acceptance/ssh/bulk-transfer/test.toml index c513bfb6ae6..2dd11a8b1e9 100644 --- a/acceptance/ssh/bulk-transfer/test.toml +++ b/acceptance/ssh/bulk-transfer/test.toml @@ -14,5 +14,3 @@ Ignore = [ GOOS.linux = true GOOS.darwin = false GOOS.windows = false - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/ssh/connect-serverless-cpu/out.test.toml b/acceptance/ssh/connect-serverless-cpu/out.test.toml index c826e1c76b6..44cce516e73 100644 --- a/acceptance/ssh/connect-serverless-cpu/out.test.toml +++ b/acceptance/ssh/connect-serverless-cpu/out.test.toml @@ -2,4 +2,3 @@ Cloud = false GOOS.darwin = false GOOS.linux = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/ssh/connect-serverless-cpu/test.toml b/acceptance/ssh/connect-serverless-cpu/test.toml index ef09c03dec4..e2a81665dae 100644 --- a/acceptance/ssh/connect-serverless-cpu/test.toml +++ b/acceptance/ssh/connect-serverless-cpu/test.toml @@ -19,7 +19,6 @@ GOOS.windows = false # No --name: the connection name is a hash of the (random) local host, so # normalize it to keep the submitted job payload deterministic. -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] [[Repls]] Old = 'databricks-cpu-[0-9a-f]{8}' diff --git a/acceptance/ssh/connect-serverless-gpu/out.test.toml b/acceptance/ssh/connect-serverless-gpu/out.test.toml index d94fbc9842c..ccd41ad5e2b 100644 --- a/acceptance/ssh/connect-serverless-gpu/out.test.toml +++ b/acceptance/ssh/connect-serverless-gpu/out.test.toml @@ -3,4 +3,3 @@ GOOS.darwin = false GOOS.linux = true GOOS.windows = false CloudEnvs.gcp = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/ssh/connect-serverless-gpu/test.toml b/acceptance/ssh/connect-serverless-gpu/test.toml index 8617cae3cde..7f941a26c6e 100644 --- a/acceptance/ssh/connect-serverless-gpu/test.toml +++ b/acceptance/ssh/connect-serverless-gpu/test.toml @@ -21,5 +21,3 @@ GOOS.windows = false # Serverless GPU is not available in GCP yet CloudEnvs.gcp = false - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/ssh/connection/out.test.toml b/acceptance/ssh/connection/out.test.toml index c826e1c76b6..44cce516e73 100644 --- a/acceptance/ssh/connection/out.test.toml +++ b/acceptance/ssh/connection/out.test.toml @@ -2,4 +2,3 @@ Cloud = false GOOS.darwin = false GOOS.linux = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/ssh/connection/test.toml b/acceptance/ssh/connection/test.toml index e09207c3d86..6f720c3a52b 100644 --- a/acceptance/ssh/connection/test.toml +++ b/acceptance/ssh/connection/test.toml @@ -19,5 +19,3 @@ Ignore = [ GOOS.linux = true GOOS.darwin = false GOOS.windows = false - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/ssh/reconnect-reused-name/out.test.toml b/acceptance/ssh/reconnect-reused-name/out.test.toml index c826e1c76b6..44cce516e73 100644 --- a/acceptance/ssh/reconnect-reused-name/out.test.toml +++ b/acceptance/ssh/reconnect-reused-name/out.test.toml @@ -2,4 +2,3 @@ Cloud = false GOOS.darwin = false GOOS.linux = true GOOS.windows = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/ssh/reconnect-reused-name/test.toml b/acceptance/ssh/reconnect-reused-name/test.toml index e1577f367a1..e88220d564c 100644 --- a/acceptance/ssh/reconnect-reused-name/test.toml +++ b/acceptance/ssh/reconnect-reused-name/test.toml @@ -14,5 +14,3 @@ Ignore = [ GOOS.linux = true GOOS.darwin = false GOOS.windows = false - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/ssh/setup/out.test.toml b/acceptance/ssh/setup/out.test.toml index 0938e678987..18b1a88417e 100644 --- a/acceptance/ssh/setup/out.test.toml +++ b/acceptance/ssh/setup/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/ssh/setup/test.toml b/acceptance/ssh/setup/test.toml index 5970721ec19..9a56fa72838 100644 --- a/acceptance/ssh/setup/test.toml +++ b/acceptance/ssh/setup/test.toml @@ -4,5 +4,3 @@ Cloud = false Ignore = [ "home", ] - -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["direct"] diff --git a/acceptance/telemetry/failure/out.test.toml b/acceptance/telemetry/failure/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/telemetry/failure/out.test.toml +++ b/acceptance/telemetry/failure/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/telemetry/partial-success/out.test.toml b/acceptance/telemetry/partial-success/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/telemetry/partial-success/out.test.toml +++ b/acceptance/telemetry/partial-success/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/telemetry/skipped/out.test.toml b/acceptance/telemetry/skipped/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/telemetry/skipped/out.test.toml +++ b/acceptance/telemetry/skipped/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/telemetry/success/out.test.toml b/acceptance/telemetry/success/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/telemetry/success/out.test.toml +++ b/acceptance/telemetry/success/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/telemetry/timeout/out.test.toml b/acceptance/telemetry/timeout/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/telemetry/timeout/out.test.toml +++ b/acceptance/telemetry/timeout/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/test.toml b/acceptance/test.toml index cd54d8c6d7f..3d965ec9729 100644 --- a/acceptance/test.toml +++ b/acceptance/test.toml @@ -25,10 +25,6 @@ Env.PYTHONUTF8 = "1" # A test that needs the raw order sets SortLinesOn.deploy_actions = false. SortLines.deploy_actions = '^(Created|Updated|Deleted|Recreated|Resized) \S+$' -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] -EnvMatrixExclude.noplantf = ["DATABRICKS_BUNDLE_ENGINE=terraform", "READPLAN=1"] -EnvRepl.DATABRICKS_BUNDLE_ENGINE = false - # >>> datetime.datetime.fromtimestamp(18000000000) # datetime.datetime(2027, 1, 15, 9, 0) # >>> datetime.datetime.fromtimestamp(1900000000) diff --git a/acceptance/workspace/jobs/create-error/out.test.toml b/acceptance/workspace/jobs/create-error/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/workspace/jobs/create-error/out.test.toml +++ b/acceptance/workspace/jobs/create-error/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/workspace/jobs/create/out.test.toml b/acceptance/workspace/jobs/create/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/workspace/jobs/create/out.test.toml +++ b/acceptance/workspace/jobs/create/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/workspace/lakeview/publish/out.test.toml b/acceptance/workspace/lakeview/publish/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/workspace/lakeview/publish/out.test.toml +++ b/acceptance/workspace/lakeview/publish/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/workspace/repos/create_with_provider/out.test.toml b/acceptance/workspace/repos/create_with_provider/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/workspace/repos/create_with_provider/out.test.toml +++ b/acceptance/workspace/repos/create_with_provider/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/workspace/repos/create_without_provider/out.test.toml b/acceptance/workspace/repos/create_without_provider/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/workspace/repos/create_without_provider/out.test.toml +++ b/acceptance/workspace/repos/create_without_provider/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/workspace/repos/delete_by_path/out.test.toml b/acceptance/workspace/repos/delete_by_path/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/workspace/repos/delete_by_path/out.test.toml +++ b/acceptance/workspace/repos/delete_by_path/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/workspace/repos/get_errors/out.test.toml b/acceptance/workspace/repos/get_errors/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/workspace/repos/get_errors/out.test.toml +++ b/acceptance/workspace/repos/get_errors/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/workspace/repos/git_cli_folder/out.test.toml b/acceptance/workspace/repos/git_cli_folder/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/workspace/repos/git_cli_folder/out.test.toml +++ b/acceptance/workspace/repos/git_cli_folder/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/acceptance/workspace/repos/update/out.test.toml b/acceptance/workspace/repos/update/out.test.toml index 98ea5040486..18b1a88417e 100644 --- a/acceptance/workspace/repos/update/out.test.toml +++ b/acceptance/workspace/repos/update/out.test.toml @@ -1,2 +1 @@ Cloud = false -EnvMatrix.DATABRICKS_BUNDLE_ENGINE = ["terraform", "direct"] diff --git a/bundle/bundle.go b/bundle/bundle.go index ce158b3e26c..09873114497 100644 --- a/bundle/bundle.go +++ b/bundle/bundle.go @@ -32,7 +32,6 @@ import ( "github.com/databricks/cli/libs/vfs" "github.com/databricks/databricks-sdk-go" "github.com/google/uuid" - "github.com/hashicorp/terraform-exec/tfexec" ) const internalFolder = ".internal" @@ -178,18 +177,9 @@ type Bundle struct { // which lists everything tracked, this counts only what actually changed. FileCounts libsync.FileCounts - // Stores an initialized copy of this bundle's Terraform wrapper. - Terraform *tfexec.Terraform - // Stores the locker responsible for acquiring/releasing a deployment lock. Locker *locker.Locker - // TerraformPlanPath is the path to the plan from the terraform CLI - TerraformPlanPath string - - // If true, the plan is empty and applying it will not do anything - TerraformPlanIsEmpty bool - // (direct only) deployment implementation and state DeploymentBundle direct.DeploymentBundle diff --git a/bundle/config/bundle.go b/bundle/config/bundle.go index a3e8e0952d0..30d361c7860 100644 --- a/bundle/config/bundle.go +++ b/bundle/config/bundle.go @@ -46,9 +46,9 @@ type Bundle struct { // Overrides the cluster used for jobs and other supported assets. ClusterId string `json:"cluster_id,omitempty"` - // Engine specifies the deployment engine to use ("terraform" or "direct"). - // Defaults to "direct"; set "terraform" to opt out. - // Can be overridden with the DATABRICKS_BUNDLE_ENGINE environment variable. + // Engine specifies the deployment engine to use. Only "direct" is supported; + // the Terraform engine was removed in v1.19.0. Can be overridden with the + // DATABRICKS_BUNDLE_ENGINE environment variable. Engine engine.EngineType `json:"engine,omitempty"` // Deployment section specifies deployment related configuration for bundle diff --git a/bundle/config/engine/engine.go b/bundle/config/engine/engine.go index d32769c53d8..acff6c15156 100644 --- a/bundle/config/engine/engine.go +++ b/bundle/config/engine/engine.go @@ -18,14 +18,26 @@ const ( ) // Default is used when the user has not set the value, both for new bundles and -// for existing terraform deployments (which are migrated to it after a deploy). +// for existing terraform deployments (whose state is migrated to it before the +// deploy). const Default = EngineDirect // SourceDefault is the Source of an EngineSetting that neither the bundle config // nor the env var requested. const SourceDefault = "default" -// Parse returns EngineType from string +// TerraformRemovedMessage is the error text shown when a bundle pins the removed +// Terraform deployment engine, via bundle.engine or DATABRICKS_BUNDLE_ENGINE. +// "terraform" is still recognized as a value so we can point at this specific +// removal rather than reporting it as an unrecognized setting. +const TerraformRemovedMessage = `the Terraform deployment engine has been removed in Databricks CLI v1.19.0 + +Remove the "engine" setting (or set it to "direct") to deploy with the direct engine; existing Terraform state is migrated automatically. To keep using Terraform, downgrade to CLI v1.18.x. +See https://docs.databricks.com/dev-tools/bundles/direct for details` + +// Parse returns EngineType from string. "terraform" still parses successfully so +// callers can distinguish the removed engine (TerraformRemovedMessage) from an +// unrecognized value. func Parse(engine string) (EngineType, bool) { switch engine { case "": @@ -44,7 +56,7 @@ func FromEnv(ctx context.Context) (EngineType, error) { value := env.Get(ctx, EnvVar) engine, ok := Parse(value) if !ok { - return EngineNotSet, fmt.Errorf("unexpected setting for %s=%#v (expected 'terraform' or 'direct')", EnvVar, value) + return EngineNotSet, fmt.Errorf("unexpected setting for %s=%#v (expected 'direct')", EnvVar, value) } return engine, nil } diff --git a/bundle/config/validate/validate_engine.go b/bundle/config/validate/validate_engine.go index 3deda5a8d7c..e3d94aacd0d 100644 --- a/bundle/config/validate/validate_engine.go +++ b/bundle/config/validate/validate_engine.go @@ -33,16 +33,16 @@ func (v *validateEngine) Apply(_ context.Context, b *bundle.Bundle) diag.Diagnos if !ok { return diag.Diagnostics{{ Severity: diag.Error, - Summary: fmt.Sprintf("invalid value %q for bundle.engine (expected %q or %q)", configEngine, engine.EngineTerraform, engine.EngineDirect), + Summary: fmt.Sprintf("invalid value %q for bundle.engine (expected %q)", configEngine, engine.EngineDirect), Locations: []dyn.Location{loc}, }} } if parsed == engine.EngineTerraform { return diag.Diagnostics{{ - Severity: diag.Warning, - Summary: "the terraform deployment engine is deprecated and will stop working in a future version of the CLI", - Detail: "See https://docs.databricks.com/aws/en/dev-tools/bundles/direct for how to migrate to the direct deployment engine", + Severity: diag.Error, + Summary: "the Terraform deployment engine has been removed in Databricks CLI v1.19.0", + Detail: `Remove the "engine" setting (or set it to "direct") to deploy with the direct engine; existing Terraform state is migrated automatically. To keep using Terraform, downgrade to CLI v1.18.x. See https://docs.databricks.com/dev-tools/bundles/direct for details.`, Locations: []dyn.Location{loc}, }} } diff --git a/bundle/config/validate/validate_engine_test.go b/bundle/config/validate/validate_engine_test.go index 9f18844546d..bb79a342f55 100644 --- a/bundle/config/validate/validate_engine_test.go +++ b/bundle/config/validate/validate_engine_test.go @@ -25,7 +25,7 @@ func TestValidateEngineDirect(t *testing.T) { assert.Empty(t, diags) } -func TestValidateEngineTerraformDeprecated(t *testing.T) { +func TestValidateEngineTerraformRemoved(t *testing.T) { b := &bundle.Bundle{ Config: config.Root{ Bundle: config.Bundle{ @@ -37,8 +37,8 @@ func TestValidateEngineTerraformDeprecated(t *testing.T) { bundletest.SetLocation(b, "bundle.engine", []dyn.Location{loc}) diags := ValidateEngine().Apply(t.Context(), b) assert.Len(t, diags, 1) - assert.Equal(t, diag.Warning, diags[0].Severity) - assert.Contains(t, diags[0].Summary, "deprecated") + assert.Equal(t, diag.Error, diags[0].Severity) + assert.Contains(t, diags[0].Summary, "removed") assert.Equal(t, []dyn.Location{loc}, diags[0].Locations) } diff --git a/bundle/deploy/terraform/apply.go b/bundle/deploy/terraform/apply.go deleted file mode 100644 index aff2025e018..00000000000 --- a/bundle/deploy/terraform/apply.go +++ /dev/null @@ -1,53 +0,0 @@ -package terraform - -import ( - "context" - - "github.com/databricks/cli/bundle" - "github.com/databricks/cli/bundle/permissions" - "github.com/databricks/cli/libs/diag" - "github.com/databricks/cli/libs/log" - "github.com/hashicorp/terraform-exec/tfexec" -) - -type apply struct{} - -func (w *apply) Name() string { - return "terraform.Apply" -} - -func (w *apply) Apply(ctx context.Context, b *bundle.Bundle) diag.Diagnostics { - // return early if plan is empty - if b.TerraformPlanIsEmpty { - log.Debugf(ctx, "No changes in plan. Skipping terraform apply.") - return nil - } - - tf := b.Terraform - if tf == nil { - return diag.Errorf("terraform not initialized") - } - - if b.TerraformPlanPath == "" { - return diag.Errorf("no plan found") - } - - // Apply terraform according to the computed plan - err := tf.Apply(ctx, tfexec.DirOrPlan(b.TerraformPlanPath)) - if err != nil { - diags := permissions.TryExtendTerraformPermissionError(ctx, b, err) - if diags != nil { - return diags - } - return diag.Errorf("terraform apply: %v", err) - } - - log.Infof(ctx, "terraform apply completed") - return nil -} - -// Apply returns a [bundle.Mutator] that runs the equivalent of `terraform apply ./plan` -// from the bundle's ephemeral working directory for Terraform. -func Apply() bundle.Mutator { - return &apply{} -} diff --git a/bundle/deploy/terraform/convert.go b/bundle/deploy/terraform/convert.go deleted file mode 100644 index 8303c2b3a0d..00000000000 --- a/bundle/deploy/terraform/convert.go +++ /dev/null @@ -1,88 +0,0 @@ -package terraform - -import ( - "context" - "fmt" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/deploy/terraform/tfdyn" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/log" -) - -// BundleToTerraformWithDynValue converts resources in a bundle configuration -// to the equivalent Terraform JSON representation. -// -// Resource types without a terraform converter are only supported by the direct -// engine. They are an error here, except when skipUnsupported is set: the state is -// migrated to the direct engine right after this deploy, so they are skipped by -// this run and deployed by the next one. See bundle.Bundle.MigratingToDirect. -func BundleToTerraformWithDynValue(ctx context.Context, root dyn.Value, skipUnsupported bool) (*schema.Root, error) { - tfroot := schema.NewRoot() - tfroot.Provider = schema.NewProviders() - - // Convert each resource in the bundle to the equivalent Terraform representation. - dynResources, err := dyn.Get(root, "resources") - if err != nil { - // If the resources key is missing, return an empty root. - if dyn.IsNoSuchKeyError(err) { - return tfroot, nil - } - return nil, err - } - - tfroot.Resource = schema.NewResources() - - numResources := 0 - _, err = dyn.Walk(dynResources, func(p dyn.Path, v dyn.Value) (dyn.Value, error) { - if len(p) < 2 { - return v, nil - } - - // Skip resources that have been deleted locally. - modifiedStatus, err := dyn.Get(v, "modified_status") - if err == nil { - modifiedStatusStr, ok := modifiedStatus.AsString() - if ok && modifiedStatusStr == resources.ModifiedStatusDeleted { - return v, dyn.ErrSkip - } - } - - typ := p[0].Key() - key := p[1].Key() - - // Lookup the converter based on the resource type. - c, ok := tfdyn.GetConverter(typ) - if !ok { - if !skipUnsupported { - return dyn.InvalidValue, fmt.Errorf("no converter for resource type %s", typ) - } - log.Infof(ctx, "%s.%s: skipping, only supported by the direct engine; will be deployed after the state is migrated", typ, key) - return v, dyn.ErrSkip - } - - // Convert resource to Terraform representation. - err = c.Convert(ctx, key, v, tfroot.Resource) - if err != nil { - return dyn.InvalidValue, err - } - - numResources++ - - // Skip traversal of the resource itself. - return v, dyn.ErrSkip - }) - if err != nil { - return nil, err - } - - // We explicitly set "resource" to nil to omit it from a JSON encoding. - // This is required because the terraform CLI requires >= 1 resources defined - // if the "resource" property is used in a .tf.json file. - if numResources == 0 { - tfroot.Resource = nil - } - - return tfroot, nil -} diff --git a/bundle/deploy/terraform/convert_test.go b/bundle/deploy/terraform/convert_test.go deleted file mode 100644 index 537c9128fa9..00000000000 --- a/bundle/deploy/terraform/convert_test.go +++ /dev/null @@ -1,598 +0,0 @@ -package terraform - -import ( - "testing" - - "github.com/databricks/cli/bundle/config" - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/catalog" - "github.com/databricks/databricks-sdk-go/service/compute" - "github.com/databricks/databricks-sdk-go/service/jobs" - "github.com/databricks/databricks-sdk-go/service/ml" - "github.com/databricks/databricks-sdk-go/service/pipelines" - "github.com/databricks/databricks-sdk-go/service/serving" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func produceTerraformConfiguration(t *testing.T, config config.Root) *schema.Root { - vin, err := convert.FromTyped(config, dyn.NilValue) - require.NoError(t, err) - out, err := BundleToTerraformWithDynValue(t.Context(), vin, false) - require.NoError(t, err) - return out -} - -func convertToResourceStruct[T any](t *testing.T, resource *T, data any) { - require.NotNil(t, resource) - require.NotNil(t, data) - - // Convert data to a dyn.Value. - vin, err := convert.FromTyped(data, dyn.NilValue) - require.NoError(t, err) - - // Convert the dyn.Value to a struct. - err = convert.ToTyped(resource, vin) - require.NoError(t, err) -} - -func TestBundleToTerraformJob(t *testing.T) { - src := resources.Job{ - JobSettings: jobs.JobSettings{ - Name: "my job", - JobClusters: []jobs.JobCluster{ - { - JobClusterKey: "key", - NewCluster: &compute.ClusterSpec{ - SparkVersion: "10.4.x-scala2.12", - }, - }, - }, - GitSource: &jobs.GitSource{ - GitProvider: jobs.GitProviderGitHub, - GitUrl: "https://github.com/foo/bar", - }, - Parameters: []jobs.JobParameterDefinition{ - { - Name: "param1", - Default: "default1", - }, - { - Name: "param2", - Default: "default2", - }, - }, - }, - } - - config := config.Root{ - Resources: config.Resources{ - Jobs: map[string]*resources.Job{ - "my_job": &src, - }, - }, - } - - var resource schema.ResourceJob - out := produceTerraformConfiguration(t, config) - convertToResourceStruct(t, &resource, out.Resource.Job["my_job"]) - - assert.Equal(t, "my job", resource.Name) - assert.Len(t, resource.JobCluster, 1) - assert.Equal(t, "https://github.com/foo/bar", resource.GitSource.Url) - assert.Len(t, resource.Parameter, 2) - assert.Equal(t, "param1", resource.Parameter[0].Name) - assert.Equal(t, "param2", resource.Parameter[1].Name) - assert.Nil(t, out.Data) -} - -func TestBundleToTerraformJobPermissions(t *testing.T) { - src := resources.Job{ - Permissions: []resources.JobPermission{ - { - Level: "CAN_VIEW", - UserName: "jane@doe.com", - }, - }, - } - - config := config.Root{ - Resources: config.Resources{ - Jobs: map[string]*resources.Job{ - "my_job": &src, - }, - }, - } - - var resource schema.ResourcePermissions - out := produceTerraformConfiguration(t, config) - convertToResourceStruct(t, &resource, out.Resource.Permissions["job_my_job"]) - - assert.NotEmpty(t, resource.JobId) - assert.Len(t, resource.AccessControl, 1) - assert.Equal(t, "jane@doe.com", resource.AccessControl[0].UserName) - assert.Equal(t, "CAN_VIEW", resource.AccessControl[0].PermissionLevel) -} - -func TestBundleToTerraformJobTaskLibraries(t *testing.T) { - src := resources.Job{ - JobSettings: jobs.JobSettings{ - Name: "my job", - Tasks: []jobs.Task{ - { - TaskKey: "key", - Libraries: []compute.Library{ - { - Pypi: &compute.PythonPyPiLibrary{ - Package: "mlflow", - }, - }, - }, - }, - }, - }, - } - - config := config.Root{ - Resources: config.Resources{ - Jobs: map[string]*resources.Job{ - "my_job": &src, - }, - }, - } - - var resource schema.ResourceJob - out := produceTerraformConfiguration(t, config) - convertToResourceStruct(t, &resource, out.Resource.Job["my_job"]) - - assert.Equal(t, "my job", resource.Name) - require.Len(t, resource.Task, 1) - require.Len(t, resource.Task[0].Library, 1) - assert.Equal(t, "mlflow", resource.Task[0].Library[0].Pypi.Package) -} - -func TestBundleToTerraformForEachTaskLibraries(t *testing.T) { - src := resources.Job{ - JobSettings: jobs.JobSettings{ - Name: "my job", - Tasks: []jobs.Task{ - { - TaskKey: "key", - ForEachTask: &jobs.ForEachTask{ - Inputs: "[1,2,3]", - Task: jobs.Task{ - TaskKey: "iteration", - Libraries: []compute.Library{ - { - Pypi: &compute.PythonPyPiLibrary{ - Package: "mlflow", - }, - }, - }, - }, - }, - }, - }, - }, - } - - config := config.Root{ - Resources: config.Resources{ - Jobs: map[string]*resources.Job{ - "my_job": &src, - }, - }, - } - - var resource schema.ResourceJob - out := produceTerraformConfiguration(t, config) - convertToResourceStruct(t, &resource, out.Resource.Job["my_job"]) - - assert.Equal(t, "my job", resource.Name) - require.Len(t, resource.Task, 1) - require.Len(t, resource.Task[0].ForEachTask.Task.Library, 1) - assert.Equal(t, "mlflow", resource.Task[0].ForEachTask.Task.Library[0].Pypi.Package) -} - -func TestBundleToTerraformPipeline(t *testing.T) { - src := resources.Pipeline{ - CreatePipeline: pipelines.CreatePipeline{ - Name: "my pipeline", - Libraries: []pipelines.PipelineLibrary{ - { - Notebook: &pipelines.NotebookLibrary{ - Path: "notebook path", - }, - }, - { - File: &pipelines.FileLibrary{ - Path: "file path", - }, - }, - }, - Notifications: []pipelines.Notifications{ - { - Alerts: []string{ - "on-update-fatal-failure", - }, - EmailRecipients: []string{ - "jane@doe.com", - }, - }, - { - Alerts: []string{ - "on-update-failure", - "on-flow-failure", - }, - EmailRecipients: []string{ - "jane@doe.com", - "john@doe.com", - }, - }, - }, - }, - } - - config := config.Root{ - Resources: config.Resources{ - Pipelines: map[string]*resources.Pipeline{ - "my_pipeline": &src, - }, - }, - } - - var resource schema.ResourcePipeline - out := produceTerraformConfiguration(t, config) - convertToResourceStruct(t, &resource, out.Resource.Pipeline["my_pipeline"]) - - assert.Equal(t, "my pipeline", resource.Name) - assert.Len(t, resource.Library, 2) - assert.Len(t, resource.Notification, 2) - assert.Equal(t, []string{"on-update-fatal-failure"}, resource.Notification[0].Alerts) - assert.Equal(t, []string{"jane@doe.com"}, resource.Notification[0].EmailRecipients) - assert.Equal(t, []string{"on-update-failure", "on-flow-failure"}, resource.Notification[1].Alerts) - assert.Equal(t, []string{"jane@doe.com", "john@doe.com"}, resource.Notification[1].EmailRecipients) - assert.Nil(t, out.Data) -} - -func TestBundleToTerraformPipelinePermissions(t *testing.T) { - src := resources.Pipeline{ - Permissions: []resources.PipelinePermission{ - { - Level: "CAN_VIEW", - UserName: "jane@doe.com", - }, - }, - } - - config := config.Root{ - Resources: config.Resources{ - Pipelines: map[string]*resources.Pipeline{ - "my_pipeline": &src, - }, - }, - } - - var resource schema.ResourcePermissions - out := produceTerraformConfiguration(t, config) - convertToResourceStruct(t, &resource, out.Resource.Permissions["pipeline_my_pipeline"]) - - assert.NotEmpty(t, resource.PipelineId) - assert.Len(t, resource.AccessControl, 1) - assert.Equal(t, "jane@doe.com", resource.AccessControl[0].UserName) - assert.Equal(t, "CAN_VIEW", resource.AccessControl[0].PermissionLevel) -} - -func TestBundleToTerraformModel(t *testing.T) { - src := resources.MlflowModel{ - CreateModelRequest: ml.CreateModelRequest{ - Name: "name", - Description: "description", - Tags: []ml.ModelTag{ - { - Key: "k1", - Value: "v1", - }, - { - Key: "k2", - Value: "v2", - }, - }, - }, - } - - config := config.Root{ - Resources: config.Resources{ - Models: map[string]*resources.MlflowModel{ - "my_model": &src, - }, - }, - } - - var resource schema.ResourceMlflowModel - out := produceTerraformConfiguration(t, config) - convertToResourceStruct(t, &resource, out.Resource.MlflowModel["my_model"]) - - assert.Equal(t, "name", resource.Name) - assert.Equal(t, "description", resource.Description) - assert.Len(t, resource.Tags, 2) - assert.Equal(t, "k1", resource.Tags[0].Key) - assert.Equal(t, "v1", resource.Tags[0].Value) - assert.Equal(t, "k2", resource.Tags[1].Key) - assert.Equal(t, "v2", resource.Tags[1].Value) - assert.Nil(t, out.Data) -} - -func TestBundleToTerraformModelPermissions(t *testing.T) { - src := resources.MlflowModel{ - CreateModelRequest: ml.CreateModelRequest{ - Name: "name", - }, - Permissions: []resources.MlflowModelPermission{ - { - Level: "CAN_READ", - UserName: "jane@doe.com", - }, - }, - } - - config := config.Root{ - Resources: config.Resources{ - Models: map[string]*resources.MlflowModel{ - "my_model": &src, - }, - }, - } - - var resource schema.ResourcePermissions - out := produceTerraformConfiguration(t, config) - convertToResourceStruct(t, &resource, out.Resource.Permissions["mlflow_model_my_model"]) - - assert.NotEmpty(t, resource.RegisteredModelId) - assert.Len(t, resource.AccessControl, 1) - assert.Equal(t, "jane@doe.com", resource.AccessControl[0].UserName) - assert.Equal(t, "CAN_READ", resource.AccessControl[0].PermissionLevel) -} - -func TestBundleToTerraformExperiment(t *testing.T) { - src := resources.MlflowExperiment{ - CreateExperiment: ml.CreateExperiment{ - Name: "name", - }, - } - - config := config.Root{ - Resources: config.Resources{ - Experiments: map[string]*resources.MlflowExperiment{ - "my_experiment": &src, - }, - }, - } - - var resource schema.ResourceMlflowExperiment - out := produceTerraformConfiguration(t, config) - convertToResourceStruct(t, &resource, out.Resource.MlflowExperiment["my_experiment"]) - - assert.Equal(t, "name", resource.Name) - assert.Nil(t, out.Data) -} - -func TestBundleToTerraformExperimentPermissions(t *testing.T) { - src := resources.MlflowExperiment{ - CreateExperiment: ml.CreateExperiment{ - Name: "name", - }, - Permissions: []resources.MlflowExperimentPermission{ - { - Level: "CAN_READ", - UserName: "jane@doe.com", - }, - }, - } - - config := config.Root{ - Resources: config.Resources{ - Experiments: map[string]*resources.MlflowExperiment{ - "my_experiment": &src, - }, - }, - } - - var resource schema.ResourcePermissions - out := produceTerraformConfiguration(t, config) - convertToResourceStruct(t, &resource, out.Resource.Permissions["mlflow_experiment_my_experiment"]) - - assert.NotEmpty(t, resource.ExperimentId) - assert.Len(t, resource.AccessControl, 1) - assert.Equal(t, "jane@doe.com", resource.AccessControl[0].UserName) - assert.Equal(t, "CAN_READ", resource.AccessControl[0].PermissionLevel) -} - -func TestBundleToTerraformModelServing(t *testing.T) { - src := resources.ModelServingEndpoint{ - CreateServingEndpoint: serving.CreateServingEndpoint{ - Name: "name", - Config: &serving.EndpointCoreConfigInput{ - ServedModels: []serving.ServedModelInput{ - { - ModelName: "model_name", - ModelVersion: "1", - ScaleToZeroEnabled: true, - WorkloadSize: "Small", - }, - }, - TrafficConfig: &serving.TrafficConfig{ - Routes: []serving.Route{ - { - ServedModelName: "model_name-1", - TrafficPercentage: 100, - }, - }, - }, - }, - }, - } - - config := config.Root{ - Resources: config.Resources{ - ModelServingEndpoints: map[string]*resources.ModelServingEndpoint{ - "my_model_serving_endpoint": &src, - }, - }, - } - - var resource schema.ResourceModelServing - out := produceTerraformConfiguration(t, config) - convertToResourceStruct(t, &resource, out.Resource.ModelServing["my_model_serving_endpoint"]) - - assert.Equal(t, "name", resource.Name) - assert.Equal(t, "model_name", resource.Config.ServedModels[0].ModelName) - assert.Equal(t, "1", resource.Config.ServedModels[0].ModelVersion) - assert.True(t, resource.Config.ServedModels[0].ScaleToZeroEnabled) - assert.Equal(t, "Small", resource.Config.ServedModels[0].WorkloadSize) - assert.Equal(t, "model_name-1", resource.Config.TrafficConfig.Routes[0].ServedModelName) - assert.Equal(t, 100, resource.Config.TrafficConfig.Routes[0].TrafficPercentage) - assert.Nil(t, out.Data) -} - -func TestBundleToTerraformModelServingPermissions(t *testing.T) { - src := resources.ModelServingEndpoint{ - CreateServingEndpoint: serving.CreateServingEndpoint{ - Name: "name", - - // Need to specify this to satisfy the equivalence test: - // The previous method of generation includes the "create" field - // because it is required (not marked as `omitempty`). - // The previous method used [json.Marshal] from the standard library - // and as such observed the `omitempty` tag. - // The new method leverages [dyn.Value] where any field that is not - // explicitly set is not part of the value. - Config: &serving.EndpointCoreConfigInput{ - ServedModels: []serving.ServedModelInput{ - { - ModelName: "model_name", - ModelVersion: "1", - ScaleToZeroEnabled: true, - WorkloadSize: "Small", - }, - }, - }, - }, - Permissions: []resources.ModelServingEndpointPermission{ - { - Level: "CAN_VIEW", - UserName: "jane@doe.com", - }, - }, - } - - config := config.Root{ - Resources: config.Resources{ - ModelServingEndpoints: map[string]*resources.ModelServingEndpoint{ - "my_model_serving_endpoint": &src, - }, - }, - } - - var resource schema.ResourcePermissions - out := produceTerraformConfiguration(t, config) - convertToResourceStruct(t, &resource, out.Resource.Permissions["model_serving_my_model_serving_endpoint"]) - - assert.NotEmpty(t, resource.ServingEndpointId) - assert.Len(t, resource.AccessControl, 1) - assert.Equal(t, "jane@doe.com", resource.AccessControl[0].UserName) - assert.Equal(t, "CAN_VIEW", resource.AccessControl[0].PermissionLevel) -} - -func TestBundleToTerraformRegisteredModel(t *testing.T) { - src := resources.RegisteredModel{ - CreateRegisteredModelRequest: catalog.CreateRegisteredModelRequest{ - Name: "name", - CatalogName: "catalog", - SchemaName: "schema", - Comment: "comment", - }, - } - - config := config.Root{ - Resources: config.Resources{ - RegisteredModels: map[string]*resources.RegisteredModel{ - "my_registered_model": &src, - }, - }, - } - - var resource schema.ResourceRegisteredModel - out := produceTerraformConfiguration(t, config) - convertToResourceStruct(t, &resource, out.Resource.RegisteredModel["my_registered_model"]) - - assert.Equal(t, "name", resource.Name) - assert.Equal(t, "catalog", resource.CatalogName) - assert.Equal(t, "schema", resource.SchemaName) - assert.Equal(t, "comment", resource.Comment) - assert.Nil(t, out.Data) -} - -func TestBundleToTerraformRegisteredModelGrants(t *testing.T) { - src := resources.RegisteredModel{ - CreateRegisteredModelRequest: catalog.CreateRegisteredModelRequest{ - Name: "name", - CatalogName: "catalog", - SchemaName: "schema", - }, - Grants: []catalog.PrivilegeAssignment{ - { - Privileges: []catalog.Privilege{catalog.PrivilegeExecute}, - Principal: "jane@doe.com", - }, - }, - } - - config := config.Root{ - Resources: config.Resources{ - RegisteredModels: map[string]*resources.RegisteredModel{ - "my_registered_model": &src, - }, - }, - } - - var resource schema.ResourceGrants - out := produceTerraformConfiguration(t, config) - convertToResourceStruct(t, &resource, out.Resource.Grants["registered_model_my_registered_model"]) - - assert.NotEmpty(t, resource.Function) - assert.Len(t, resource.Grant, 1) - assert.Equal(t, "jane@doe.com", resource.Grant[0].Principal) - assert.Equal(t, "EXECUTE", resource.Grant[0].Privileges[0]) -} - -func TestBundleToTerraformDeletedResources(t *testing.T) { - job1 := resources.Job{ - JobSettings: jobs.JobSettings{}, - } - job2 := resources.Job{ - BaseResource: resources.BaseResource{ModifiedStatus: resources.ModifiedStatusDeleted}, - JobSettings: jobs.JobSettings{}, - } - config := config.Root{ - Resources: config.Resources{ - Jobs: map[string]*resources.Job{ - "my_job1": &job1, - "my_job2": &job2, - }, - }, - } - - vin, err := convert.FromTyped(config, dyn.NilValue) - require.NoError(t, err) - out, err := BundleToTerraformWithDynValue(t.Context(), vin, false) - require.NoError(t, err) - - _, ok := out.Resource.Job["my_job1"] - assert.True(t, ok) - _, ok = out.Resource.Job["my_job2"] - assert.False(t, ok) -} diff --git a/bundle/deploy/terraform/import.go b/bundle/deploy/terraform/import.go deleted file mode 100644 index 474aaa23057..00000000000 --- a/bundle/deploy/terraform/import.go +++ /dev/null @@ -1,121 +0,0 @@ -package terraform - -import ( - "bytes" - "context" - "fmt" - "io" - "os" - "path/filepath" - "strings" - - "github.com/databricks/cli/bundle" - "github.com/databricks/cli/libs/agent" - "github.com/databricks/cli/libs/cmdio" - "github.com/databricks/cli/libs/diag" - "github.com/hashicorp/terraform-exec/tfexec" -) - -type BindOptions struct { - AutoApprove bool - ResourceType string - ResourceKey string - ResourceId string -} - -type importResource struct { - opts *BindOptions -} - -// Apply implements bundle.Mutator. -func (m *importResource) Apply(ctx context.Context, b *bundle.Bundle) diag.Diagnostics { - dir, err := Dir(ctx, b) - if err != nil { - return diag.FromErr(err) - } - - diags := Initialize(ctx, b) - if diags.HasError() { - return diags - } - - tf := b.Terraform - tmpDir, err := os.MkdirTemp("", "state-*") - if err != nil { - return diag.Errorf("terraform init: %v", err) - } - defer os.RemoveAll(tmpDir) - relPath, _ := b.StateFilenameTerraform(ctx) - tmpState := filepath.Join(tmpDir, filepath.Base(relPath)) - - importAddress := fmt.Sprintf("%s.%s", m.opts.ResourceType, m.opts.ResourceKey) - err = tf.Import(ctx, importAddress, m.opts.ResourceId, tfexec.StateOut(tmpState)) - if err != nil { - return diag.Errorf("terraform import: %v", err) - } - - buf := bytes.NewBuffer(nil) - tf.SetStdout(buf) - - //nolint:staticcheck // SA1019 We use legacy -state flag for now to plan the import changes based on temporary state file - changed, err := tf.Plan(ctx, tfexec.State(tmpState), tfexec.Target(importAddress)) - if err != nil { - return diag.Errorf("terraform plan: %v", err) - } - - if changed && !m.opts.AutoApprove { - output := buf.String() - // Remove output starting from Warning until end of output, if present. - if idx := strings.Index(output, "Warning:"); idx != -1 { - output = output[:idx] - } - cmdio.LogString(ctx, output) - - if !cmdio.IsPromptSupported(ctx) { - return diag.Errorf("this bind operation requires user confirmation, but the current console does not support prompting.\nTo proceed, use --auto-approve after reviewing the plan above.%s", agent.AgentNotice()) - } - - ans, err := cmdio.AskYesOrNo(ctx, "Confirm import changes? Changes will be remotely applied only after running 'bundle deploy'.") - if err != nil { - return diag.FromErr(err) - } - if !ans { - return diag.Errorf("import aborted") - } - } - - // If user confirmed changes, move the state file from temp dir to state location - f, err := os.Create(filepath.Join(dir, relPath)) - if err != nil { - return diag.FromErr(err) - } - defer f.Close() - - tmpF, err := os.Open(tmpState) - if err != nil { - return diag.FromErr(err) - } - defer tmpF.Close() - - _, err = io.Copy(f, tmpF) - if err != nil { - return diag.FromErr(err) - } - - // A failed Close can mean a truncated state file; the deferred Close above covers error paths. - err = f.Close() - if err != nil { - return diag.FromErr(err) - } - - return diags -} - -// Name implements bundle.Mutator. -func (*importResource) Name() string { - return "terraform.Import" -} - -func Import(opts *BindOptions) bundle.Mutator { - return &importResource{opts: opts} -} diff --git a/bundle/deploy/terraform/init.go b/bundle/deploy/terraform/init.go deleted file mode 100644 index cbabeb3fee1..00000000000 --- a/bundle/deploy/terraform/init.go +++ /dev/null @@ -1,381 +0,0 @@ -package terraform - -import ( - "context" - "errors" - "fmt" - "io/fs" - "maps" - "os" - "os/exec" - "path/filepath" - "runtime" - "slices" - "strings" - - "github.com/databricks/cli/bundle" - "github.com/databricks/cli/bundle/config" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/internal/build" - "github.com/databricks/cli/libs/diag" - "github.com/databricks/cli/libs/env" - "github.com/databricks/cli/libs/log" - "github.com/hashicorp/hc-install/product" - "github.com/hashicorp/terraform-exec/tfexec" -) - -func findExecPath(ctx context.Context, b *bundle.Bundle, tf *config.Terraform, installer Installer) (string, error) { - // If set, pass it through [exec.LookPath] to resolve its absolute path. - if tf.ExecPath != "" { - execPath, err := exec.LookPath(tf.ExecPath) - if err != nil { - return "", err - } - tf.ExecPath = execPath - log.Debugf(ctx, "Using Terraform at %s", tf.ExecPath) - return tf.ExecPath, nil - } - - // Resolve the version of the Terraform CLI to use. - tv, isDefault, err := GetTerraformVersion(ctx) - if err != nil { - return "", err - } - - // Allow the user to specify the path to the Terraform CLI. - // If this is set, verify that the version matches the version we expect. - if execPathValue, ok := env.Lookup(ctx, TerraformExecPathEnv); ok { - tfe, err := getTerraformExec(ctx, b, execPathValue) - if err != nil { - return "", err - } - - expectedVersion := tv.Version - actualVersion, _, err := tfe.Version(ctx, false) - if err != nil { - return "", fmt.Errorf("unable to execute %s: %w", TerraformExecPathEnv, err) - } - - if !actualVersion.Equal(expectedVersion) { - if isDefault { - return "", fmt.Errorf( - "terraform binary at %s (from $%s) is %s but expected version is %s. Set %s to %s to continue", - execPathValue, - TerraformExecPathEnv, - actualVersion.String(), - expectedVersion.String(), - TerraformVersionEnv, - actualVersion.String(), - ) - } else { - return "", fmt.Errorf( - "terraform binary at %s (from $%s) is %s but expected version is %s (from $%s). Update $%s and $%s so that versions match", - execPathValue, - TerraformExecPathEnv, - actualVersion.String(), - expectedVersion.String(), - TerraformVersionEnv, - TerraformExecPathEnv, - TerraformVersionEnv, - ) - } - } - - tf.ExecPath = execPathValue - log.Debugf(ctx, "Using Terraform from %s at %s", TerraformExecPathEnv, tf.ExecPath) - return tf.ExecPath, nil - } - - binDir, err := b.LocalStateDir(ctx, "bin") - if err != nil { - return "", err - } - - // If the execPath already exists, return it. - execPath := filepath.Join(binDir, product.Terraform.BinaryName()) - _, err = os.Stat(execPath) - if err != nil && !errors.Is(err, fs.ErrNotExist) { - return "", err - } - if err == nil { - tf.ExecPath = execPath - log.Debugf(ctx, "Using Terraform at %s", tf.ExecPath) - return tf.ExecPath, nil - } - - // Download Terraform to private bin directory. - execPath, err = installer.Install(ctx, binDir, tv.Version) - if err != nil { - return "", fmt.Errorf("error downloading Terraform: %w", err) - } - - tf.ExecPath = execPath - log.Debugf(ctx, "Using Terraform at %s", tf.ExecPath) - return tf.ExecPath, nil -} - -var envCopy = []string{ - // Include $HOME in set of environment variables to pass along. - "HOME", - - // Include $USERPROFILE in set of environment variables to pass along. - // This variable is used by Azure CLI on Windows to find stored credentials and metadata - "USERPROFILE", - - // Include $PATH in set of environment variables to pass along. - // This is necessary to ensure that our Terraform provider can use the - // same auxiliary programs (e.g. `az`, or `gcloud`) as the CLI. - "PATH", - - // Include $AZURE_CONFIG_DIR in set of environment variables to pass along. - // This is set in Azure DevOps by the AzureCLI@2 task. - "AZURE_CONFIG_DIR", - - // Include $TF_CLI_CONFIG_FILE to override terraform provider in development. - // See: https://developer.hashicorp.com/terraform/cli/config/config-file#explicit-installation-method-configuration - "TF_CLI_CONFIG_FILE", - - // Include $USE_SDK_V2_RESOURCES and $USE_SDK_V2_DATA_SOURCES, these are used to switch back from plugin framework to SDKv2. - // This is used for mitigation issues with resource migrated to plugin framework, as recommended here: - // https://registry.terraform.io/providers/databricks/databricks/latest/docs/guides/troubleshooting#plugin-framework-migration-problems - // It is currently a workaround for deploying quality_monitors - // https://github.com/databricks/terraform-provider-databricks/issues/4229#issuecomment-2520344690 - "USE_SDK_V2_RESOURCES", - "USE_SDK_V2_DATA_SOURCES", -} - -// This function inherits some environment variables for Terraform CLI. -func inheritEnvVars(ctx context.Context, environ map[string]string) error { - for _, key := range envCopy { - value, ok := env.Lookup(ctx, key) - if ok { - environ[key] = value - } - } - - // If there's a DATABRICKS_OIDC_TOKEN_ENV set, we need to pass the value of the environment variable defined in DATABRICKS_OIDC_TOKEN_ENV to Terraform. - // This is necessary to ensure that Terraform can use the same OIDC token as the CLI. - oidcTokenEnv, ok := env.Lookup(ctx, "DATABRICKS_OIDC_TOKEN_ENV") - if ok { - environ["DATABRICKS_OIDC_TOKEN_ENV"] = oidcTokenEnv - } else { - oidcTokenEnv = "DATABRICKS_OIDC_TOKEN" - } - - oidcToken, ok := env.Lookup(ctx, oidcTokenEnv) - if ok { - environ[oidcTokenEnv] = oidcToken - } - - // Pass additional Azure DevOps system variables required for OIDC authentication. - // These variables are used by the Databricks Go SDK to authenticate with Azure DevOps OIDC. - azureDevOpsVars := []string{ - "SYSTEM_ACCESSTOKEN", - "SYSTEM_COLLECTIONID", - "SYSTEM_COLLECTIONURI", - "SYSTEM_DEFINITIONID", - "SYSTEM_HOSTTYPE", - "SYSTEM_JOBID", - "SYSTEM_OIDCREQUESTURI", - "SYSTEM_PLANID", - "SYSTEM_TEAMFOUNDATIONCOLLECTIONURI", - "SYSTEM_TEAMPROJECT", - "SYSTEM_TEAMPROJECTID", - } - for _, varName := range azureDevOpsVars { - if val, ok := env.Lookup(ctx, varName); ok { - environ[varName] = val - } - } - - // Map $DATABRICKS_TF_CLI_CONFIG_FILE to $TF_CLI_CONFIG_FILE - // VSCode extension provides a file with the "provider_installation.filesystem_mirror" configuration. - // We only use it if the provider version matches the currently used version, - // otherwise terraform will fail to download the right version (even with unrestricted internet access). - configFile, err := getEnvVarWithMatchingVersion(ctx, TerraformCliConfigPathEnv, TerraformProviderVersionEnv, schema.ProviderVersion) - if err != nil { - return err - } - if configFile != "" { - log.Debugf(ctx, "Using Terraform CLI config from %s at %s", TerraformCliConfigPathEnv, configFile) - environ["TF_CLI_CONFIG_FILE"] = configFile - } - - return nil -} - -// Example: this function will return a value of TF_EXEC_PATH only if the path exists and if TF_VERSION matches the TerraformVersion. -// This function is used for env vars set by the Databricks VSCode extension. The variables are intended to be used by the CLI -// bundled with the Databricks VSCode extension, but users can use different CLI versions in the VSCode terminals, in which case we want to ignore -// the variables if that CLI uses different versions of the dependencies. -func getEnvVarWithMatchingVersion(ctx context.Context, envVarName, versionVarName, currentVersion string) (string, error) { - envValue := env.Get(ctx, envVarName) - versionValue := env.Get(ctx, versionVarName) - - // return early if the environment variable is not set - if envValue == "" { - log.Debugf(ctx, "%s is not defined", envVarName) - return "", nil - } - - // If the path does not exist, we return early. - _, err := os.Stat(envValue) - if err != nil { - if errors.Is(err, fs.ErrNotExist) { - log.Debugf(ctx, "%s at %s does not exist", envVarName, envValue) - return "", nil - } else { - return "", err - } - } - - // If the version environment variable is not set, we directly return the value of the environment variable. - if versionValue == "" { - return envValue, nil - } - - // When the version environment variable is set, we check if it matches the current version. - // If it does not match, we return an empty string. - if versionValue != currentVersion { - log.Debugf(ctx, "%s as %s does not match the current version %s, ignoring %s", versionVarName, versionValue, currentVersion, envVarName) - return "", nil - } - return envValue, nil -} - -// This function sets temp dir location for terraform to use. If user does not -// specify anything here, we fall back to a `tmp` directory in the bundle's cache -// directory -// -// This is necessary to avoid trying to create temporary files in directories -// the CLI and its dependencies do not have access to. -// -// see: os.TempDir for more context -func setTempDirEnvVars(ctx context.Context, environ map[string]string, b *bundle.Bundle) error { - switch runtime.GOOS { - case "windows": - if v, ok := env.Lookup(ctx, "TMP"); ok { - environ["TMP"] = v - } else if v, ok := env.Lookup(ctx, "TEMP"); ok { - environ["TEMP"] = v - } else { - tmpDir, err := b.LocalStateDir(ctx, "tmp") - if err != nil { - return err - } - environ["TMP"] = tmpDir - } - default: - // If TMPDIR is not set, we let the process fall back to its default value. - if v, ok := env.Lookup(ctx, "TMPDIR"); ok { - environ["TMPDIR"] = v - } - } - return nil -} - -// This function passes through all proxy related environment variables. -func setProxyEnvVars(ctx context.Context, environ map[string]string, b *bundle.Bundle) error { - for _, v := range []string{"http_proxy", "https_proxy", "no_proxy"} { - // The case (upper or lower) is notoriously inconsistent for tools on Unix systems. - // We therefore try to read both the upper and lower case versions of the variable. - for _, v := range []string{strings.ToUpper(v), strings.ToLower(v)} { - if val, ok := env.Lookup(ctx, v); ok { - // Only set uppercase version of the variable. - environ[strings.ToUpper(v)] = val - } - } - } - return nil -} - -func setUserAgentExtraEnvVar(environ map[string]string, b *bundle.Bundle) error { - // Add "cli" to the user agent in set by the Databricks Terraform provider. - // This will allow us to attribute downstream requests made by the Databricks - // Terraform provider to the CLI. - products := []string{"cli/" + build.GetInfo().Version} - if experimental := b.Config.Experimental; experimental != nil { - hasPython := experimental.Python.Resources != nil || experimental.Python.Mutators != nil - - if hasPython { - products = append(products, "databricks-pydabs/0.7.0") - } - } - - userAgentExtra := strings.Join(products, " ") - if userAgentExtra != "" { - environ["DATABRICKS_USER_AGENT_EXTRA"] = userAgentExtra - } - - return nil -} - -func getTerraformExec(ctx context.Context, b *bundle.Bundle, execPath string) (*tfexec.Terraform, error) { - workingDir, err := Dir(ctx, b) - if err != nil { - return nil, err - } - - return tfexec.NewTerraform(workingDir, execPath) -} - -func Initialize(ctx context.Context, b *bundle.Bundle) diag.Diagnostics { - tfConfig := b.Config.Bundle.Terraform - if tfConfig == nil { - tfConfig = &config.Terraform{} - b.Config.Bundle.Terraform = tfConfig - } - - execPath, err := findExecPath(ctx, b, tfConfig, tfInstaller{}) - if err != nil { - return diag.FromErr(err) - } - - tfe, err := getTerraformExec(ctx, b, execPath) - if err != nil { - return diag.FromErr(err) - } - - environ, err := b.AuthEnv(ctx) - if err != nil { - return diag.FromErr(err) - } - - err = inheritEnvVars(ctx, environ) - if err != nil { - return diag.FromErr(err) - } - - // Set the temporary directory environment variables - err = setTempDirEnvVars(ctx, environ, b) - if err != nil { - return diag.FromErr(err) - } - - // Set the proxy related environment variables - err = setProxyEnvVars(ctx, environ, b) - if err != nil { - return diag.FromErr(err) - } - - err = setUserAgentExtraEnvVar(environ, b) - if err != nil { - return diag.FromErr(err) - } - - // Configure environment variables for auth for Terraform to use. - log.Debugf(ctx, "Environment variables for Terraform: %s", strings.Join(slices.Collect(maps.Keys(environ)), ", ")) - err = tfe.SetEnv(environ) - if err != nil { - return diag.FromErr(err) - } - - err = tfe.Init(ctx, tfexec.Upgrade(true)) - if err != nil { - return diag.Errorf("terraform init: %v", err) - } - - b.Terraform = tfe - - return nil -} diff --git a/bundle/deploy/terraform/init_test.go b/bundle/deploy/terraform/init_test.go deleted file mode 100644 index da06e2dbed4..00000000000 --- a/bundle/deploy/terraform/init_test.go +++ /dev/null @@ -1,720 +0,0 @@ -package terraform - -import ( - "context" - "fmt" - "maps" - "os" - "path/filepath" - "runtime" - "slices" - "strings" - "testing" - - "github.com/databricks/cli/bundle" - "github.com/databricks/cli/bundle/config" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/internal/build" - "github.com/databricks/cli/internal/testutil" - "github.com/databricks/cli/libs/env" - "github.com/hashicorp/go-version" - "github.com/hashicorp/hc-install/product" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func unsetEnv(t *testing.T, name string) { - t.Setenv(name, "") - err := os.Unsetenv(name) - require.NoError(t, err) -} - -func TestSetTempDirEnvVarsForUnixWithTmpDirSet(t *testing.T) { - if runtime.GOOS != "darwin" && runtime.GOOS != "linux" { - t.SkipNow() - } - - b := &bundle.Bundle{ - BundleRootPath: t.TempDir(), - Config: config.Root{ - Bundle: config.Bundle{ - Target: "whatever", - }, - }, - } - - // Set TMPDIR environment variable - t.Setenv("TMPDIR", "/foo/bar") - - // compute env - env := make(map[string]string, 0) - err := setTempDirEnvVars(t.Context(), env, b) - require.NoError(t, err) - - // Assert that we pass through TMPDIR. - assert.Equal(t, map[string]string{ - "TMPDIR": "/foo/bar", - }, env) -} - -func TestSetTempDirEnvVarsForUnixWithTmpDirNotSet(t *testing.T) { - if runtime.GOOS != "darwin" && runtime.GOOS != "linux" { - t.SkipNow() - } - - b := &bundle.Bundle{ - BundleRootPath: t.TempDir(), - Config: config.Root{ - Bundle: config.Bundle{ - Target: "whatever", - }, - }, - } - - // Unset TMPDIR environment variable confirm it's not set - unsetEnv(t, "TMPDIR") - - // compute env - env := make(map[string]string, 0) - err := setTempDirEnvVars(t.Context(), env, b) - require.NoError(t, err) - - // Assert that we don't pass through TMPDIR. - assert.Equal(t, map[string]string{}, env) -} - -func TestSetTempDirEnvVarsForWindowWithAllTmpDirEnvVarsSet(t *testing.T) { - if runtime.GOOS != "windows" { - t.SkipNow() - } - - b := &bundle.Bundle{ - BundleRootPath: t.TempDir(), - Config: config.Root{ - Bundle: config.Bundle{ - Target: "whatever", - }, - }, - } - - // Set environment variables - t.Setenv("TMP", "c:\\foo\\a") - t.Setenv("TEMP", "c:\\foo\\b") - t.Setenv("USERPROFILE", "c:\\foo\\c") - - // compute env - env := make(map[string]string, 0) - err := setTempDirEnvVars(t.Context(), env, b) - require.NoError(t, err) - - // assert that we pass through the highest priority env var value - assert.Equal(t, map[string]string{ - "TMP": "c:\\foo\\a", - }, env) -} - -func TestSetTempDirEnvVarsForWindowWithUserProfileAndTempSet(t *testing.T) { - if runtime.GOOS != "windows" { - t.SkipNow() - } - - b := &bundle.Bundle{ - BundleRootPath: t.TempDir(), - Config: config.Root{ - Bundle: config.Bundle{ - Target: "whatever", - }, - }, - } - - // Set environment variables - unsetEnv(t, "TMP") - t.Setenv("TEMP", "c:\\foo\\b") - t.Setenv("USERPROFILE", "c:\\foo\\c") - - // compute env - env := make(map[string]string, 0) - err := setTempDirEnvVars(t.Context(), env, b) - require.NoError(t, err) - - // assert that we pass through the highest priority env var value - assert.Equal(t, map[string]string{ - "TEMP": "c:\\foo\\b", - }, env) -} - -func TestSetTempDirEnvVarsForWindowsWithoutAnyTempDirEnvVarsSet(t *testing.T) { - if runtime.GOOS != "windows" { - t.SkipNow() - } - - b := &bundle.Bundle{ - BundleRootPath: t.TempDir(), - Config: config.Root{ - Bundle: config.Bundle{ - Target: "whatever", - }, - }, - } - - // unset all env vars - unsetEnv(t, "TMP") - unsetEnv(t, "TEMP") - unsetEnv(t, "USERPROFILE") - - // compute env - env := make(map[string]string, 0) - err := setTempDirEnvVars(t.Context(), env, b) - require.NoError(t, err) - - // assert TMP is set to b.LocalStateDir("tmp") - tmpDir, err := b.LocalStateDir(t.Context(), "tmp") - require.NoError(t, err) - assert.Equal(t, map[string]string{ - "TMP": tmpDir, - }, env) -} - -func TestSetProxyEnvVars(t *testing.T) { - b := &bundle.Bundle{ - BundleRootPath: t.TempDir(), - Config: config.Root{ - Bundle: config.Bundle{ - Target: "whatever", - }, - }, - } - - // Temporarily clear environment variables. - clearEnv := func() { - for _, v := range []string{"http_proxy", "https_proxy", "no_proxy"} { - for _, v := range []string{strings.ToUpper(v), strings.ToLower(v)} { - t.Setenv(v, "foo") - os.Unsetenv(v) - } - } - } - - // No proxy env vars set. - clearEnv() - env := make(map[string]string, 0) - err := setProxyEnvVars(t.Context(), env, b) - require.NoError(t, err) - assert.Empty(t, env) - - // Lower case set. - clearEnv() - t.Setenv("http_proxy", "foo") - t.Setenv("https_proxy", "foo") - t.Setenv("no_proxy", "foo") - env = make(map[string]string, 0) - err = setProxyEnvVars(t.Context(), env, b) - require.NoError(t, err) - assert.ElementsMatch(t, []string{"HTTP_PROXY", "HTTPS_PROXY", "NO_PROXY"}, slices.Collect(maps.Keys(env))) - - // Upper case set. - clearEnv() - t.Setenv("HTTP_PROXY", "foo") - t.Setenv("HTTPS_PROXY", "foo") - t.Setenv("NO_PROXY", "foo") - env = make(map[string]string, 0) - err = setProxyEnvVars(t.Context(), env, b) - require.NoError(t, err) - assert.ElementsMatch(t, []string{"HTTP_PROXY", "HTTPS_PROXY", "NO_PROXY"}, slices.Collect(maps.Keys(env))) -} - -func TestSetUserAgentExtra_Python(t *testing.T) { - b := &bundle.Bundle{ - BundleRootPath: t.TempDir(), - Config: config.Root{ - Experimental: &config.Experimental{ - Python: config.Python{ - Resources: []string{"my_project.resources:load_resources"}, - }, - }, - }, - } - - env := make(map[string]string, 0) - err := setUserAgentExtraEnvVar(env, b) - require.NoError(t, err) - // The CLI version is the test binary's own, which is the not-injected default. - assert.Equal(t, map[string]string{ - "DATABRICKS_USER_AGENT_EXTRA": "cli/" + build.DefaultSemver + " databricks-pydabs/0.7.0", - }, env) -} - -func TestInheritEnvVars(t *testing.T) { - t.Setenv("HOME", "/home/testuser") - t.Setenv("PATH", "/foo:/bar") - t.Setenv("TF_CLI_CONFIG_FILE", "/tmp/config.tfrc") - t.Setenv("AZURE_CONFIG_DIR", "/tmp/foo/bar") - - ctx := t.Context() - env := map[string]string{} - err := inheritEnvVars(ctx, env) - if assert.NoError(t, err) { - assert.Equal(t, "/home/testuser", env["HOME"]) - assert.Equal(t, "/foo:/bar", env["PATH"]) - assert.Equal(t, "/tmp/config.tfrc", env["TF_CLI_CONFIG_FILE"]) - assert.Equal(t, "/tmp/foo/bar", env["AZURE_CONFIG_DIR"]) - } -} - -func TestInheritOIDCTokenEnvCustom(t *testing.T) { - t.Setenv("DATABRICKS_OIDC_TOKEN_ENV", "custom_DATABRICKS_OIDC_TOKEN") - t.Setenv("custom_DATABRICKS_OIDC_TOKEN", "foobar") - - ctx := t.Context() - env := map[string]string{} - err := inheritEnvVars(ctx, env) - require.NoError(t, err) - assert.Equal(t, "foobar", env["custom_DATABRICKS_OIDC_TOKEN"]) - assert.Equal(t, "custom_DATABRICKS_OIDC_TOKEN", env["DATABRICKS_OIDC_TOKEN_ENV"]) -} - -func TestInheritOIDCTokenEnv(t *testing.T) { - t.Setenv("DATABRICKS_OIDC_TOKEN", "foobar") - - ctx := t.Context() - env := map[string]string{} - err := inheritEnvVars(ctx, env) - require.NoError(t, err) - assert.Equal(t, "foobar", env["DATABRICKS_OIDC_TOKEN"]) - assert.Empty(t, env["DATABRICKS_OIDC_TOKEN_ENV"]) -} - -func TestInheritAzureDevOpsSystemVariablesIndividual(t *testing.T) { - testCases := []struct { - envVar string - envValue string - }{ - {"SYSTEM_ACCESSTOKEN", "test-token"}, - {"SYSTEM_COLLECTIONID", "collection-id-456"}, - {"SYSTEM_COLLECTIONURI", "https://dev.azure.com/myorg/"}, - {"SYSTEM_DEFINITIONID", "42"}, - {"SYSTEM_HOSTTYPE", "build"}, - {"SYSTEM_JOBID", "job-123"}, - {"SYSTEM_OIDCREQUESTURI", "https://oidc.example.com"}, - {"SYSTEM_PLANID", "plan-id-123"}, - {"SYSTEM_TEAMFOUNDATIONCOLLECTIONURI", "https://dev.azure.com/org/"}, - {"SYSTEM_TEAMPROJECT", "my-project"}, - {"SYSTEM_TEAMPROJECTID", "project-id-789"}, - } - - for _, tc := range testCases { - t.Run(tc.envVar, func(t *testing.T) { - t.Setenv(tc.envVar, tc.envValue) - - ctx := t.Context() - env := map[string]string{} - err := inheritEnvVars(ctx, env) - require.NoError(t, err) - assert.Equal(t, tc.envValue, env[tc.envVar]) - }) - } -} - -func TestInheritAzureDevOpsSystemVariables(t *testing.T) { - // Set all Azure DevOps system variables - vars := map[string]string{ - "SYSTEM_ACCESSTOKEN": "test-token", - "SYSTEM_COLLECTIONID": "collection-id-456", - "SYSTEM_COLLECTIONURI": "https://dev.azure.com/myorg/", - "SYSTEM_DEFINITIONID": "42", - "SYSTEM_HOSTTYPE": "build", - "SYSTEM_JOBID": "job-123", - "SYSTEM_OIDCREQUESTURI": "https://oidc.example.com", - "SYSTEM_PLANID": "plan-id-123", - "SYSTEM_TEAMFOUNDATIONCOLLECTIONURI": "https://dev.azure.com/org/", - "SYSTEM_TEAMPROJECT": "my-project", - "SYSTEM_TEAMPROJECTID": "project-id-789", - } - - for k, v := range vars { - t.Setenv(k, v) - } - - ctx := t.Context() - env := map[string]string{} - err := inheritEnvVars(ctx, env) - require.NoError(t, err) - - for k, v := range vars { - assert.Equal(t, v, env[k]) - } -} - -func TestSetUserProfileFromInheritEnvVars(t *testing.T) { - t.Setenv("USERPROFILE", "c:\\foo\\c") - - env := make(map[string]string, 0) - err := inheritEnvVars(t.Context(), env) - require.NoError(t, err) - - assert.Contains(t, env, "USERPROFILE") - assert.Equal(t, "c:\\foo\\c", env["USERPROFILE"]) -} - -func TestInheritEnvVarsWithAbsentTFConfigFile(t *testing.T) { - ctx := t.Context() - envMap := map[string]string{} - ctx = env.Set(ctx, "DATABRICKS_TF_PROVIDER_VERSION", schema.ProviderVersion) - ctx = env.Set(ctx, "DATABRICKS_TF_CLI_CONFIG_FILE", "/tmp/config.tfrc") - err := inheritEnvVars(ctx, envMap) - require.NoError(t, err) - require.NotContains(t, envMap, "TF_CLI_CONFIG_FILE") -} - -func TestInheritEnvVarsWithWrongTFProviderVersion(t *testing.T) { - ctx := t.Context() - envMap := map[string]string{} - configFile := createTempFile(t, t.TempDir(), "config.tfrc", false) - ctx = env.Set(ctx, "DATABRICKS_TF_PROVIDER_VERSION", "wrong") - ctx = env.Set(ctx, "DATABRICKS_TF_CLI_CONFIG_FILE", configFile) - err := inheritEnvVars(ctx, envMap) - require.NoError(t, err) - require.NotContains(t, envMap, "TF_CLI_CONFIG_FILE") -} - -func TestInheritEnvVarsWithCorrectTFCLIConfigFile(t *testing.T) { - ctx := t.Context() - envMap := map[string]string{} - configFile := createTempFile(t, t.TempDir(), "config.tfrc", false) - ctx = env.Set(ctx, "DATABRICKS_TF_PROVIDER_VERSION", schema.ProviderVersion) - ctx = env.Set(ctx, "DATABRICKS_TF_CLI_CONFIG_FILE", configFile) - err := inheritEnvVars(ctx, envMap) - require.NoError(t, err) - require.Contains(t, envMap, "TF_CLI_CONFIG_FILE") - require.Equal(t, configFile, envMap["TF_CLI_CONFIG_FILE"]) -} - -func createFakeTerraformBinary(t *testing.T, dest, version string) string { - binPath := filepath.Join(dest, product.Terraform.BinaryName()) - jsonPayload := fmt.Sprintf(`{ - "terraform_version": "%s", - "provider_selections": {} -} -`, version) - - if runtime.GOOS == "windows" { - // Create stub with .exe that cannot be executed. - // We need it because the implementation looks for this file to see if it is cached. - createFakeTerraformBinaryWindows(t, binPath, jsonPayload, version) - // Create stub with .bat that can be executed. - // We use this path when setting the DATABRICKS_TF_EXEC_PATH environment variable. - createFakeTerraformBinaryWindows(t, binPath+".bat", jsonPayload, version) - // Return the .bat file that can be executed. - return binPath + ".bat" - } else { - return createFakeTerraformBinaryOther(t, binPath, jsonPayload, version) - } -} - -func createFakeTerraformBinaryWindows(t *testing.T, binPath, jsonPayload, version string) string { - f, err := os.Create(binPath) - require.NoError(t, err) - defer func() { - err = f.Close() - require.NoError(t, err) - }() - // Write the payload to a temp file and type it, to avoid escaping issues - tmpJsonPath := filepath.Join(t.TempDir(), "payload.json") - err = os.WriteFile(tmpJsonPath, []byte(jsonPayload), 0o644) - require.NoError(t, err) - _, err = fmt.Fprintf(f, `@echo off -REM This is a fake Terraform binary that returns the JSON payload. -REM It stubs version %s. -type "%s" -`, version, tmpJsonPath) - require.NoError(t, err) - return binPath -} - -func createFakeTerraformBinaryOther(t *testing.T, binPath, jsonPayload, version string) string { - f, err := os.Create(binPath) - require.NoError(t, err) - defer func() { - err = f.Close() - require.NoError(t, err) - }() - err = f.Chmod(0o777) - require.NoError(t, err) - _, err = fmt.Fprintf(f, `#!/bin/sh -# This is a fake Terraform binary that returns the JSON payload. -# It stubs version %s. -cat <..... - if !path.HasPrefix(prefix) || len(path) < 4 { - return dyn.InvalidValue, dynvar.ErrSkipResolution - } - - // Rewrite the bundle configuration path: - // - // ${resources.pipelines.my_pipeline.id} - // - // into the Terraform-compatible resource identifier: - // - // ${databricks_pipeline.my_pipeline.id} - // - resourceType := path[1].Key() - tfResourceName, ok := GroupToTerraformName[resourceType] - if !ok { - // Trigger "key not found" for unknown resource types. - return dyn.GetByPath(root, path) - } - - // Replace the resource type with the Terraform resource name. - path = dyn.NewPath(dyn.Key(tfResourceName)).Append(path[2:]...) - - // Postgres resources use "name" (resource path) instead of "id" as the identifier. - // Map .id references to .name for these resources so cross-resource references - // (like branch.parent -> project) resolve to the resource path format. - if isPostgresResource(resourceType) && len(path) >= 3 { - if lastKey := path[len(path)-1].Key(); lastKey == "id" { - path = path[:len(path)-1].Append(dyn.Key("name")) - } - } - - return dyn.V(fmt.Sprintf("${%s}", path.String())), nil - }) - }) - - return diag.FromErr(err) -} diff --git a/bundle/deploy/terraform/interpolate_test.go b/bundle/deploy/terraform/interpolate_test.go deleted file mode 100644 index 5d45b4d8fb6..00000000000 --- a/bundle/deploy/terraform/interpolate_test.go +++ /dev/null @@ -1,136 +0,0 @@ -package terraform - -import ( - "testing" - - "github.com/databricks/cli/bundle" - "github.com/databricks/cli/bundle/config" - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/databricks-sdk-go/service/jobs" - "github.com/databricks/databricks-sdk-go/service/ml" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestInterpolate(t *testing.T) { - b := &bundle.Bundle{ - Config: config.Root{ - Bundle: config.Bundle{ - Name: "example", - }, - Resources: config.Resources{ - Jobs: map[string]*resources.Job{ - "my_job": { - JobSettings: jobs.JobSettings{ - Tags: map[string]string{ - "other_pipeline": "${resources.pipelines.other_pipeline.id}", - "other_job": "${resources.jobs.other_job.id}", - "other_model": "${resources.models.other_model.id}", - "other_experiment": "${resources.experiments.other_experiment.id}", - "other_model_serving": "${resources.model_serving_endpoints.other_model_serving.id}", - "other_registered_model": "${resources.registered_models.other_registered_model.id}", - "other_schema": "${resources.schemas.other_schema.id}", - "other_volume": "${resources.volumes.other_volume.id}", - "other_cluster": "${resources.clusters.other_cluster.id}", - "other_dashboard": "${resources.dashboards.other_dashboard.id}", - "other_app": "${resources.apps.other_app.id}", - "other_sql_warehouse": "${resources.sql_warehouses.other_sql_warehouse.id}", - }, - Tasks: []jobs.Task{ - { - TaskKey: "my_task", - NotebookTask: &jobs.NotebookTask{ - BaseParameters: map[string]string{ - "model_name": "${resources.models.my_model.name}", - }, - }, - }, - }, - }, - }, - }, - Models: map[string]*resources.MlflowModel{ - "my_model": { - CreateModelRequest: ml.CreateModelRequest{ - Name: "my_model", - }, - }, - }, - }, - }, - } - - diags := bundle.Apply(t.Context(), b, Interpolate()) - require.NoError(t, diags.Error()) - - j := b.Config.Resources.Jobs["my_job"] - assert.Equal(t, "${databricks_pipeline.other_pipeline.id}", j.Tags["other_pipeline"]) - assert.Equal(t, "${databricks_job.other_job.id}", j.Tags["other_job"]) - assert.Equal(t, "${databricks_mlflow_model.other_model.id}", j.Tags["other_model"]) - assert.Equal(t, "${databricks_mlflow_experiment.other_experiment.id}", j.Tags["other_experiment"]) - assert.Equal(t, "${databricks_model_serving.other_model_serving.id}", j.Tags["other_model_serving"]) - assert.Equal(t, "${databricks_registered_model.other_registered_model.id}", j.Tags["other_registered_model"]) - assert.Equal(t, "${databricks_schema.other_schema.id}", j.Tags["other_schema"]) - assert.Equal(t, "${databricks_volume.other_volume.id}", j.Tags["other_volume"]) - assert.Equal(t, "${databricks_cluster.other_cluster.id}", j.Tags["other_cluster"]) - assert.Equal(t, "${databricks_dashboard.other_dashboard.id}", j.Tags["other_dashboard"]) - assert.Equal(t, "${databricks_app.other_app.id}", j.Tags["other_app"]) - assert.Equal(t, "${databricks_sql_endpoint.other_sql_warehouse.id}", j.Tags["other_sql_warehouse"]) - - m := b.Config.Resources.Models["my_model"] - assert.Equal(t, "my_model", m.Name) -} - -func TestInterpolatePostgresResourcesMapIdToName(t *testing.T) { - b := &bundle.Bundle{ - Config: config.Root{ - Resources: config.Resources{ - Jobs: map[string]*resources.Job{ - "my_job": { - JobSettings: jobs.JobSettings{ - Tags: map[string]string{ - "postgres_project_id": "${resources.postgres_projects.my_project.id}", - "postgres_branch_id": "${resources.postgres_branches.my_branch.id}", - "postgres_endpoint_id": "${resources.postgres_endpoints.my_endpoint.id}", - // name attribute should not be changed - "postgres_project_name": "${resources.postgres_projects.my_project.name}", - }, - }, - }, - }, - }, - }, - } - - diags := bundle.Apply(t.Context(), b, Interpolate()) - require.NoError(t, diags.Error()) - - j := b.Config.Resources.Jobs["my_job"] - // .id should be mapped to .name for postgres resources (resource path format) - assert.Equal(t, "${databricks_postgres_project.my_project.name}", j.Tags["postgres_project_id"]) - assert.Equal(t, "${databricks_postgres_branch.my_branch.name}", j.Tags["postgres_branch_id"]) - assert.Equal(t, "${databricks_postgres_endpoint.my_endpoint.name}", j.Tags["postgres_endpoint_id"]) - // .name reference should also remain .name - assert.Equal(t, "${databricks_postgres_project.my_project.name}", j.Tags["postgres_project_name"]) -} - -func TestInterpolateUnknownResourceType(t *testing.T) { - b := &bundle.Bundle{ - Config: config.Root{ - Resources: config.Resources{ - Jobs: map[string]*resources.Job{ - "my_job": { - JobSettings: jobs.JobSettings{ - Tags: map[string]string{ - "other_unknown": "${resources.unknown.other_unknown.id}", - }, - }, - }, - }, - }, - }, - } - - diags := bundle.Apply(t.Context(), b, Interpolate()) - assert.ErrorContains(t, diags.Error(), `reference does not exist: ${resources.unknown.other_unknown.id}`) -} diff --git a/bundle/deploy/terraform/lifecycle_test.go b/bundle/deploy/terraform/lifecycle_test.go deleted file mode 100644 index 508d9610f87..00000000000 --- a/bundle/deploy/terraform/lifecycle_test.go +++ /dev/null @@ -1,66 +0,0 @@ -package terraform - -import ( - "encoding/json" - "testing" - - "github.com/databricks/cli/bundle/config" - "github.com/databricks/cli/libs/dyn" - "github.com/stretchr/testify/require" -) - -func TestConvertLifecycleForAllResources(t *testing.T) { - supportedResources := config.SupportedResources() - ctx := t.Context() - - // Resources that are only supported in direct mode and should not be converted to Terraform - ignoredResources := []string{ - "catalogs", - "cluster_policies", - "external_locations", - "genie_spaces", - "instance_pools", - "job_runs", - // The Terraform provider has no resource that maps to a snapshot schedule, - // so it is deployed through the direct engine only (see the resource's - // acceptance test.toml). - "postgres_snapshot_schedules", - // AI Gateway model service is deployed through the direct engine only. - "model_services", - "mcp_services", - "model_provider_services", - "secrets", - "vector_search_endpoints", - "vector_search_indexes", - "internal_immutable_snapshots", - } - - for resourceType := range supportedResources { - t.Run(resourceType, func(t *testing.T) { - for _, ignored := range ignoredResources { - if resourceType == ignored { - t.Skipf("%s is only supported in direct mode", resourceType) - } - } - - vin := dyn.NewValue(map[string]dyn.Value{ - "resources": dyn.NewValue(map[string]dyn.Value{ - resourceType: dyn.NewValue(map[string]dyn.Value{ - "test_resource": dyn.NewValue(map[string]dyn.Value{ - "lifecycle": dyn.NewValue(map[string]dyn.Value{ - "prevent_destroy": dyn.NewValue(true, nil), - }, nil), - }, nil), - }, nil), - }, nil), - }, nil) - - tfroot, err := BundleToTerraformWithDynValue(ctx, vin, false) - require.NoError(t, err) - - bytes, err := json.Marshal(tfroot.Resource) - require.NoError(t, err) - require.Contains(t, string(bytes), `"lifecycle":{"prevent_destroy":true}`) - }) - } -} diff --git a/bundle/deploy/terraform/plan.go b/bundle/deploy/terraform/plan.go deleted file mode 100644 index 660cd0ba34b..00000000000 --- a/bundle/deploy/terraform/plan.go +++ /dev/null @@ -1,61 +0,0 @@ -package terraform - -import ( - "context" - "path/filepath" - - "github.com/databricks/cli/bundle" - "github.com/databricks/cli/libs/diag" - "github.com/databricks/cli/libs/log" - "github.com/hashicorp/terraform-exec/tfexec" -) - -type PlanGoal string - -var ( - PlanDeploy = PlanGoal("deploy") - PlanDestroy = PlanGoal("destroy") -) - -type plan struct { - goal PlanGoal -} - -func (p *plan) Name() string { - return "terraform.Plan" -} - -func (p *plan) Apply(ctx context.Context, b *bundle.Bundle) diag.Diagnostics { - diags := Initialize(ctx, b) - if diags.HasError() { - return diags - } - - // Persist computed plan - tfDir, err := Dir(ctx, b) - if err != nil { - return diag.FromErr(err) - } - planPath := filepath.Join(tfDir, "plan") - destroy := p.goal == PlanDestroy - - notEmpty, err := b.Terraform.Plan(ctx, tfexec.Destroy(destroy), tfexec.Out(planPath)) - if err != nil { - return diag.FromErr(err) - } - - // Set plan in main bundle struct for downstream mutators - b.TerraformPlanPath = planPath - b.TerraformPlanIsEmpty = !notEmpty - - log.Debugf(ctx, "Planning complete and persisted at %s\n", planPath) - return diags -} - -// Plan returns a [bundle.Mutator] that runs the equivalent of `terraform plan -out ./plan` -// from the bundle's ephemeral working directory for Terraform. -func Plan(goal PlanGoal) bundle.Mutator { - return &plan{ - goal: goal, - } -} diff --git a/bundle/deploy/terraform/pubkey.go b/bundle/deploy/terraform/pubkey.go deleted file mode 100644 index e7609056524..00000000000 --- a/bundle/deploy/terraform/pubkey.go +++ /dev/null @@ -1,137 +0,0 @@ -package terraform - -// hashicorpPublicKey is HashiCorp's release-signing public key with self-signatures -// refreshed on 2026-02-19 (expiration extended to ~2035). -// -// The embedded key in hc-install v0.9.3 has a UserID self-signature that expired -// on 2026-04-18, which breaks Terraform checksum verification. hc-install#355 -// added refreshed signatures, but go-crypto v1 only reads the first armored -// block and keeps one SelfSignature per Identity, so the fix is a no-op when -// relying on the embedded key. We pass this refreshed block to -// releases.ExactVersion.ArmoredPublicKey directly. -// -// Source: https://github.com/hashicorp/hc-install/blob/main/internal/pubkey/pubkey.go -// -// (second -----BEGIN PGP PUBLIC KEY BLOCK----- block, added in PR #355) -const hashicorpPublicKey = `-----BEGIN PGP PUBLIC KEY BLOCK----- - -mQINBGB9+xkBEACabYZOWKmgZsHTdRDiyPJxhbuUiKX65GUWkyRMJKi/1dviVxOX -PG6hBPtF48IFnVgxKpIb7G6NjBousAV+CuLlv5yqFKpOZEGC6sBV+Gx8Vu1CICpl -Zm+HpQPcIzwBpN+Ar4l/exCG/f/MZq/oxGgH+TyRF3XcYDjG8dbJCpHO5nQ5Cy9h -QIp3/Bh09kET6lk+4QlofNgHKVT2epV8iK1cXlbQe2tZtfCUtxk+pxvU0UHXp+AB -0xc3/gIhjZp/dePmCOyQyGPJbp5bpO4UeAJ6frqhexmNlaw9Z897ltZmRLGq1p4a -RnWL8FPkBz9SCSKXS8uNyV5oMNVn4G1obCkc106iWuKBTibffYQzq5TG8FYVJKrh -RwWB6piacEB8hl20IIWSxIM3J9tT7CPSnk5RYYCTRHgA5OOrqZhC7JefudrP8n+M -pxkDgNORDu7GCfAuisrf7dXYjLsxG4tu22DBJJC0c/IpRpXDnOuJN1Q5e/3VUKKW -mypNumuQpP5lc1ZFG64TRzb1HR6oIdHfbrVQfdiQXpvdcFx+Fl57WuUraXRV6qfb -4ZmKHX1JEwM/7tu21QE4F1dz0jroLSricZxfaCTHHWNfvGJoZ30/MZUrpSC0IfB3 -iQutxbZrwIlTBt+fGLtm3vDtwMFNWM+Rb1lrOxEQd2eijdxhvBOHtlIcswARAQAB -tERIYXNoaUNvcnAgU2VjdXJpdHkgKGhhc2hpY29ycC5jb20vc2VjdXJpdHkpIDxz -ZWN1cml0eUBoYXNoaWNvcnAuY29tPokCVAQTAQoAPgIbAwULCQgHAgYVCgkICwIE -FgIDAQIeAQIXgBYhBMh0AR8KtAURDQIQVTQ2XZRy10aPBQJplkfQBQkQrOy3AAoJ -EDQ2XZRy10aPw6gP/3GUEMUa6mCRuuSOT9UnziPIvXYd63mcN6A6Jwmwj8JaB2qu -OCijvJkw56UbZK3x1FZIbe0hA6VUAwNSNmSIxVJkilgwIYYFO0tnL79XhIeP7jYF -ydXLZ4rTi1FDl8lltAujTNARdY8UGg4hGlcM9OrEeXEFLWugJNiChL15FVoxZqIS -jeduaEqyxGfJnyVwy8z3pZfgODeFr7xs2NkUIMSfuRg24VcL4aW8Frt3jW8P45y3 -o/5fsi6Aw2tZ0wD9NSgkVc8VD1NRV9eSZ95Bv+Awf9IXa+Cn5OCjc8Jc+XF+nLfB -oPswOO7E8dLiuBUw6/GzSLMbVs8qf8BNXB92dOe1VccVTqjCxK2sEpVaHh7e+co8 -d8lDGBIWMGh7NS6XlGORpFb/T6gxjjOYUV3SKd4QDebUUG8kMkb5juLljOoq+YOP -vgNLDZLZteFpmH+zB9DpOY1YtHZB/OD+DtzLMaSl6VPF2Ln0j5aQGwNDt7sheyAe -sXbu0qn2H5FxojSfvhT0kUDKZ0mgg5y3Oflg49MiAOhjLGY0JocFpBeMILw27fbw -fpIBP7siQWFTFJ1O+l2NQiWAwC2x5fX2EakyCBJmrkPV2hr4nEogNqg9/RDskIUq -cpcOOd/0BntiXMyUCCH2AoCt5acaTQ0WU6CAosZPojOYhtGGgOgeQSdflpMSuQIN -BGB9+xkBEACoklYsfvWRCjOwS8TOKBTfl8myuP9V9uBNbyHufzNETbhYeT33Cj0M -GCNd9GdoaknzBQLbQVSQogA+spqVvQPz1MND18GIdtmr0BXENiZE7SRvu76jNqLp -KxYALoK2Pc3yK0JGD30HcIIgx+lOofrVPA2dfVPTj1wXvm0rbSGA4Wd4Ng3d2AoR -G/wZDAQ7sdZi1A9hhfugTFZwfqR3XAYCk+PUeoFrkJ0O7wngaon+6x2GJVedVPOs -2x/XOR4l9ytFP3o+5ILhVnsK+ESVD9AQz2fhDEU6RhvzaqtHe+sQccR3oVLoGcat -ma5rbfzH0Fhj0JtkbP7WreQf9udYgXxVJKXLQFQgel34egEGG+NlbGSPG+qHOZtY -4uWdlDSvmo+1P95P4VG/EBteqyBbDDGDGiMs6lAMg2cULrwOsbxWjsWka8y2IN3z -1stlIJFvW2kggU+bKnQ+sNQnclq3wzCJjeDBfucR3a5WRojDtGoJP6Fc3luUtS7V -5TAdOx4dhaMFU9+01OoH8ZdTRiHZ1K7RFeAIslSyd4iA/xkhOhHq89F4ECQf3Bt4 -ZhGsXDTaA/VgHmf3AULbrC94O7HNqOvTWzwGiWHLfcxXQsr+ijIEQvh6rHKmJK8R -9NMHqc3L18eMO6bqrzEHW0Xoiu9W8Yj+WuB3IKdhclT3w0pO4Pj8gQARAQABiQI8 -BBgBCgAmAhsMFiEEyHQBHwq0BRENAhBVNDZdlHLXRo8FAmmWR+0FCRCs7NQACgkQ -NDZdlHLXRo/R0A//QW1opBlzWSmWww1q9QuJA2WCIIs8tJKRDOsmgJPscNpzwZFU -N1Df0wWNjqi1BDReei7lZTHwUk+ebBn0bkI3ANmmgYg7LBueAt5UWSingOc+rvKA -N32BDzBYkMckRzJSQsmeC5hm3J3wLSy90uaIlrJJE9GJZkf/W2Ob+4SQZZ+dnnRP -JokDdW1DuZS9PbxSLJKD5eIWHBxJnFM1CmHfOfrjTJ+MYvVGM5sxSY8R7E+GADj5 -L/i4N+tTFJLuTMYARGfA6d+KPKcMJtgpUPjSMAg8nGUhukctpuBs27mOKW0CBtmJ -82X/qYROTL0+vGTvUYflYiuceVlhX/kw0JZnMaG5V/mpHq8SwD07pCGOf69j/mNa -5EL3++Pmzg0s0stw3Ea5pCN0cL/nKkoWchHBfW15W4JOnKAIspyD1vH670P4WfeV -E9B9d6tgKSbM/9JlXoQS5ZdG+kbdosieELhmVWmvojyK7K+Ry6C9wgd+UfnW5jXd -iNwKW3KHuautQwlFhHRNMyDg08c+pI5emTMT3IUQyGWo+Gska3TqGujFcABx7Ip+ -mHNmMrCkSD+XC2bvzvRR7FcM0/B9fsjLX/Wttm5vRJ1d2oAoEPvw2IZnJIXpOt2z -zo55sJTztNu4lWGgDVgtp9SXO5a0E5YvFHQNZN5QLeVTTFu6I7qG+ME1E/K5Ag0E -YH3+JQEQALivllTjMolxUW2OxrXb+a2Pt6vjCBsiJzrUj0Pa63U+lT9jldbCCfgP -wDpcDuO1O05Q8k1MoYZ6HddjWnqKG7S3eqkV5c3ct3amAXp513QDKZUfIDylOmhU -qvxjEgvGjdRjz6kECFGYr6Vnj/p6AwWv4/FBRFlrq7cnQgPynbIH4hrWvewp3Tqw -GVgqm5RRofuAugi8iZQVlAiQZJo88yaztAQ/7VsXBiHTn61ugQ8bKdAsr8w/ZZU5 -HScHLqRolcYg0cKN91c0EbJq9k1LUC//CakPB9mhi5+aUVUGusIM8ECShUEgSTCi -KQiJUPZ2CFbbPE9L5o9xoPCxjXoX+r7L/WyoCPTeoS3YRUMEnWKvc42Yxz3meRb+ -BmaqgbheNmzOah5nMwPupJYmHrjWPkX7oyyHxLSFw4dtoP2j6Z7GdRXKa2dUYdk2 -x3JYKocrDoPHh3Q0TAZujtpdjFi1BS8pbxYFb3hHmGSdvz7T7KcqP7ChC7k2RAKO -GiG7QQe4NX3sSMgweYpl4OwvQOn73t5CVWYp/gIBNZGsU3Pto8g27vHeWyH9mKr4 -cSepDhw+/X8FGRNdxNfpLKm7Vc0Sm9Sof8TRFrBTqX+vIQupYHRi5QQCuYaV6OVr -ITeegNK3So4m39d6ajCR9QxRbmjnx9UcnSYYDmIB6fpBuwT0ogNtABEBAAGJBHIE -GAEKACYCGwIWIQTIdAEfCrQFEQ0CEFU0Nl2UctdGjwUCYH4bgAUJAeFQ2wJAwXQg -BBkBCgAdFiEEs2y6kaLAcwxDX8KAsLRBCXaFtnYFAmB9/iUACgkQsLRBCXaFtnYX -BhAAlxejyFXoQwyGo9U+2g9N6LUb/tNtH29RHYxy4A3/ZUY7d/FMkArmh4+dfjf0 -p9MJz98Zkps20kaYP+2YzYmaizO6OA6RIddcEXQDRCPHmLts3097mJ/skx9qLAf6 -rh9J7jWeSqWO6VW6Mlx8j9m7sm3Ae1OsjOx/m7lGZOhY4UYfY627+Jf7WQ5103Qs -lgQ09es/vhTCx0g34SYEmMW15Tc3eCjQ21b1MeJD/V26npeakV8iCZ1kHZHawPq/ -aCCuYEcCeQOOteTWvl7HXaHMhHIx7jjOd8XX9V+UxsGz2WCIxX/j7EEEc7CAxwAN -nWp9jXeLfxYfjrUB7XQZsGCd4EHHzUyCf7iRJL7OJ3tz5Z+rOlNjSgci+ycHEccL -YeFAEV+Fz+sj7q4cFAferkr7imY1XEI0Ji5P8p/uRYw/n8uUf7LrLw5TzHmZsTSC -UaiL4llRzkDC6cVhYfqQWUXDd/r385OkE4oalNNE+n+txNRx92rpvXWZ5qFYfv7E -95fltvpXc0iOugPMzyof3lwo3Xi4WZKc1CC/jEviKTQhfn3WZukuF5lbz3V1PQfI -xFsYe9WYQmp25XGgezjXzp89C/OIcYsVB1KJAKihgbYdHyUN4fRCmOszmOUwEAKR -3k5j4X8V5bk08sA69NVXPn2ofxyk3YYOMYWW8ouObnXoS8QJEDQ2XZRy10aPMpsQ -AIbwX21erVqUDMPn1uONP6o4NBEq4MwG7d+fT85rc1U0RfeKBwjucAE/iStZDQoM -ZKWvGhFR+uoyg1LrXNKuSPB82unh2bpvj4zEnJsJadiwtShTKDsikhrfFEK3aCK8 -Zuhpiu3jxMFDhpFzlxsSwaCcGJqcdwGhWUx0ZAVD2X71UCFoOXPjF9fNnpy80YNp -flPjj2RnOZbJyBIM0sWIVMd8F44qkTASf8K5Qb47WFN5tSpePq7OCm7s8u+lYZGK -wR18K7VliundR+5a8XAOyUXOL5UsDaQCK4Lj4lRaeFXunXl3DJ4E+7BKzZhReJL6 -EugV5eaGonA52TWtFdB8p+79wPUeI3KcdPmQ9Ll5Zi/jBemY4bzasmgKzNeMtwWP -fk6WgrvBwptqohw71HDymGxFUnUP7XYYjic2sVKhv9AevMGycVgwWBiWroDCQ9Ja -btKfxHhI2p+g+rcywmBobWJbZsujTNjhtme+kNn1mhJsD3bKPjKQfAxaTskBLb0V -wgV21891TS1Dq9kdPLwoS4XNpYg2LLB4p9hmeG3fu9+OmqwY5oKXsHiWc43dei9Y -yxZ1AAUOIaIdPkq+YG/PhlGE4YcQZ4RPpltAr0HfGgZhmXWigbGS+66pUj+Ojysc -j0K5tCVxVu0fhhFpOlHv0LWaxCbnkgkQH9jfMEJkAWMOuQINBGCAXCYBEADW6RNr -ZVGNXvHVBqSiOWaxl1XOiEoiHPt50Aijt25yXbG+0kHIFSoR+1g6Lh20JTCChgfQ -kGGjzQvEuG1HTw07YhsvLc0pkjNMfu6gJqFox/ogc53mz69OxXauzUQ/TZ27GDVp -UBu+EhDKt1s3OtA6Bjz/csop/Um7gT0+ivHyvJ/jGdnPEZv8tNuSE/Uo+hn/Q9hg -8SbveZzo3C+U4KcabCESEFl8Gq6aRi9vAfa65oxD5jKaIz7cy+pwb0lizqlW7H9t -Qlr3dBfdIcdzgR55hTFC5/XrcwJ6/nHVH/xGskEasnfCQX8RYKMuy0UADJy72TkZ -bYaCx+XXIcVB8GTOmJVoAhrTSSVLAZspfCnjwnSxisDn3ZzsYrq3cV6sU8b+QlIX -7VAjurE+5cZiVlaxgCjyhKqlGgmonnReWOBacCgL/UvuwMmMp5TTLmiLXLT7uxeG -ojEyoCk4sMrqrU1jevHyGlDJH9Taux15GILDwnYFfAvPF9WCid4UZ4Ouwjcaxfys -3LxNiZIlUsXNKwS3mhiMRL4TRsbs4k4QE+LIMOsauIvcvm8/frydvQ/kUwIhVTH8 -0XGOH909bYtJvY3fudK7ShIwm7ZFTduBJUG473E/Fn3VkhTmBX6+PjOC50HR/Hyb -waRCzfDruMe3TAcE/tSP5CUOb9C7+P+hPzQcDwARAQABiQRyBBgBCgAmAhsCFiEE -yHQBHwq0BRENAhBVNDZdlHLXRo8FAmmWSAoFCRCqi+QCQMF0IAQZAQoAHRYhBDdO -x1tIWRNgSoMcx8ggxtXNJ6uHBQJggFwmAAoJEMggxtXNJ6uHRfAP/2CGdSyg0K7U -66Vygl0dugxrMm8O3/Oe211BKdQsFUSWAznOTRTK/zvMUHO4LJAlYvdtZ6xDa4XH -l9FYQ8MR9ZV0OuOlAZvU4IJDLPVCU09X/UzX/GEoZL0R5esvwPAXopMaRHCfXJeI -/gEaB94UhAeYlwpcRn0eSuk1vyZx7GRE6/hog8DCf4hoT40dW20gGe58xcvJ+mRY -lC0lr16WH08wuUcee6+dgu+4Cg6SG6+zt9cMyl8VnTUL5BK/V3MebnYZJK0RFDNn -nXDhzStgOd5gOeIL+xBPXHd0/ld/rDM74SFExpuS+hNsyo+xMQ/HJavak21MFinu -l9COwfGEmlAXTGMY30Lf3Pt/eAkbwgmGc966VSoRmOFEXJVlDr+yJR6ru+7j50z8 -lAv6Lsop7sun1Qysbo0swf6W1qgPf6VWbx91NTFLkw0+gD8jxwrU5ZMkeSuntX9d -pjuZS29CflXXIRPlvhuiDPicwTpYuIUx37vHveAH5gnowZg247x780Urrsx8duTX -8CI9MAnqzm4dFAiRlwE8bvLk+l9wekiXA9gIMZiVNqNlduXIqvAG21Wdgq8qyeXK -y/XWCVKDQOmEbFAltfNam8E3KEw0fl199x+93d5ckDGcPzUYPbNkCuIwngC/ZN96 -pDafF3Z12fSNfhZUe0C8td8KAszYa96GCRA0Nl2UctdGj1gKD/4jOGhEGTg88Vyu -PVjeK+zkwrTIZSvHdUHfTt/+rTLSNb/RQiBCUQuEZvafj6FrntS7bAEhccGqH894 -T3St5K0AXWkvsLd6K+cbIQdlnFA2zb6geJUCk6qx5NgWpRc3i0DS7CheGwl+Bwu7 -+n9pNjNjiHV+rYDgqbQXG0dtGysB0/3qIRgEDHFO0HJu/dcte4oXrQIqrZrpOwe8 -WxqFqdU918JpSUcc8coiFp9YtwpgqQNxGVZ+rhgnTGdZzk1f/Yhhimh+2B0ReaFv -k3UzVBj3HQ9C6+Ot3MyDEhSgdhjr9e25Tm9S5YfhwtWmghRw9RKPyLMSXSxm/Uc0 -mK1NucAp8TQBwKqKzNpCk5IdrBSWRUbjOoOFyzyCsY6gS285GCpSIzI39hTf+3gd -wYPlE6fj+F2TZzdhx62DPnzBzBHnByYTVdJ649bx0FFp4Q+5TbIWtxu/AQkRDxmW -NQfE+6GgeshlrhXWsh6+PGDzt+2raG6zUT913sdz7Ctw4fLjmsKOTdTz3Xa9pr8l -xfI/JuukSgt9o/n3GirhTB3zE1w/I/Xt6k7oASiP3zQSuHtB/CYKYHDtOCWwjo7J -PEGtb/FkreKNxsk/p20jnlrB8WZxxswdr2Vri9NmFeyMDVX7qF3WqT+8aCV9GtS1 -GCHx/5nGBdDwoxEsXqpI3IUqPb6FDg== -=wtp+ ------END PGP PUBLIC KEY BLOCK-----` diff --git a/bundle/deploy/terraform/showplanfile.go b/bundle/deploy/terraform/showplanfile.go deleted file mode 100644 index 5df56ff57b9..00000000000 --- a/bundle/deploy/terraform/showplanfile.go +++ /dev/null @@ -1,165 +0,0 @@ -package terraform - -import ( - "context" - "strings" - - "github.com/databricks/cli/bundle/deployplan" - "github.com/databricks/cli/libs/log" - "github.com/hashicorp/terraform-exec/tfexec" - tfjson "github.com/hashicorp/terraform-json" -) - -var prefixToGroup = []struct{ prefix, group string }{ - {"job_", "jobs"}, - {"pipeline_", "pipelines"}, - {"mlflow_experiment_", "experiments"}, - {"mlflow_model_", "models"}, - {"cluster_", "clusters"}, - {"app_", "apps"}, - {"dashboard_", "dashboards"}, - {"alert_", "alerts"}, - {"model_serving_", "model_serving_endpoints"}, - {"sql_endpoint_", "sql_warehouses"}, - {"database_instance_", "database_instances"}, - {"postgres_project_", "postgres_projects"}, -} - -var grantsPrefix = []struct{ prefix, group string }{ - {"schema_", "schemas"}, - {"volume_", "volumes"}, - {"registered_model_", "registered_models"}, -} - -// convertPermissionResourceNameToKey converts terraform permission resource names back to hierarchical resource keys -// e.g., "mlflow_experiment_foo" -> "resources.experiments.foo.permissions" -func convertPermissionsResourceNameToKey(terraformName string) string { - for _, pg := range prefixToGroup { - if resourceName, found := strings.CutPrefix(terraformName, pg.prefix); found { - return "resources." + pg.group + "." + resourceName + ".permissions" - } - } - - // Fallback: if no known prefix is found, use the old behavior - return "" -} - -// convertGrantsResourceNameToKey converts terraform grants resource names back to hierarchical resource keys -// e.g., "schema_foo" -> "resources.schemas.foo.grants" -func convertGrantsResourceNameToKey(terraformName string) string { - for _, gp := range grantsPrefix { - if resourceName, found := strings.CutPrefix(terraformName, gp.prefix); found { - return "resources." + gp.group + "." + resourceName + ".grants" - } - } - - // Fallback: if no known prefix is found, use the old behavior - return "" -} - -// convertSecretAclNameToScopeKey converts terraform secret ACL resource names to scope permission keys. -// ACL names have format "secret_acl__" (see convert_secret_scope.go). -// e.g., "secret_acl_my_scope_0" -> "resources.secret_scopes.my_scope.permissions" -func convertSecretAclNameToScopeKey(name string) string { - name, _ = strings.CutPrefix(name, "secret_acl_") - if i := strings.LastIndex(name, "_"); i >= 0 { - name = name[:i] - } - return "resources.secret_scopes." + name + ".permissions" -} - -// populatePlan populates a deployplan.Plan from Terraform resource changes. -func populatePlan(ctx context.Context, plan *deployplan.Plan, changes []*tfjson.ResourceChange) { - for _, rc := range changes { - if rc.Change == nil { - continue - } - - var actionType deployplan.ActionType - switch { - case rc.Change.Actions.Delete(): - actionType = deployplan.Delete - case rc.Change.Actions.Replace(): - actionType = deployplan.Recreate - case rc.Change.Actions.Create(): - actionType = deployplan.Create - case rc.Change.Actions.Update(): - actionType = deployplan.Update - case rc.Change.Actions.NoOp(): - actionType = deployplan.Skip - default: - continue - } - - group, ok := TerraformToGroupName[rc.Type] - if !ok { - log.Warnf(ctx, "unknown resource type '%s'", rc.Type) - continue - } - - var key string - switch group { - case "permissions": - key = convertPermissionsResourceNameToKey(rc.Name) - case "grants": - key = convertGrantsResourceNameToKey(rc.Name) - case "secret_acls": - key = convertSecretAclNameToScopeKey(rc.Name) - default: - key = "resources." + group + "." + rc.Name - } - - if existing, ok := plan.Plan[key]; ok { - // For secret ACLs, multiple individual ACL changes are merged into a single - // scope-level permissions entry. When the actions differ (e.g., some ACLs are - // recreated while others are deleted), it means permissions are being updated, - // not deleted entirely. - if group == "secret_acls" && existing.Action != actionType { - existing.Action = deployplan.Update - } else { - existing.Action = deployplan.GetHigherAction(existing.Action, actionType) - } - existing.StateOnly = isStateOnlyDelete(group, existing.Action) - } else { - plan.Plan[key] = &deployplan.PlanEntry{ - Action: actionType, - StateOnly: isStateOnlyDelete(group, actionType), - } - } - } -} - -// isStateOnlyDelete reports whether deleting a resource of this group has no -// backend effect, so a planned Delete is a state-only cleanup. The direct engine -// derives this from the resource omitting DoDelete (see dresources.Adapter.HasDoDelete -// and PlanEntry.StateOnly); the terraform engine has no adapters here, so the set is -// mirrored by group. TestStateOnlyGroupsMatchDirect guards the two against drift. -// -// Note this only suppresses these deletes from plan/deploy output and counts to keep -// the two engines consistent — it does not change what terraform applies (terraform -// still revokes grants / resets permissions on delete). -func isStateOnlyDelete(group string, action deployplan.ActionType) bool { - if action != deployplan.Delete { - return false - } - switch group { - case "permissions", "grants", "secret_acls": - return true - default: - return false - } -} - -// ShowPlanFile reads a Terraform plan file located at planPath using the provided tfexec.Terraform handle -// and converts it into a deployplan.Plan. -func ShowPlanFile(ctx context.Context, tf *tfexec.Terraform, planPath string) (*deployplan.Plan, error) { - tfPlan, err := tf.ShowPlanFile(ctx, planPath) - if err != nil { - return nil, err - } - - plan := deployplan.NewPlanTerraform() - populatePlan(ctx, plan, tfPlan.ResourceChanges) - - return plan, nil -} diff --git a/bundle/deploy/terraform/showplanfile_test.go b/bundle/deploy/terraform/showplanfile_test.go deleted file mode 100644 index 5c4426f6650..00000000000 --- a/bundle/deploy/terraform/showplanfile_test.go +++ /dev/null @@ -1,164 +0,0 @@ -package terraform - -import ( - "testing" - - "github.com/databricks/cli/bundle/deployplan" - tfjson "github.com/hashicorp/terraform-json" - "github.com/stretchr/testify/assert" -) - -func TestPopulatePlan(t *testing.T) { - ctx := t.Context() - changes := []*tfjson.ResourceChange{ - { - Type: "databricks_pipeline", - Change: &tfjson.Change{ - Actions: tfjson.Actions{tfjson.ActionCreate}, - }, - Name: "create pipeline", - }, - { - Type: "databricks_pipeline", - Change: &tfjson.Change{ - Actions: tfjson.Actions{tfjson.ActionDelete}, - }, - Name: "delete pipeline", - }, - { - Type: "databricks_pipeline", - Change: &tfjson.Change{ - Actions: tfjson.Actions{tfjson.ActionDelete, tfjson.ActionCreate}, - }, - Name: "recreate pipeline", - }, - { - Type: "databricks_whatever", - Change: &tfjson.Change{ - Actions: tfjson.Actions{tfjson.ActionDelete, tfjson.ActionCreate}, - }, - Name: "recreate whatever", - }, - } - - plan := deployplan.NewPlanTerraform() - populatePlan(ctx, plan, changes) - - actions := plan.GetActions() - - // Assert that the actions list contains all expected actions - expectedActions := []deployplan.Action{ - { - ActionType: deployplan.Create, - ResourceKey: "resources.pipelines.create pipeline", - }, - { - ActionType: deployplan.Delete, - ResourceKey: "resources.pipelines.delete pipeline", - }, - { - ActionType: deployplan.Recreate, - ResourceKey: "resources.pipelines.recreate pipeline", - }, - } - assert.Equal(t, expectedActions, actions) - - // Also test that the plan was populated correctly with expected entries - assert.Contains(t, plan.Plan, "resources.pipelines.create pipeline") - assert.Equal(t, deployplan.Create, plan.Plan["resources.pipelines.create pipeline"].Action) - - assert.Contains(t, plan.Plan, "resources.pipelines.delete pipeline") - assert.Equal(t, deployplan.Delete, plan.Plan["resources.pipelines.delete pipeline"].Action) - - assert.Contains(t, plan.Plan, "resources.pipelines.recreate pipeline") - assert.Equal(t, deployplan.Recreate, plan.Plan["resources.pipelines.recreate pipeline"].Action) - - // Unknown resource type should not be in the plan - assert.NotContains(t, plan.Plan, "resources.recreate whatever") -} - -func TestPopulatePlanSecretAcl(t *testing.T) { - ctx := t.Context() - changes := []*tfjson.ResourceChange{ - { - Type: "databricks_secret_acl", - Change: &tfjson.Change{Actions: tfjson.Actions{tfjson.ActionCreate}}, - Name: "secret_acl_my_scope_0", - }, - { - Type: "databricks_secret_acl", - Change: &tfjson.Change{Actions: tfjson.Actions{tfjson.ActionDelete, tfjson.ActionCreate}}, - Name: "secret_acl_my_scope_1", - }, - } - - plan := deployplan.NewPlanTerraform() - populatePlan(ctx, plan, changes) - - // Multiple ACL changes for the same scope with different actions are merged as Update. - assert.Equal(t, map[string]*deployplan.PlanEntry{ - "resources.secret_scopes.my_scope.permissions": {Action: deployplan.Update}, - }, plan.Plan) -} - -func TestPopulatePlanSecretAclMixedCreateDelete(t *testing.T) { - ctx := t.Context() - changes := []*tfjson.ResourceChange{ - { - Type: "databricks_secret_acl", - Change: &tfjson.Change{Actions: tfjson.Actions{tfjson.ActionDelete}}, - Name: "secret_acl_my_scope_0", - }, - { - Type: "databricks_secret_acl", - Change: &tfjson.Change{Actions: tfjson.Actions{tfjson.ActionCreate}}, - Name: "secret_acl_my_scope_1", - }, - } - - plan := deployplan.NewPlanTerraform() - populatePlan(ctx, plan, changes) - - assert.Equal(t, map[string]*deployplan.PlanEntry{ - "resources.secret_scopes.my_scope.permissions": {Action: deployplan.Update}, - }, plan.Plan) -} - -func TestPopulatePlanSecretAclMixedRecreateDelete(t *testing.T) { - ctx := t.Context() - // Simulates a permission update where some ACLs are recreated (principal changed) - // and some are deleted (principal removed). This is the typical Terraform plan shape - // when updating secret scope permissions. - changes := []*tfjson.ResourceChange{ - { - Type: "databricks_secret_acl", - Change: &tfjson.Change{Actions: tfjson.Actions{tfjson.ActionDelete, tfjson.ActionCreate}}, - Name: "secret_acl_my_scope_0", - }, - { - Type: "databricks_secret_acl", - Change: &tfjson.Change{Actions: tfjson.Actions{tfjson.ActionDelete, tfjson.ActionCreate}}, - Name: "secret_acl_my_scope_1", - }, - { - Type: "databricks_secret_acl", - Change: &tfjson.Change{Actions: tfjson.Actions{tfjson.ActionDelete}}, - Name: "secret_acl_my_scope_2", - }, - } - - plan := deployplan.NewPlanTerraform() - populatePlan(ctx, plan, changes) - - // When permissions are being updated (some ACLs recreated, some deleted), - // the aggregated action should be Update, not Delete. - assert.Equal(t, map[string]*deployplan.PlanEntry{ - "resources.secret_scopes.my_scope.permissions": {Action: deployplan.Update}, - }, plan.Plan) -} - -func TestConvertSecretAclNameToScopeKey(t *testing.T) { - assert.Equal(t, "resources.secret_scopes.my_scope.permissions", convertSecretAclNameToScopeKey("secret_acl_my_scope_0")) - assert.Equal(t, "resources.secret_scopes.my_scope.permissions", convertSecretAclNameToScopeKey("secret_acl_my_scope_1")) - assert.Equal(t, "resources.secret_scopes.scope_123.permissions", convertSecretAclNameToScopeKey("secret_acl_scope_123_2")) -} diff --git a/bundle/deploy/terraform/statemap.go b/bundle/deploy/terraform/statemap.go new file mode 100644 index 00000000000..510fded2cc5 --- /dev/null +++ b/bundle/deploy/terraform/statemap.go @@ -0,0 +1,58 @@ +package terraform + +import "strings" + +// BindOptions configures binding a bundle resource to an existing remote resource. +type BindOptions struct { + AutoApprove bool + ResourceType string + ResourceKey string + ResourceId string +} + +var prefixToGroup = []struct{ prefix, group string }{ + {"job_", "jobs"}, + {"pipeline_", "pipelines"}, + {"mlflow_experiment_", "experiments"}, + {"mlflow_model_", "models"}, + {"cluster_", "clusters"}, + {"app_", "apps"}, + {"dashboard_", "dashboards"}, + {"alert_", "alerts"}, + {"model_serving_", "model_serving_endpoints"}, + {"sql_endpoint_", "sql_warehouses"}, + {"database_instance_", "database_instances"}, + {"postgres_project_", "postgres_projects"}, +} + +var grantsPrefix = []struct{ prefix, group string }{ + {"schema_", "schemas"}, + {"volume_", "volumes"}, + {"registered_model_", "registered_models"}, +} + +// convertPermissionsResourceNameToKey converts terraform permission resource names back to hierarchical resource keys +// e.g., "mlflow_experiment_foo" -> "resources.experiments.foo.permissions" +func convertPermissionsResourceNameToKey(terraformName string) string { + for _, pg := range prefixToGroup { + if resourceName, found := strings.CutPrefix(terraformName, pg.prefix); found { + return "resources." + pg.group + "." + resourceName + ".permissions" + } + } + + // Fallback: if no known prefix is found, use the old behavior + return "" +} + +// convertGrantsResourceNameToKey converts terraform grants resource names back to hierarchical resource keys +// e.g., "schema_foo" -> "resources.schemas.foo.grants" +func convertGrantsResourceNameToKey(terraformName string) string { + for _, gp := range grantsPrefix { + if resourceName, found := strings.CutPrefix(terraformName, gp.prefix); found { + return "resources." + gp.group + "." + resourceName + ".grants" + } + } + + // Fallback: if no known prefix is found, use the old behavior + return "" +} diff --git a/bundle/deploy/terraform/tfdyn/convert.go b/bundle/deploy/terraform/tfdyn/convert.go deleted file mode 100644 index 9df4e264013..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert.go +++ /dev/null @@ -1,23 +0,0 @@ -package tfdyn - -import ( - "context" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" -) - -type Converter interface { - Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error -} - -var converters = map[string]Converter{} - -func GetConverter(name string) (Converter, bool) { - c, ok := converters[name] - return c, ok -} - -func registerConverter(name string, c Converter) { - converters[name] = c -} diff --git a/bundle/deploy/terraform/tfdyn/convert_alert.go b/bundle/deploy/terraform/tfdyn/convert_alert.go deleted file mode 100644 index 8cb17001f18..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_alert.go +++ /dev/null @@ -1,56 +0,0 @@ -package tfdyn - -import ( - "context" - "fmt" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" -) - -func convertAlertResource(ctx context.Context, vin dyn.Value) (dyn.Value, error) { - // Normalize the output value to the target schema. - vout, diags := convert.Normalize(schema.ResourceAlertV2{}, vin) - for _, diag := range diags { - log.Debugf(ctx, "alert normalization diagnostic: %s", diag.Summary) - } - - // Always set purge_on_delete to true. PR with context: https://github.com/databricks/cli/pull/4505 - vout, err := dyn.Set(vout, "purge_on_delete", dyn.V(true)) - if err != nil { - return dyn.InvalidValue, err - } - - return vout, nil -} - -type alertConverter struct{} - -func (alertConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - vout, err := convertAlertResource(ctx, vin) - if err != nil { - return err - } - - vout, err = convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - // Add the converted resource to the output. - out.AlertV2[key] = vout.AsAny() - - // Configure permissions for this resource. - if permissions := convertPermissionsResource(ctx, vin); permissions != nil { - permissions.AlertV2Id = fmt.Sprintf("${databricks_alert_v2.%s.id}", key) - out.Permissions["alert_"+key] = permissions - } - - return nil -} - -func init() { - registerConverter("alerts", alertConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_alert_test.go b/bundle/deploy/terraform/tfdyn/convert_alert_test.go deleted file mode 100644 index 25d59425194..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_alert_test.go +++ /dev/null @@ -1,107 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/sql" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertAlert(t *testing.T) { - src := resources.Alert{ - AlertV2: sql.AlertV2{ - DisplayName: "test_alert", - QueryText: "SELECT 1", - WarehouseId: "test_warehouse_id", - CustomSummary: "Test alert summary", - CustomDescription: "Test alert description", - }, - Permissions: []resources.Permission{ - { - Level: "CAN_VIEW", - UserName: "jane@doe.com", - }, - { - Level: "CAN_MANAGE", - ServicePrincipalName: "sp-test", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = alertConverter{}.Convert(ctx, "test_alert", vin, out) - require.NoError(t, err) - - // Assert equality on the alert - alert := out.AlertV2["test_alert"] - assert.Equal(t, map[string]any{ - "display_name": "test_alert", - "query_text": "SELECT 1", - "warehouse_id": "test_warehouse_id", - "custom_summary": "Test alert summary", - "custom_description": "Test alert description", - "purge_on_delete": true, - }, alert) - - // Assert equality on the permissions - assert.Equal(t, &schema.ResourcePermissions{ - AlertV2Id: "${databricks_alert_v2.test_alert.id}", - AccessControl: []schema.ResourcePermissionsAccessControl{ - { - UserName: "jane@doe.com", - PermissionLevel: "CAN_VIEW", - }, - { - ServicePrincipalName: "sp-test", - PermissionLevel: "CAN_MANAGE", - }, - }, - }, out.Permissions["alert_test_alert"]) -} - -func TestConvertAlertWithThresholdDoubleValue(t *testing.T) { - src := resources.Alert{ - AlertV2: sql.AlertV2{ - DisplayName: "test_alert", - QueryText: "SELECT 1", - WarehouseId: "test_warehouse_id", - Evaluation: sql.AlertV2Evaluation{ - ComparisonOperator: "EQUAL", - Source: sql.AlertV2OperandColumn{ - Name: "1", - }, - Threshold: &sql.AlertV2Operand{ - Value: &sql.AlertV2OperandValue{ - DoubleValue: 1.3, - }, - }, - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = alertConverter{}.Convert(ctx, "test_alert", vin, out) - require.NoError(t, err) - - alert := out.AlertV2["test_alert"] - alertMap := alert.(map[string]any) - evaluation := alertMap["evaluation"].(map[string]any) - threshold := evaluation["threshold"].(map[string]any) - value := threshold["value"].(map[string]any) - - // Assert the fractional double_value is preserved after normalization. - assert.InDelta(t, 1.3, value["double_value"], 0.0001) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_app.go b/bundle/deploy/terraform/tfdyn/convert_app.go deleted file mode 100644 index edc6073a89d..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_app.go +++ /dev/null @@ -1,75 +0,0 @@ -package tfdyn - -import ( - "context" - "fmt" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" - "github.com/databricks/databricks-sdk-go/service/apps" -) - -func convertAppResource(ctx context.Context, vin dyn.Value) (dyn.Value, error) { - // Check if the description is not set and if it's not, set it to an empty string. - // This is done to avoid TF drift because Apps API return empty string for description when if it's not set. - if _, err := dyn.Get(vin, "description"); err != nil { - vin, err = dyn.Set(vin, "description", dyn.V("")) - if err != nil { - return vin, err - } - } - - // Normalize the output value to the target schema. - vout, diags := convert.Normalize(apps.App{}, vin) - for _, diag := range diags { - log.Debugf(ctx, "app normalization diagnostic: %s", diag.Summary) - } - - // SDK v0.175 added source_code_path, git_source, and default_git_source to - // apps.App. These are deploy-only fields DABs handles via source upload (see - // bundle/direct/dresources/app.go), not databricks_app resource attributes, so - // keep them out of the Terraform state. - vout, err := dyn.DropKeys(vout, []string{"source_code_path", "git_source", "default_git_source"}) - if err != nil { - return vout, err - } - - return vout, nil -} - -type appConverter struct{} - -func (appConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - vout, err := convertAppResource(ctx, vin) - if err != nil { - return err - } - - // Always skip compute during creation; lifecycle.started is only supported in direct mode. - vout, err = dyn.Set(vout, "no_compute", dyn.V(true)) - if err != nil { - return err - } - - vout, err = convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - // Add the converted resource to the output. - out.App[key] = vout.AsAny() - - // Configure permissions for this resource. - if permissions := convertPermissionsResource(ctx, vin); permissions != nil { - permissions.AppName = fmt.Sprintf("${databricks_app.%s.name}", key) - out.Permissions["app_"+key] = permissions - } - - return nil -} - -func init() { - registerConverter("apps", appConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_app_test.go b/bundle/deploy/terraform/tfdyn/convert_app_test.go deleted file mode 100644 index 013b9e7e9ac..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_app_test.go +++ /dev/null @@ -1,151 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/apps" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertApp(t *testing.T) { - src := resources.App{ - App: apps.App{ - SourceCodePath: "./app", - Name: "app_id", - Description: "app description", - Resources: []apps.AppResource{ - { - Name: "job1", - Job: &apps.AppResourceJob{ - Id: "1234", - Permission: "CAN_MANAGE_RUN", - }, - }, - { - Name: "sql1", - SqlWarehouse: &apps.AppResourceSqlWarehouse{ - Id: "5678", - Permission: "CAN_USE", - }, - }, - }, - }, - Permissions: []resources.AppPermission{ - { - Level: "CAN_RUN", - UserName: "jack@gmail.com", - }, - { - Level: "CAN_MANAGE", - ServicePrincipalName: "sp", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = appConverter{}.Convert(ctx, "my_app", vin, out) - require.NoError(t, err) - - app := out.App["my_app"] - assert.Equal(t, map[string]any{ - "description": "app description", - "name": "app_id", - "no_compute": true, - "resources": []any{ - map[string]any{ - "name": "job1", - "job": map[string]any{ - "id": "1234", - "permission": "CAN_MANAGE_RUN", - }, - }, - map[string]any{ - "name": "sql1", - "sql_warehouse": map[string]any{ - "id": "5678", - "permission": "CAN_USE", - }, - }, - }, - }, app) - - // Assert equality on the permissions - assert.Equal(t, &schema.ResourcePermissions{ - AppName: "${databricks_app.my_app.name}", - AccessControl: []schema.ResourcePermissionsAccessControl{ - { - PermissionLevel: "CAN_RUN", - UserName: "jack@gmail.com", - }, - { - PermissionLevel: "CAN_MANAGE", - ServicePrincipalName: "sp", - }, - }, - }, out.Permissions["app_my_app"]) -} - -func TestConvertAppWithNoDescription(t *testing.T) { - src := resources.App{ - App: apps.App{ - SourceCodePath: "./app", - Name: "app_id", - Resources: []apps.AppResource{ - { - Name: "job1", - Job: &apps.AppResourceJob{ - Id: "1234", - Permission: "CAN_MANAGE_RUN", - }, - }, - { - Name: "sql1", - SqlWarehouse: &apps.AppResourceSqlWarehouse{ - Id: "5678", - Permission: "CAN_USE", - }, - }, - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = appConverter{}.Convert(ctx, "my_app", vin, out) - require.NoError(t, err) - - app := out.App["my_app"] - assert.Equal(t, map[string]any{ - "name": "app_id", - "description": "", // Due to Apps API always returning a description field, we set it in the output as well to avoid permanent TF drift - "no_compute": true, - "resources": []any{ - map[string]any{ - "name": "job1", - "job": map[string]any{ - "id": "1234", - "permission": "CAN_MANAGE_RUN", - }, - }, - map[string]any{ - "name": "sql1", - "sql_warehouse": map[string]any{ - "id": "5678", - "permission": "CAN_USE", - }, - }, - }, - }, app) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_cluster.go b/bundle/deploy/terraform/tfdyn/convert_cluster.go deleted file mode 100644 index e53b22a38d6..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_cluster.go +++ /dev/null @@ -1,57 +0,0 @@ -package tfdyn - -import ( - "context" - "fmt" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" - "github.com/databricks/databricks-sdk-go/service/compute" -) - -func convertClusterResource(ctx context.Context, vin dyn.Value) (dyn.Value, error) { - // Normalize the output value to the target schema. - vout, diags := convert.Normalize(compute.ClusterSpec{}, vin) - for _, diag := range diags { - log.Debugf(ctx, "cluster normalization diagnostic: %s", diag.Summary) - } - - return vout, nil -} - -type clusterConverter struct{} - -func (clusterConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - vout, err := convertClusterResource(ctx, vin) - if err != nil { - return err - } - - // We always set no_wait as it allows DABs not to wait for cluster to be started. - vout, err = dyn.Set(vout, "no_wait", dyn.V(true)) - if err != nil { - return err - } - - vout, err = convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - // Add the converted resource to the output. - out.Cluster[key] = vout.AsAny() - - // Configure permissions for this resource. - if permissions := convertPermissionsResource(ctx, vin); permissions != nil { - permissions.ClusterId = fmt.Sprintf("${databricks_cluster.%s.id}", key) - out.Permissions["cluster_"+key] = permissions - } - - return nil -} - -func init() { - registerConverter("clusters", clusterConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_cluster_test.go b/bundle/deploy/terraform/tfdyn/convert_cluster_test.go deleted file mode 100644 index c28e8744137..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_cluster_test.go +++ /dev/null @@ -1,95 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/compute" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertCluster(t *testing.T) { - src := resources.Cluster{ - ClusterSpec: compute.ClusterSpec{ - NumWorkers: 3, - SparkVersion: "13.3.x-scala2.12", - ClusterName: "cluster", - SparkConf: map[string]string{ - "spark.executor.memory": "2g", - }, - AwsAttributes: &compute.AwsAttributes{ - Availability: "ON_DEMAND", - }, - AzureAttributes: &compute.AzureAttributes{ - Availability: "SPOT", - }, - DataSecurityMode: "USER_ISOLATION", - NodeTypeId: "m5.xlarge", - Autoscale: &compute.AutoScale{ - MinWorkers: 1, - MaxWorkers: 10, - }, - }, - - Permissions: []resources.ClusterPermission{ - { - Level: "CAN_RUN", - UserName: "jack@gmail.com", - }, - { - Level: "CAN_MANAGE", - ServicePrincipalName: "sp", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = clusterConverter{}.Convert(ctx, "my_cluster", vin, out) - require.NoError(t, err) - - cluster := out.Cluster["my_cluster"] - assert.Equal(t, map[string]any{ - "num_workers": int64(3), - "spark_version": "13.3.x-scala2.12", - "cluster_name": "cluster", - "spark_conf": map[string]any{ - "spark.executor.memory": "2g", - }, - "aws_attributes": map[string]any{ - "availability": "ON_DEMAND", - }, - "azure_attributes": map[string]any{ - "availability": "SPOT", - }, - "data_security_mode": "USER_ISOLATION", - "no_wait": true, - "node_type_id": "m5.xlarge", - "autoscale": map[string]any{ - "min_workers": int64(1), - "max_workers": int64(10), - }, - }, cluster) - - // Assert equality on the permissions - assert.Equal(t, &schema.ResourcePermissions{ - ClusterId: "${databricks_cluster.my_cluster.id}", - AccessControl: []schema.ResourcePermissionsAccessControl{ - { - PermissionLevel: "CAN_RUN", - UserName: "jack@gmail.com", - }, - { - PermissionLevel: "CAN_MANAGE", - ServicePrincipalName: "sp", - }, - }, - }, out.Permissions["cluster_my_cluster"]) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_dashboard.go b/bundle/deploy/terraform/tfdyn/convert_dashboard.go deleted file mode 100644 index e55cb6b83de..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_dashboard.go +++ /dev/null @@ -1,60 +0,0 @@ -package tfdyn - -import ( - "context" - "fmt" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" -) - -func convertDashboardResource(ctx context.Context, vin dyn.Value) (dyn.Value, error) { - var err error - - // Normalize the output value to the target schema. ConfigureDashboardSerializedDashboard - // normalizes serialized_dashboard to a JSON string before this runs, so it maps - // straight onto the schema's string field. - vout, diags := convert.Normalize(schema.ResourceDashboard{}, vin) - for _, diag := range diags { - log.Debugf(ctx, "dashboard normalization diagnostic: %s", diag.Summary) - } - - // Drop the "file_path" field. It's always inlined into "serialized_dashboard". - vout, err = dyn.DropKeys(vout, []string{"file_path"}) - if err != nil { - return dyn.InvalidValue, err - } - - return vout, nil -} - -type dashboardConverter struct{} - -func (dashboardConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - vout, err := convertDashboardResource(ctx, vin) - if err != nil { - return err - } - - vout, err = convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - // Add the converted resource to the output. - out.Dashboard[key] = vout.AsAny() - - // Configure permissions for this resource. - if permissions := convertPermissionsResource(ctx, vin); permissions != nil { - permissions.DashboardId = fmt.Sprintf("${databricks_dashboard.%s.id}", key) - out.Permissions["dashboard_"+key] = permissions - } - - return nil -} - -func init() { - registerConverter("dashboards", dashboardConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_dashboard_test.go b/bundle/deploy/terraform/tfdyn/convert_dashboard_test.go deleted file mode 100644 index aa23b90df78..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_dashboard_test.go +++ /dev/null @@ -1,136 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertDashboard(t *testing.T) { - src := resources.Dashboard{ - DashboardConfig: resources.DashboardConfig{ - DisplayName: "my dashboard", - WarehouseId: "f00dcafe", - ParentPath: "/some/path", - EmbedCredentials: true, - }, - - Permissions: []resources.Permission{ - { - Level: "CAN_VIEW", - UserName: "jane@doe.com", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = dashboardConverter{}.Convert(ctx, "my_dashboard", vin, out) - require.NoError(t, err) - - // Assert equality on the job - assert.Equal(t, map[string]any{ - "display_name": "my dashboard", - "warehouse_id": "f00dcafe", - "parent_path": "/some/path", - "embed_credentials": true, - }, out.Dashboard["my_dashboard"]) - - // Assert equality on the permissions - assert.Equal(t, &schema.ResourcePermissions{ - DashboardId: "${databricks_dashboard.my_dashboard.id}", - AccessControl: []schema.ResourcePermissionsAccessControl{ - { - PermissionLevel: "CAN_VIEW", - UserName: "jane@doe.com", - }, - }, - }, out.Permissions["dashboard_my_dashboard"]) -} - -func TestConvertDashboardSerializedDashboardString(t *testing.T) { - src := resources.Dashboard{ - DashboardConfig: resources.DashboardConfig{ - SerializedDashboard: `{ "json": true }`, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = dashboardConverter{}.Convert(ctx, "my_dashboard", vin, out) - require.NoError(t, err) - - // Assert that the "serialized_dashboard" is included. - assert.Subset(t, out.Dashboard["my_dashboard"], map[string]any{ - "serialized_dashboard": `{ "json": true }`, - }) -} - -func TestConvertDashboardDropsFilePath(t *testing.T) { - // ConfigureDashboardSerializedDashboard reads file_path into serialized_dashboard - // but keeps file_path around, so the converter sees both and must drop file_path. - src := resources.Dashboard{ - DashboardConfig: resources.DashboardConfig{ - SerializedDashboard: `{"pages":[{"displayName":"New Page","layout":[]}]}`, - }, - FilePath: "some/path/to/dashboard.lvdash.json", - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = dashboardConverter{}.Convert(ctx, "my_dashboard", vin, out) - require.NoError(t, err) - - // Assert that the "serialized_dashboard" is included. - assert.Subset(t, out.Dashboard["my_dashboard"], map[string]any{ - "serialized_dashboard": `{"pages":[{"displayName":"New Page","layout":[]}]}`, - }) - - // Assert that the "file_path" is dropped. - assert.NotContains(t, out.Dashboard["my_dashboard"], "file_path") -} - -func TestConvertDashboardDatasetCatalogSchema(t *testing.T) { - src := resources.Dashboard{ - DashboardConfig: resources.DashboardConfig{ - DisplayName: "my dashboard", - WarehouseId: "f00dcafe", - ParentPath: "/some/path", - DatasetCatalog: "main", - DatasetSchema: "default", - EmbedCredentials: true, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = dashboardConverter{}.Convert(ctx, "my_dashboard", vin, out) - require.NoError(t, err) - - // Assert that dataset_catalog and dataset_schema are included. - assert.Subset(t, out.Dashboard["my_dashboard"], map[string]any{ - "display_name": "my dashboard", - "warehouse_id": "f00dcafe", - "parent_path": "/some/path", - "dataset_catalog": "main", - "dataset_schema": "default", - "embed_credentials": true, - }) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_database_catalog.go b/bundle/deploy/terraform/tfdyn/convert_database_catalog.go deleted file mode 100644 index 716c3baf814..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_database_catalog.go +++ /dev/null @@ -1,35 +0,0 @@ -package tfdyn - -import ( - "context" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" - "github.com/databricks/databricks-sdk-go/service/database" -) - -type databaseCatalogConverter struct{} - -func (d databaseCatalogConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - // Normalize the output value to the target schema. - vout, diags := convert.Normalize(database.DatabaseCatalog{}, vin) - for _, diag := range diags { - log.Debugf(ctx, "database Catalog normalization diagnostic: %s", diag.Summary) - } - - var err error - vout, err = convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - out.DatabaseDatabaseCatalog[key] = vout.AsAny() - - return nil -} - -func init() { - registerConverter("database_catalogs", databaseCatalogConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_database_instance.go b/bundle/deploy/terraform/tfdyn/convert_database_instance.go deleted file mode 100644 index 1dfb4dc4c94..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_database_instance.go +++ /dev/null @@ -1,48 +0,0 @@ -package tfdyn - -import ( - "context" - "fmt" - - "github.com/databricks/databricks-sdk-go/service/database" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" -) - -type databaseInstanceConverter struct{} - -func (d databaseInstanceConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - // Normalize the output value to the target schema. - vout, diags := convert.Normalize(database.DatabaseInstance{}, vin) - for _, diag := range diags { - log.Debugf(ctx, "database instance normalization diagnostic: %s", diag.Summary) - } - - // Always set purge_on_delete to true - vout, err := dyn.Set(vout, "purge_on_delete", dyn.V(true)) - if err != nil { - return err - } - - vout, err = convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - out.DatabaseInstance[key] = vout.AsAny() - - // Configure permissions for this resource. - if permissions := convertPermissionsResource(ctx, vin); permissions != nil { - permissions.DatabaseInstanceName = fmt.Sprintf("${databricks_database_instance.%s.name}", key) - out.Permissions["database_instance_"+key] = permissions - } - - return nil -} - -func init() { - registerConverter("database_instances", databaseInstanceConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_database_instance_test.go b/bundle/deploy/terraform/tfdyn/convert_database_instance_test.go deleted file mode 100644 index 533c69abedc..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_database_instance_test.go +++ /dev/null @@ -1,118 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/database" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertDatabaseInstance(t *testing.T) { - src := resources.DatabaseInstance{ - DatabaseInstance: database.DatabaseInstance{ - Name: "test-db-instance", - Capacity: "CU_4", - NodeCount: 2, - EnableReadableSecondaries: true, - RetentionWindowInDays: 14, - Stopped: false, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = databaseInstanceConverter{}.Convert(ctx, "my_database_instance", vin, out) - require.NoError(t, err) - - databaseInstance := out.DatabaseInstance["my_database_instance"] - assert.Equal(t, map[string]any{ - "name": "test-db-instance", - "capacity": "CU_4", - "node_count": int64(2), - "enable_readable_secondaries": true, - "retention_window_in_days": int64(14), - "purge_on_delete": true, - }, databaseInstance) -} - -func TestConvertDatabaseInstanceWithMinimalConfig(t *testing.T) { - src := resources.DatabaseInstance{ - DatabaseInstance: database.DatabaseInstance{ - Name: "minimal-db-instance", - Capacity: "CU_1", - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = databaseInstanceConverter{}.Convert(ctx, "minimal_database_instance", vin, out) - require.NoError(t, err) - - databaseInstance := out.DatabaseInstance["minimal_database_instance"] - assert.Equal(t, map[string]any{ - "name": "minimal-db-instance", - "capacity": "CU_1", - "purge_on_delete": true, - }, databaseInstance) -} - -func TestConvertDatabaseInstanceWithPermissions(t *testing.T) { - src := resources.DatabaseInstance{ - DatabaseInstance: database.DatabaseInstance{ - Name: "db-instance-with-permissions", - Capacity: "CU_2", - }, - Permissions: []resources.Permission{ - { - Level: "CAN_USE", - UserName: "user@example.com", - }, - { - Level: "CAN_MANAGE", - ServicePrincipalName: "sp-name", - }, - }, - } - - // Add permissions to the dynamic value - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = databaseInstanceConverter{}.Convert(ctx, "db_with_permissions", vin, out) - require.NoError(t, err) - - databaseInstance := out.DatabaseInstance["db_with_permissions"] - assert.Equal(t, map[string]any{ - "name": "db-instance-with-permissions", - "purge_on_delete": true, - "capacity": "CU_2", - }, databaseInstance) - - // Assert permissions were created - assert.Equal(t, &schema.ResourcePermissions{ - DatabaseInstanceName: "${databricks_database_instance.db_with_permissions.name}", - AccessControl: []schema.ResourcePermissionsAccessControl{ - { - PermissionLevel: "CAN_USE", - UserName: "user@example.com", - }, - { - PermissionLevel: "CAN_MANAGE", - ServicePrincipalName: "sp-name", - }, - }, - }, out.Permissions["database_instance_db_with_permissions"]) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_experiment.go b/bundle/deploy/terraform/tfdyn/convert_experiment.go deleted file mode 100644 index a741b4dec4c..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_experiment.go +++ /dev/null @@ -1,50 +0,0 @@ -package tfdyn - -import ( - "context" - "fmt" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" -) - -func convertExperimentResource(ctx context.Context, vin dyn.Value) (dyn.Value, error) { - // Normalize the output value to the target schema. - vout, diags := convert.Normalize(schema.ResourceMlflowExperiment{}, vin) - for _, diag := range diags { - log.Debugf(ctx, "experiment normalization diagnostic: %s", diag.Summary) - } - - return vout, nil -} - -type experimentConverter struct{} - -func (experimentConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - vout, err := convertExperimentResource(ctx, vin) - if err != nil { - return err - } - - vout, err = convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - // Add the converted resource to the output. - out.MlflowExperiment[key] = vout.AsAny() - - // Configure permissions for this resource. - if permissions := convertPermissionsResource(ctx, vin); permissions != nil { - permissions.ExperimentId = fmt.Sprintf("${databricks_mlflow_experiment.%s.id}", key) - out.Permissions["mlflow_experiment_"+key] = permissions - } - - return nil -} - -func init() { - registerConverter("experiments", experimentConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_experiment_test.go b/bundle/deploy/terraform/tfdyn/convert_experiment_test.go deleted file mode 100644 index 9140ef13aca..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_experiment_test.go +++ /dev/null @@ -1,51 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/ml" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertExperiment(t *testing.T) { - src := resources.MlflowExperiment{ - CreateExperiment: ml.CreateExperiment{ - Name: "name", - }, - Permissions: []resources.MlflowExperimentPermission{ - { - Level: "CAN_READ", - UserName: "jane@doe.com", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = experimentConverter{}.Convert(ctx, "my_experiment", vin, out) - require.NoError(t, err) - - // Assert equality on the experiment - assert.Equal(t, map[string]any{ - "name": "name", - }, out.MlflowExperiment["my_experiment"]) - - // Assert equality on the permissions - assert.Equal(t, &schema.ResourcePermissions{ - ExperimentId: "${databricks_mlflow_experiment.my_experiment.id}", - AccessControl: []schema.ResourcePermissionsAccessControl{ - { - PermissionLevel: "CAN_READ", - UserName: "jane@doe.com", - }, - }, - }, out.Permissions["mlflow_experiment_my_experiment"]) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_grants.go b/bundle/deploy/terraform/tfdyn/convert_grants.go deleted file mode 100644 index 1ddd99dd70f..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_grants.go +++ /dev/null @@ -1,39 +0,0 @@ -package tfdyn - -import ( - "context" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" -) - -func convertGrantsResource(ctx context.Context, vin dyn.Value) *schema.ResourceGrants { - grants, ok := vin.Get("grants").AsSequence() - if !ok || len(grants) == 0 { - return nil - } - - resource := &schema.ResourceGrants{} - for _, permission := range grants { - principal, _ := permission.Get("principal").AsString() - v, _ := permission.Get("privileges").AsSequence() - - // Turn privileges into a slice of strings. - var privileges []string - for _, privilege := range v { - str, ok := privilege.AsString() - if !ok { - continue - } - - privileges = append(privileges, str) - } - - resource.Grant = append(resource.Grant, schema.ResourceGrantsGrant{ - Principal: principal, - Privileges: privileges, - }) - } - - return resource -} diff --git a/bundle/deploy/terraform/tfdyn/convert_grants_test.go b/bundle/deploy/terraform/tfdyn/convert_grants_test.go deleted file mode 100644 index 6019ab823d2..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_grants_test.go +++ /dev/null @@ -1,71 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/catalog" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertGrants(t *testing.T) { - src := resources.RegisteredModel{ - Grants: []catalog.PrivilegeAssignment{ - { - Privileges: []catalog.Privilege{"EXECUTE", "FOO"}, - Principal: "jane@doe.com", - }, - { - Privileges: []catalog.Privilege{"EXECUTE", "BAR"}, - Principal: "spn", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - resource := convertGrantsResource(ctx, vin) - require.NotNil(t, resource) - assert.Equal(t, []schema.ResourceGrantsGrant{ - { - Privileges: []string{"EXECUTE", "FOO"}, - Principal: "jane@doe.com", - }, - { - Privileges: []string{"EXECUTE", "BAR"}, - Principal: "spn", - }, - }, resource.Grant) -} - -func TestConvertGrantsNil(t *testing.T) { - src := resources.RegisteredModel{ - Grants: nil, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - resource := convertGrantsResource(ctx, vin) - assert.Nil(t, resource) -} - -func TestConvertGrantsEmpty(t *testing.T) { - src := resources.RegisteredModel{ - Grants: []catalog.PrivilegeAssignment{}, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - resource := convertGrantsResource(ctx, vin) - assert.Nil(t, resource) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_job.go b/bundle/deploy/terraform/tfdyn/convert_job.go deleted file mode 100644 index 2e47c4ef1c0..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_job.go +++ /dev/null @@ -1,265 +0,0 @@ -package tfdyn - -import ( - "cmp" - "context" - "fmt" - "slices" - "strings" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" - "github.com/databricks/cli/libs/logdiag" - "github.com/databricks/databricks-sdk-go/service/jobs" -) - -// These are the task types that support the source field -// https://docs.databricks.com/api/workspace/jobs/create -var supportedTypeTasks = []string{ - "dbt_task", - "gen_ai_compute_task", - "notebook_task", - "spark_python_task", - "sql_task.file", -} - -func setSourceIfNotSet(task dyn.Value, defaultSource jobs.Source) (dyn.Value, error) { - for _, taskType := range supportedTypeTasks { - t, err := dyn.Get(task, taskType) - if err != nil { - continue - } - - _, err = dyn.Get(t, "source") - if err != nil { - return dyn.Set(task, taskType+".source", dyn.V(string(defaultSource))) - } - } - return task, nil -} - -func applyDefaultTaskSource(job dyn.Value) (dyn.Value, error) { - defaultSource := jobs.SourceWorkspace - - // Check if the job has git_source set and set the default source to GIT if it does - _, err := dyn.Get(job, "git_source") - if err == nil { - defaultSource = jobs.SourceGit - } - - // Then iterate over the tasks and set the source to the default if it's not set - return dyn.Map(job, "tasks", dyn.Foreach(func(_ dyn.Path, task dyn.Value) (dyn.Value, error) { - // Then iterate over the foreach tasks and set the source to the default if it's not set - task, err = dyn.Map(task, "for_each_task.task", func(_ dyn.Path, foreachTask dyn.Value) (dyn.Value, error) { - return setSourceIfNotSet(foreachTask, defaultSource) - }) - if err != nil { - return task, err - } - - return setSourceIfNotSet(task, defaultSource) - })) -} - -func patchApplyPolicyDefaultValues(_ dyn.Path, v dyn.Value) (dyn.Value, error) { - // If the field "apply_policy_default_values" is not set, do nothing. - if b, ok := v.Get("apply_policy_default_values").AsBool(); !ok || !b { - return v, nil - } - - // If the field "policy_id" is not set, do nothing. - if _, ok := v.Get("policy_id").AsString(); !ok { - return v, nil - } - - // The field "apply_policy_default_values" is set. - // We need to collect the list of fields that are set explicitly - // and pass it to Terraform. This enables Terraform to clear - // server-side defaults from the update request, which in turn - // allows the backend to re-apply the policy defaults. - // - // For more details, see: https://github.com/databricks/terraform-provider-databricks/pull/4834 - // - paths := dyn.CollectLeafPaths(v) - - // If any of the map or sequence fields are set, always include them entirely instead of traversing the them. - for _, field := range []string{ - "custom_tags", - "init_scripts", - "spark_conf", - "spark_env_vars", - "ssh_public_keys", - } { - if vv := v.Get(field); vv.IsValid() { - // Remove all paths that start with the field. - paths = slices.DeleteFunc(paths, func(p string) bool { - return strings.HasPrefix(p, field+".") || strings.HasPrefix(p, field+"[") - }) - // Add the field to the paths. - paths = append(paths, field) - } - } - - slices.Sort(paths) - valList := make([]dyn.Value, len(paths)) - for i, s := range paths { - valList[i] = dyn.V(s) - } - v, err := dyn.Set(v, "__apply_policy_default_values_allow_list", dyn.V(valList)) - if err != nil { - return dyn.InvalidValue, err - } - - return v, nil -} - -func convertJobResource(ctx context.Context, vin dyn.Value) (dyn.Value, error) { - // Normalize the input value to the underlying job schema. - // This removes superfluous keys and adapts the input to the expected schema. - vin, diags := convert.Normalize(jobs.JobSettings{}, vin) - for _, diag := range diags { - log.Debugf(ctx, "job normalization diagnostic: %s", diag.Summary) - } - - // Sort the tasks of each job in the bundle by task key. Sorting - // the task keys ensures that the diff computed by terraform is correct and avoids - // recreates. For more details see the NOTE at - // https://registry.terraform.io/providers/databricks/databricks/latest/docs/resources/job#example-usage - // and https://github.com/databricks/terraform-provider-databricks/issues/4011 - // and https://github.com/databricks/cli/pull/1776 - vout := vin - var err error - tasks, ok := vin.Get("tasks").AsSequence() - if ok { - slices.SortFunc(tasks, func(a, b dyn.Value) int { - // We sort the tasks by their task key. Tasks without task keys are ordered - // before tasks with task keys. We do not error for those tasks - // since presence of a task_key is validated for in the Jobs backend. - tk1, ok1 := a.Get("task_key").AsString() - tk2, ok2 := b.Get("task_key").AsString() - if !ok1 && ok2 { - return -1 - } - if ok1 && !ok2 { - return 1 - } - if !ok1 && !ok2 { - return 0 - } - return cmp.Compare(tk1, tk2) - }) - vout, err = dyn.Set(vin, "tasks", dyn.V(tasks)) - if err != nil { - return dyn.InvalidValue, err - } - } - - // Apply default task source logic - vout, err = applyDefaultTaskSource(vout) - if err != nil { - return dyn.InvalidValue, err - } - - // Modify top-level keys. - vout, err = renameKeys(vout, map[string]string{ - "tasks": "task", - "job_clusters": "job_cluster", - "parameters": "parameter", - "environments": "environment", - }) - if err != nil { - return dyn.InvalidValue, err - } - - // Modify keys in the "git_source" block - vout, err = dyn.Map(vout, "git_source", func(_ dyn.Path, v dyn.Value) (dyn.Value, error) { - return renameKeys(v, map[string]string{ - "git_branch": "branch", - "git_commit": "commit", - "git_provider": "provider", - "git_tag": "tag", - "git_url": "url", - }) - }) - if err != nil { - return dyn.InvalidValue, err - } - - // Modify keys in the "task" blocks - vout, err = dyn.Map(vout, "task", dyn.Foreach(func(_ dyn.Path, v dyn.Value) (dyn.Value, error) { - // Modify "library" blocks for for_each_task - vout, err = dyn.Map(v, "for_each_task.task", func(_ dyn.Path, v dyn.Value) (dyn.Value, error) { - return renameKeys(v, map[string]string{ - "libraries": "library", - }) - }) - if err != nil { - return dyn.InvalidValue, err - } - - return renameKeys(vout, map[string]string{ - "libraries": "library", - }) - })) - if err != nil { - return dyn.InvalidValue, err - } - - // Normalize the output value to the target schema. - // A diagnostic here means the field is unknown to the pinned Terraform provider - // schema and is dropped from the deployment; warn so the drop is not silent. - // Normalize only emits warning severity, so this cannot fail the deploy. - vout, diags = convert.Normalize(schema.ResourceJob{}, vout) - for _, d := range diags { - logdiag.LogDiag(ctx, d) - } - - // Apply __apply_policy_default_values_allow_list for tasks - vout, err = dyn.Map(vout, "task", dyn.Foreach(func(_ dyn.Path, v dyn.Value) (dyn.Value, error) { - return dyn.Map(v, "new_cluster", patchApplyPolicyDefaultValues) - })) - if err != nil { - return dyn.InvalidValue, err - } - - // Apply __apply_policy_default_values_allow_list for job clusters - vout, err = dyn.Map(vout, "job_cluster", dyn.Foreach(func(_ dyn.Path, v dyn.Value) (dyn.Value, error) { - return dyn.Map(v, "new_cluster", patchApplyPolicyDefaultValues) - })) - if err != nil { - return dyn.InvalidValue, err - } - - return vout, err -} - -type jobConverter struct{} - -func (jobConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - vout, err := convertJobResource(ctx, vin) - if err != nil { - return err - } - - vout, err = convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - // Add the converted resource to the output. - out.Job[key] = vout.AsAny() - - // Configure permissions for this resource. - if permissions := convertPermissionsResource(ctx, vin); permissions != nil { - permissions.JobId = fmt.Sprintf("${databricks_job.%s.id}", key) - out.Permissions["job_"+key] = permissions - } - - return nil -} - -func init() { - registerConverter("jobs", jobConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_job_test.go b/bundle/deploy/terraform/tfdyn/convert_job_test.go deleted file mode 100644 index d24bdd47b31..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_job_test.go +++ /dev/null @@ -1,423 +0,0 @@ -package tfdyn - -import ( - "reflect" - "slices" - "strings" - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/diag" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/logdiag" - "github.com/databricks/cli/libs/textutil" - "github.com/databricks/databricks-sdk-go/service/compute" - "github.com/databricks/databricks-sdk-go/service/jobs" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertJob(t *testing.T) { - src := resources.Job{ - JobSettings: jobs.JobSettings{ - Name: "my job", - JobClusters: []jobs.JobCluster{ - { - JobClusterKey: "key", - NewCluster: &compute.ClusterSpec{ - SparkVersion: "10.4.x-scala2.12", - }, - }, - }, - GitSource: &jobs.GitSource{ - GitProvider: jobs.GitProviderGitHub, - GitUrl: "https://github.com/foo/bar", - }, - Parameters: []jobs.JobParameterDefinition{ - { - Name: "param1", - Default: "default1", - }, - { - Name: "param2", - Default: "default2", - }, - }, - Tasks: []jobs.Task{ - { - TaskKey: "task_key_b", - JobClusterKey: "job_cluster_key_b", - Libraries: []compute.Library{ - { - Pypi: &compute.PythonPyPiLibrary{ - Package: "package", - }, - }, - { - Whl: "/path/to/my.whl", - }, - }, - }, - { - TaskKey: "task_key_a", - JobClusterKey: "job_cluster_key_a", - }, - { - TaskKey: "task_key_c", - JobClusterKey: "job_cluster_key_c", - }, - { - Description: "missing task key 😱", - }, - }, - }, - Permissions: []resources.JobPermission{ - { - Level: "CAN_VIEW", - UserName: "jane@doe.com", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = jobConverter{}.Convert(ctx, "my_job", vin, out) - require.NoError(t, err) - - // Assert equality on the job - assert.Equal(t, map[string]any{ - "name": "my job", - "job_cluster": []any{ - map[string]any{ - "job_cluster_key": "key", - "new_cluster": map[string]any{ - "spark_version": "10.4.x-scala2.12", - }, - }, - }, - "git_source": map[string]any{ - "provider": "gitHub", - "url": "https://github.com/foo/bar", - }, - "parameter": []any{ - map[string]any{ - "name": "param1", - "default": "default1", - }, - map[string]any{ - "name": "param2", - "default": "default2", - }, - }, - "task": []any{ - map[string]any{ - "description": "missing task key 😱", - }, - map[string]any{ - "task_key": "task_key_a", - "job_cluster_key": "job_cluster_key_a", - }, - map[string]any{ - "task_key": "task_key_b", - "job_cluster_key": "job_cluster_key_b", - "library": []any{ - map[string]any{ - "pypi": map[string]any{ - "package": "package", - }, - }, - map[string]any{ - "whl": "/path/to/my.whl", - }, - }, - }, - map[string]any{ - "task_key": "task_key_c", - "job_cluster_key": "job_cluster_key_c", - }, - }, - }, out.Job["my_job"]) - - // Assert equality on the permissions - assert.Equal(t, &schema.ResourcePermissions{ - JobId: "${databricks_job.my_job.id}", - AccessControl: []schema.ResourcePermissionsAccessControl{ - { - PermissionLevel: "CAN_VIEW", - UserName: "jane@doe.com", - }, - }, - }, out.Permissions["job_my_job"]) -} - -func TestConvertJobApplyPolicyDefaultValues(t *testing.T) { - src := resources.Job{ - JobSettings: jobs.JobSettings{ - Name: "my job", - JobClusters: []jobs.JobCluster{ - { - JobClusterKey: "key", - NewCluster: &compute.ClusterSpec{ - ApplyPolicyDefaultValues: true, - PolicyId: "policy_id", - GcpAttributes: &compute.GcpAttributes{ - Availability: "SPOT", - LocalSsdCount: 2, - }, - }, - }, - { - JobClusterKey: "key2", - NewCluster: &compute.ClusterSpec{ - ApplyPolicyDefaultValues: true, - PolicyId: "policy_id2", - CustomTags: map[string]string{ - "key": "value", - }, - InitScripts: []compute.InitScriptInfo{ - { - Workspace: &compute.WorkspaceStorageInfo{ - Destination: "/Workspace/path/to/init_script1", - }, - }, - { - Workspace: &compute.WorkspaceStorageInfo{ - Destination: "/Workspace/path/to/init_script2", - }, - }, - }, - SparkConf: map[string]string{ - "key": "value", - }, - SparkEnvVars: map[string]string{ - "key": "value", - }, - SshPublicKeys: []string{ - "ssh-rsa 1234", - }, - }, - }, - { - JobClusterKey: "key3", - NewCluster: &compute.ClusterSpec{ - ApplyPolicyDefaultValues: true, - SparkVersion: "16.4.x-scala2.12", - }, - }, - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = jobConverter{}.Convert(ctx, "my_job", vin, out) - require.NoError(t, err) - - assert.Equal(t, map[string]any{ - "name": "my job", - "job_cluster": []any{ - map[string]any{ - "job_cluster_key": "key", - "new_cluster": map[string]any{ - "__apply_policy_default_values_allow_list": []any{ - "apply_policy_default_values", - "gcp_attributes.availability", - "gcp_attributes.local_ssd_count", - "policy_id", - }, - "apply_policy_default_values": true, - "policy_id": "policy_id", - "gcp_attributes": map[string]any{ - "availability": "SPOT", - "local_ssd_count": int64(2), - }, - }, - }, - map[string]any{ - "job_cluster_key": "key2", - "new_cluster": map[string]any{ - "__apply_policy_default_values_allow_list": []any{ - "apply_policy_default_values", - "custom_tags", - "init_scripts", - "policy_id", - "spark_conf", - "spark_env_vars", - "ssh_public_keys", - }, - "apply_policy_default_values": true, - "policy_id": "policy_id2", - "custom_tags": map[string]any{ - "key": "value", - }, - "init_scripts": []any{ - map[string]any{ - "workspace": map[string]any{ - "destination": "/Workspace/path/to/init_script1", - }, - }, - map[string]any{ - "workspace": map[string]any{ - "destination": "/Workspace/path/to/init_script2", - }, - }, - }, - "spark_conf": map[string]any{ - "key": "value", - }, - "spark_env_vars": map[string]any{ - "key": "value", - }, - "ssh_public_keys": []any{ - "ssh-rsa 1234", - }, - }, - }, - map[string]any{ - "job_cluster_key": "key3", - "new_cluster": map[string]any{ - "apply_policy_default_values": true, - "spark_version": "16.4.x-scala2.12", - }, - }, - }, - }, out.Job["my_job"]) -} - -func TestConvertJobFieldUnknownToTerraformSchema(t *testing.T) { - // autotermination_minutes is in the SDK job schema but not in the pinned - // Terraform provider schema; if a provider bump adds it, pick another such field. - src := resources.Job{ - JobSettings: jobs.JobSettings{ - Name: "my job", - Tasks: []jobs.Task{ - { - TaskKey: "key", - NewCluster: &compute.ClusterSpec{ - SparkVersion: "10.4.x-scala2.12", - AutoterminationMinutes: 60, - }, - }, - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := logdiag.InitContext(t.Context()) - logdiag.SetCollect(ctx, true) - - out := schema.NewResources() - err = jobConverter{}.Convert(ctx, "my_job", vin, out) - require.NoError(t, err) - - diags := logdiag.FlushCollected(ctx) - require.Len(t, diags, 1) - assert.Equal(t, diag.Warning, diags[0].Severity) - assert.Equal(t, "unknown field: autotermination_minutes", diags[0].Summary) - - assert.Equal(t, map[string]any{ - "name": "my job", - "task": []any{ - map[string]any{ - "task_key": "key", - "new_cluster": map[string]any{ - "spark_version": "10.4.x-scala2.12", - }, - }, - }, - }, out.Job["my_job"]) -} - -// TestSupportedTypeTasksComplete verifies that supportedTypeTasks includes all task types with a Source field. -func TestSupportedTypeTasksComplete(t *testing.T) { - // Use reflection to find all task types that have a Source field - taskType := reflect.TypeFor[jobs.Task]() - var tasksWithSource []string - - for field := range taskType.Fields() { - // Skip non-task fields (like DependsOn, Libraries, etc.) - if !strings.HasSuffix(field.Name, "Task") { - continue - } - - // Get the type of the task field (e.g., *NotebookTask) - taskFieldType := field.Type - if taskFieldType.Kind() == reflect.Pointer { - taskFieldType = taskFieldType.Elem() - } - - if taskFieldType.Kind() != reflect.Struct { - continue - } - - // Recursively search for Source fields in this task type - // We only search one level deep to catch nested Source fields like sql_task.file - taskName := textutil.CamelToSnakeCase(field.Name) - sourcePaths := findSourceFieldsShallow(taskFieldType) - for _, path := range sourcePaths { - if path == "" { - tasksWithSource = append(tasksWithSource, taskName) - } else { - tasksWithSource = append(tasksWithSource, taskName+"."+path) - } - } - } - - // Verify that all tasks with Source fields are in supportedTypeTasks - slices.Sort(tasksWithSource) - sortedSupported := make([]string, len(supportedTypeTasks)) - copy(sortedSupported, supportedTypeTasks) - slices.Sort(sortedSupported) - - assert.Equal(t, sortedSupported, tasksWithSource, - "supportedTypeTasks must include all task types with a Source field. "+ - "If this test fails, update supportedTypeTasks in convert_job.go") -} - -// findSourceFieldsShallow searches for Source fields in a struct type, going only one level deep. -// Returns a list of paths to Source fields (e.g., "" for direct Source, "file" for sql_task.file). -func findSourceFieldsShallow(t reflect.Type) []string { - if t.Kind() == reflect.Pointer { - t = t.Elem() - } - - if t.Kind() != reflect.Struct { - return nil - } - - var paths []string - - for field := range t.Fields() { - // Check if this field is named "Source" - if field.Name == "Source" { - paths = append(paths, "") - continue - } - - // Only search one level deep in nested structs - fieldType := field.Type - if fieldType.Kind() == reflect.Pointer { - fieldType = fieldType.Elem() - } - - if fieldType.Kind() == reflect.Struct { - // Check if the nested struct has a Source field - if _, hasSource := fieldType.FieldByName("Source"); hasSource { - fieldName := textutil.CamelToSnakeCase(field.Name) - paths = append(paths, fieldName) - } - } - } - - return paths -} diff --git a/bundle/deploy/terraform/tfdyn/convert_model.go b/bundle/deploy/terraform/tfdyn/convert_model.go deleted file mode 100644 index 722f3aa6363..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_model.go +++ /dev/null @@ -1,50 +0,0 @@ -package tfdyn - -import ( - "context" - "fmt" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" -) - -func convertModelResource(ctx context.Context, vin dyn.Value) (dyn.Value, error) { - // Normalize the output value to the target schema. - vout, diags := convert.Normalize(schema.ResourceMlflowModel{}, vin) - for _, diag := range diags { - log.Debugf(ctx, "model normalization diagnostic: %s", diag.Summary) - } - - return vout, nil -} - -type modelConverter struct{} - -func (modelConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - vout, err := convertModelResource(ctx, vin) - if err != nil { - return err - } - - vout, err = convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - // Add the converted resource to the output. - out.MlflowModel[key] = vout.AsAny() - - // Configure permissions for this resource. - if permissions := convertPermissionsResource(ctx, vin); permissions != nil { - permissions.RegisteredModelId = fmt.Sprintf("${databricks_mlflow_model.%s.registered_model_id}", key) - out.Permissions["mlflow_model_"+key] = permissions - } - - return nil -} - -func init() { - registerConverter("models", modelConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_model_serving_endpoint.go b/bundle/deploy/terraform/tfdyn/convert_model_serving_endpoint.go deleted file mode 100644 index b9a5d95c145..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_model_serving_endpoint.go +++ /dev/null @@ -1,50 +0,0 @@ -package tfdyn - -import ( - "context" - "fmt" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" -) - -func convertModelServingEndpointResource(ctx context.Context, vin dyn.Value) (dyn.Value, error) { - // Normalize the output value to the target schema. - vout, diags := convert.Normalize(schema.ResourceModelServing{}, vin) - for _, diag := range diags { - log.Debugf(ctx, "model serving endpoint normalization diagnostic: %s", diag.Summary) - } - - return vout, nil -} - -type modelServingEndpointConverter struct{} - -func (modelServingEndpointConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - vout, err := convertModelServingEndpointResource(ctx, vin) - if err != nil { - return err - } - - vout, err = convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - // Add the converted resource to the output. - out.ModelServing[key] = vout.AsAny() - - // Configure permissions for this resource. - if permissions := convertPermissionsResource(ctx, vin); permissions != nil { - permissions.ServingEndpointId = fmt.Sprintf("${databricks_model_serving.%s.serving_endpoint_id}", key) - out.Permissions["model_serving_"+key] = permissions - } - - return nil -} - -func init() { - registerConverter("model_serving_endpoints", modelServingEndpointConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_model_serving_endpoint_test.go b/bundle/deploy/terraform/tfdyn/convert_model_serving_endpoint_test.go deleted file mode 100644 index fbb3d39a72c..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_model_serving_endpoint_test.go +++ /dev/null @@ -1,87 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/serving" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertModelServingEndpoint(t *testing.T) { - src := resources.ModelServingEndpoint{ - CreateServingEndpoint: serving.CreateServingEndpoint{ - Name: "name", - Config: &serving.EndpointCoreConfigInput{ - ServedModels: []serving.ServedModelInput{ - { - ModelName: "model_name", - ModelVersion: "1", - ScaleToZeroEnabled: true, - WorkloadSize: "Small", - }, - }, - TrafficConfig: &serving.TrafficConfig{ - Routes: []serving.Route{ - { - ServedModelName: "model_name-1", - TrafficPercentage: 100, - }, - }, - }, - }, - }, - Permissions: []resources.ModelServingEndpointPermission{ - { - Level: "CAN_VIEW", - UserName: "jane@doe.com", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = modelServingEndpointConverter{}.Convert(ctx, "my_model_serving_endpoint", vin, out) - require.NoError(t, err) - - // Assert equality on the model serving endpoint - assert.Equal(t, map[string]any{ - "name": "name", - "config": map[string]any{ - "served_models": []any{ - map[string]any{ - "model_name": "model_name", - "model_version": "1", - "scale_to_zero_enabled": true, - "workload_size": "Small", - }, - }, - "traffic_config": map[string]any{ - "routes": []any{ - map[string]any{ - "served_model_name": "model_name-1", - "traffic_percentage": int64(100), - }, - }, - }, - }, - }, out.ModelServing["my_model_serving_endpoint"]) - - // Assert equality on the permissions - assert.Equal(t, &schema.ResourcePermissions{ - ServingEndpointId: "${databricks_model_serving.my_model_serving_endpoint.serving_endpoint_id}", - AccessControl: []schema.ResourcePermissionsAccessControl{ - { - PermissionLevel: "CAN_VIEW", - UserName: "jane@doe.com", - }, - }, - }, out.Permissions["model_serving_my_model_serving_endpoint"]) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_model_test.go b/bundle/deploy/terraform/tfdyn/convert_model_test.go deleted file mode 100644 index 3d7e8b22c4f..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_model_test.go +++ /dev/null @@ -1,73 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/ml" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertModel(t *testing.T) { - src := resources.MlflowModel{ - CreateModelRequest: ml.CreateModelRequest{ - Name: "name", - Description: "description", - Tags: []ml.ModelTag{ - { - Key: "k1", - Value: "v1", - }, - { - Key: "k2", - Value: "v2", - }, - }, - }, - Permissions: []resources.MlflowModelPermission{ - { - Level: "CAN_READ", - UserName: "jane@doe.com", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = modelConverter{}.Convert(ctx, "my_model", vin, out) - require.NoError(t, err) - - // Assert equality on the model - assert.Equal(t, map[string]any{ - "name": "name", - "description": "description", - "tags": []any{ - map[string]any{ - "key": "k1", - "value": "v1", - }, - map[string]any{ - "key": "k2", - "value": "v2", - }, - }, - }, out.MlflowModel["my_model"]) - - // Assert equality on the permissions - assert.Equal(t, &schema.ResourcePermissions{ - RegisteredModelId: "${databricks_mlflow_model.my_model.registered_model_id}", - AccessControl: []schema.ResourcePermissionsAccessControl{ - { - PermissionLevel: "CAN_READ", - UserName: "jane@doe.com", - }, - }, - }, out.Permissions["mlflow_model_my_model"]) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_permissions.go b/bundle/deploy/terraform/tfdyn/convert_permissions.go deleted file mode 100644 index 99e8d29737c..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_permissions.go +++ /dev/null @@ -1,32 +0,0 @@ -package tfdyn - -import ( - "context" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" -) - -func convertPermissionsResource(ctx context.Context, vin dyn.Value) *schema.ResourcePermissions { - permissions, ok := vin.Get("permissions").AsSequence() - if !ok || len(permissions) == 0 { - return nil - } - - resource := &schema.ResourcePermissions{} - for _, permission := range permissions { - level, _ := permission.Get("level").AsString() - userName, _ := permission.Get("user_name").AsString() - groupName, _ := permission.Get("group_name").AsString() - servicePrincipalName, _ := permission.Get("service_principal_name").AsString() - - resource.AccessControl = append(resource.AccessControl, schema.ResourcePermissionsAccessControl{ - PermissionLevel: level, - UserName: userName, - GroupName: groupName, - ServicePrincipalName: servicePrincipalName, - }) - } - - return resource -} diff --git a/bundle/deploy/terraform/tfdyn/convert_permissions_test.go b/bundle/deploy/terraform/tfdyn/convert_permissions_test.go deleted file mode 100644 index 4d0d2d7481b..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_permissions_test.go +++ /dev/null @@ -1,84 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertPermissions(t *testing.T) { - src := resources.Job{ - Permissions: []resources.JobPermission{ - { - Level: "CAN_VIEW", - UserName: "jane@doe.com", - }, - { - Level: "CAN_MANAGE", - GroupName: "special admins", - }, - { - Level: "CAN_MANAGE_RUN", - ServicePrincipalName: "spn", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - resource := convertPermissionsResource(ctx, vin) - require.NotNil(t, resource) - assert.Equal(t, []schema.ResourcePermissionsAccessControl{ - { - PermissionLevel: "CAN_VIEW", - UserName: "jane@doe.com", - GroupName: "", - ServicePrincipalName: "", - }, - { - PermissionLevel: "CAN_MANAGE", - UserName: "", - GroupName: "special admins", - ServicePrincipalName: "", - }, - { - PermissionLevel: "CAN_MANAGE_RUN", - UserName: "", - GroupName: "", - ServicePrincipalName: "spn", - }, - }, resource.AccessControl) -} - -func TestConvertPermissionsNil(t *testing.T) { - src := resources.Job{ - Permissions: nil, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - resource := convertPermissionsResource(ctx, vin) - assert.Nil(t, resource) -} - -func TestConvertPermissionsEmpty(t *testing.T) { - src := resources.Job{ - Permissions: []resources.JobPermission{}, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - resource := convertPermissionsResource(ctx, vin) - assert.Nil(t, resource) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_pipeline.go b/bundle/deploy/terraform/tfdyn/convert_pipeline.go deleted file mode 100644 index 2eacbf714af..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_pipeline.go +++ /dev/null @@ -1,67 +0,0 @@ -package tfdyn - -import ( - "context" - "fmt" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" -) - -func convertPipelineResource(ctx context.Context, vin dyn.Value) (dyn.Value, error) { - // Modify top-level keys. - vout, err := renameKeys(vin, map[string]string{ - "libraries": "library", - "clusters": "cluster", - "notifications": "notification", - }) - if err != nil { - return dyn.InvalidValue, err - } - - // Current Terraform provider does not support the cascade_on_destroy attribute yet. - // ValidateCascadeOnDestroy rejects it here and provides an explicit error message. - vout, err = dyn.DropKeys(vout, []string{"dry_run", "cascade_on_destroy"}) - if err != nil { - return dyn.InvalidValue, err - } - - // Normalize the output value to the target schema. - vout, diags := convert.Normalize(schema.ResourcePipeline{}, vout) - for _, diag := range diags { - log.Debugf(ctx, "pipeline normalization diagnostic: %s", diag.Summary) - } - - return vout, err -} - -type pipelineConverter struct{} - -func (pipelineConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - vout, err := convertPipelineResource(ctx, vin) - if err != nil { - return err - } - - vout, err = convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - // Add the converted resource to the output. - out.Pipeline[key] = vout.AsAny() - - // Configure permissions for this resource. - if permissions := convertPermissionsResource(ctx, vin); permissions != nil { - permissions.PipelineId = fmt.Sprintf("${databricks_pipeline.%s.id}", key) - out.Permissions["pipeline_"+key] = permissions - } - - return nil -} - -func init() { - registerConverter("pipelines", pipelineConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_pipeline_test.go b/bundle/deploy/terraform/tfdyn/convert_pipeline_test.go deleted file mode 100644 index fe6620a00c2..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_pipeline_test.go +++ /dev/null @@ -1,140 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/pipelines" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertPipeline(t *testing.T) { - src := resources.Pipeline{ - CreatePipeline: pipelines.CreatePipeline{ - Name: "my pipeline", - // This fields is not part of TF schema yet, but once we upgrade to TF version that supports it, this test will fail because run_as - // will be exposed which is expected and test will need to be updated. - RunAs: &pipelines.RunAs{ - UserName: "foo@bar.test", - }, - // We expect AllowDuplicateNames and DryRun to be ignored and not passed to the TF output. - // This is not supported by TF now, so we don't want to expose it. - AllowDuplicateNames: true, - DryRun: true, - Libraries: []pipelines.PipelineLibrary{ - { - Notebook: &pipelines.NotebookLibrary{ - Path: "notebook path", - }, - }, - { - File: &pipelines.FileLibrary{ - Path: "file path", - }, - }, - }, - Notifications: []pipelines.Notifications{ - { - Alerts: []string{ - "on-update-fatal-failure", - }, - EmailRecipients: []string{ - "jane@doe.com", - }, - }, - { - Alerts: []string{ - "on-update-failure", - "on-flow-failure", - }, - EmailRecipients: []string{ - "jane@doe.com", - "john@doe.com", - }, - }, - }, - Clusters: []pipelines.PipelineCluster{ - { - Label: "default", - NumWorkers: 1, - }, - }, - }, - Permissions: []resources.PipelinePermission{ - { - Level: "CAN_VIEW", - UserName: "jane@doe.com", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = pipelineConverter{}.Convert(ctx, "my_pipeline", vin, out) - require.NoError(t, err) - - // Assert equality on the pipeline - assert.Equal(t, map[string]any{ - "name": "my pipeline", - "library": []any{ - map[string]any{ - "notebook": map[string]any{ - "path": "notebook path", - }, - }, - map[string]any{ - "file": map[string]any{ - "path": "file path", - }, - }, - }, - "notification": []any{ - map[string]any{ - "alerts": []any{ - "on-update-fatal-failure", - }, - "email_recipients": []any{ - "jane@doe.com", - }, - }, - map[string]any{ - "alerts": []any{ - "on-update-failure", - "on-flow-failure", - }, - "email_recipients": []any{ - "jane@doe.com", - "john@doe.com", - }, - }, - }, - "allow_duplicate_names": true, - "cluster": []any{ - map[string]any{ - "label": "default", - "num_workers": int64(1), - }, - }, - "run_as": map[string]any{ - "user_name": "foo@bar.test", - }, - }, out.Pipeline["my_pipeline"]) - - // Assert equality on the permissions - assert.Equal(t, &schema.ResourcePermissions{ - PipelineId: "${databricks_pipeline.my_pipeline.id}", - AccessControl: []schema.ResourcePermissionsAccessControl{ - { - PermissionLevel: "CAN_VIEW", - UserName: "jane@doe.com", - }, - }, - }, out.Permissions["pipeline_my_pipeline"]) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_postgres_branch.go b/bundle/deploy/terraform/tfdyn/convert_postgres_branch.go deleted file mode 100644 index 0867c392e0c..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_postgres_branch.go +++ /dev/null @@ -1,63 +0,0 @@ -package tfdyn - -import ( - "context" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" -) - -type postgresBranchConverter struct{} - -func (c postgresBranchConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - // The bundle config has flattened BranchSpec fields at the top level. - // Terraform expects them nested in a "spec" block. - specFields := specFieldNames(schema.ResourcePostgresBranchSpec{}) - topLevelFields := []string{"branch_id", "parent", "replace_existing", "purge_on_delete"} - - // Build the spec block from the flattened fields - specMap := make(map[string]dyn.Value) - for _, field := range specFields { - if v := vin.Get(field); v.Kind() != dyn.KindInvalid { - specMap[field] = v - } - } - - // Build the output with top-level fields and spec - outMap := make(map[string]dyn.Value) - - // Keep top-level fields - for _, field := range topLevelFields { - if v := vin.Get(field); v.Kind() != dyn.KindInvalid { - outMap[field] = v - } - } - - // Add spec block if we have any spec fields - if len(specMap) > 0 { - outMap["spec"] = dyn.V(specMap) - } - - vout := dyn.V(outMap) - - // Normalize the output value to the Terraform schema. - vout, diags := convert.Normalize(schema.ResourcePostgresBranch{}, vout) - for _, diag := range diags { - log.Debugf(ctx, "postgres branch normalization diagnostic: %s", diag.Summary) - } - - vout, err := convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - out.PostgresBranch[key] = vout.AsAny() - - return nil -} - -func init() { - registerConverter("postgres_branches", postgresBranchConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_postgres_branch_test.go b/bundle/deploy/terraform/tfdyn/convert_postgres_branch_test.go deleted file mode 100644 index 39902579cfe..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_postgres_branch_test.go +++ /dev/null @@ -1,133 +0,0 @@ -package tfdyn - -import ( - "testing" - "time" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/common/types/duration" - "github.com/databricks/databricks-sdk-go/service/postgres" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertPostgresBranch(t *testing.T) { - src := resources.PostgresBranch{ - PostgresBranchConfig: resources.PostgresBranchConfig{ - BranchId: "my-branch", - Parent: "projects/my-project", - BranchSpec: postgres.BranchSpec{ - IsProtected: true, - NoExpiry: true, - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresBranchConverter{}.Convert(ctx, "my_postgres_branch", vin, out) - require.NoError(t, err) - - postgresBranch := out.PostgresBranch["my_postgres_branch"] - assert.Equal(t, map[string]any{ - "branch_id": "my-branch", - "parent": "projects/my-project", - "spec": map[string]any{ - "is_protected": true, - "no_expiry": true, - }, - }, postgresBranch) -} - -func TestConvertPostgresBranchWithSourceBranch(t *testing.T) { - src := resources.PostgresBranch{ - PostgresBranchConfig: resources.PostgresBranchConfig{ - BranchId: "feature-branch", - Parent: "projects/my-project", - BranchSpec: postgres.BranchSpec{ - SourceBranch: "projects/my-project/branches/main", - SourceBranchLsn: "0/1234ABCD", - Ttl: duration.New(86400 * time.Second), - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresBranchConverter{}.Convert(ctx, "feature_postgres_branch", vin, out) - require.NoError(t, err) - - postgresBranch := out.PostgresBranch["feature_postgres_branch"] - assert.Equal(t, map[string]any{ - "branch_id": "feature-branch", - "parent": "projects/my-project", - "spec": map[string]any{ - "source_branch": "projects/my-project/branches/main", - "source_branch_lsn": "0/1234ABCD", - "ttl": "86400s", - }, - }, postgresBranch) -} - -func TestConvertPostgresBranchPurgeOnDelete(t *testing.T) { - src := resources.PostgresBranch{ - PostgresBranchConfig: resources.PostgresBranchConfig{ - BranchId: "my-branch", - Parent: "projects/my-project", - PurgeOnDelete: true, - BranchSpec: postgres.BranchSpec{ - IsProtected: true, - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresBranchConverter{}.Convert(ctx, "my_postgres_branch", vin, out) - require.NoError(t, err) - - postgresBranch := out.PostgresBranch["my_postgres_branch"] - assert.Equal(t, map[string]any{ - "branch_id": "my-branch", - "parent": "projects/my-project", - "purge_on_delete": true, - "spec": map[string]any{ - "is_protected": true, - }, - }, postgresBranch) -} - -func TestConvertPostgresBranchMinimal(t *testing.T) { - src := resources.PostgresBranch{ - PostgresBranchConfig: resources.PostgresBranchConfig{ - BranchId: "minimal-branch", - Parent: "projects/minimal-project", - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresBranchConverter{}.Convert(ctx, "minimal_postgres_branch", vin, out) - require.NoError(t, err) - - postgresBranch := out.PostgresBranch["minimal_postgres_branch"] - assert.Equal(t, map[string]any{ - "branch_id": "minimal-branch", - "parent": "projects/minimal-project", - }, postgresBranch) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_postgres_catalog.go b/bundle/deploy/terraform/tfdyn/convert_postgres_catalog.go deleted file mode 100644 index b84fb09d717..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_postgres_catalog.go +++ /dev/null @@ -1,56 +0,0 @@ -package tfdyn - -import ( - "context" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" -) - -type postgresCatalogConverter struct{} - -func (c postgresCatalogConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - // The bundle config has flattened CatalogCatalogSpec fields at the top level. - // Terraform expects them nested in a "spec" block. - specFields := specFieldNames(schema.ResourcePostgresCatalogSpec{}) - topLevelFields := []string{"catalog_id"} - - specMap := make(map[string]dyn.Value) - for _, field := range specFields { - if v := vin.Get(field); v.Kind() != dyn.KindInvalid { - specMap[field] = v - } - } - - outMap := make(map[string]dyn.Value) - for _, field := range topLevelFields { - if v := vin.Get(field); v.Kind() != dyn.KindInvalid { - outMap[field] = v - } - } - if len(specMap) > 0 { - outMap["spec"] = dyn.V(specMap) - } - - vout := dyn.V(outMap) - - vout, diags := convert.Normalize(schema.ResourcePostgresCatalog{}, vout) - for _, diag := range diags { - log.Debugf(ctx, "postgres catalog normalization diagnostic: %s", diag.Summary) - } - - vout, err := convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - out.PostgresCatalog[key] = vout.AsAny() - - return nil -} - -func init() { - registerConverter("postgres_catalogs", postgresCatalogConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_postgres_catalog_test.go b/bundle/deploy/terraform/tfdyn/convert_postgres_catalog_test.go deleted file mode 100644 index 8eca766f613..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_postgres_catalog_test.go +++ /dev/null @@ -1,73 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/postgres" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertPostgresCatalog(t *testing.T) { - src := resources.PostgresCatalog{ - PostgresCatalogConfig: resources.PostgresCatalogConfig{ - CatalogId: "shop_lakebase", - CatalogCatalogSpec: postgres.CatalogCatalogSpec{ - Branch: "projects/my-shop/branches/production", - PostgresDatabase: "appdb", - CreateDatabaseIfMissing: true, - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresCatalogConverter{}.Convert(ctx, "my_postgres_catalog", vin, out) - require.NoError(t, err) - - postgresCatalog := out.PostgresCatalog["my_postgres_catalog"] - assert.Equal(t, map[string]any{ - "catalog_id": "shop_lakebase", - "spec": map[string]any{ - "branch": "projects/my-shop/branches/production", - "postgres_database": "appdb", - "create_database_if_missing": true, - }, - }, postgresCatalog) -} - -func TestConvertPostgresCatalogMinimal(t *testing.T) { - src := resources.PostgresCatalog{ - PostgresCatalogConfig: resources.PostgresCatalogConfig{ - CatalogId: "minimal_catalog", - CatalogCatalogSpec: postgres.CatalogCatalogSpec{ - Branch: "projects/my-shop/branches/production", - PostgresDatabase: "appdb", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresCatalogConverter{}.Convert(ctx, "minimal_postgres_catalog", vin, out) - require.NoError(t, err) - - postgresCatalog := out.PostgresCatalog["minimal_postgres_catalog"] - assert.Equal(t, map[string]any{ - "catalog_id": "minimal_catalog", - "spec": map[string]any{ - "branch": "projects/my-shop/branches/production", - "postgres_database": "appdb", - }, - }, postgresCatalog) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_postgres_database.go b/bundle/deploy/terraform/tfdyn/convert_postgres_database.go deleted file mode 100644 index cb2f6e88de2..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_postgres_database.go +++ /dev/null @@ -1,63 +0,0 @@ -package tfdyn - -import ( - "context" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" -) - -type postgresDatabaseConverter struct{} - -func (c postgresDatabaseConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - // The bundle config has flattened DatabaseSpec fields at the top level. - // Terraform expects them nested in a "spec" block. - specFields := specFieldNames(schema.ResourcePostgresDatabaseSpec{}) - topLevelFields := []string{"database_id", "parent", "replace_existing"} - - // Build the spec block from the flattened fields - specMap := make(map[string]dyn.Value) - for _, field := range specFields { - if v := vin.Get(field); v.Kind() != dyn.KindInvalid { - specMap[field] = v - } - } - - // Build the output with top-level fields and spec - outMap := make(map[string]dyn.Value) - - // Keep top-level fields - for _, field := range topLevelFields { - if v := vin.Get(field); v.Kind() != dyn.KindInvalid { - outMap[field] = v - } - } - - // Add spec block if we have any spec fields - if len(specMap) > 0 { - outMap["spec"] = dyn.V(specMap) - } - - vout := dyn.V(outMap) - - // Normalize the output value to the Terraform schema. - vout, diags := convert.Normalize(schema.ResourcePostgresDatabase{}, vout) - for _, diag := range diags { - log.Debugf(ctx, "postgres database normalization diagnostic: %s", diag.Summary) - } - - vout, err := convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - out.PostgresDatabase[key] = vout.AsAny() - - return nil -} - -func init() { - registerConverter("postgres_databases", postgresDatabaseConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_postgres_database_test.go b/bundle/deploy/terraform/tfdyn/convert_postgres_database_test.go deleted file mode 100644 index 3276be62856..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_postgres_database_test.go +++ /dev/null @@ -1,73 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/postgres" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertPostgresDatabase(t *testing.T) { - src := resources.PostgresDatabase{ - PostgresDatabaseConfig: resources.PostgresDatabaseConfig{ - DatabaseId: "my-database", - Parent: "projects/my-project/branches/main", - DatabaseDatabaseSpec: postgres.DatabaseDatabaseSpec{ - PostgresDatabase: "my_postgres_db", - Role: "projects/my-project/branches/main/roles/owner", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresDatabaseConverter{}.Convert(ctx, "my_postgres_database", vin, out) - require.NoError(t, err) - - postgresDatabase := out.PostgresDatabase["my_postgres_database"] - assert.Equal(t, map[string]any{ - "database_id": "my-database", - "parent": "projects/my-project/branches/main", - "spec": map[string]any{ - "postgres_database": "my_postgres_db", - "role": "projects/my-project/branches/main/roles/owner", - }, - }, postgresDatabase) -} - -func TestConvertPostgresDatabaseMinimal(t *testing.T) { - src := resources.PostgresDatabase{ - PostgresDatabaseConfig: resources.PostgresDatabaseConfig{ - DatabaseId: "minimal-database", - Parent: "projects/my-project/branches/main", - DatabaseDatabaseSpec: postgres.DatabaseDatabaseSpec{ - PostgresDatabase: "minimal_db", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresDatabaseConverter{}.Convert(ctx, "minimal_postgres_database", vin, out) - require.NoError(t, err) - - postgresDatabase := out.PostgresDatabase["minimal_postgres_database"] - assert.Equal(t, map[string]any{ - "database_id": "minimal-database", - "parent": "projects/my-project/branches/main", - "spec": map[string]any{ - "postgres_database": "minimal_db", - }, - }, postgresDatabase) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_postgres_endpoint.go b/bundle/deploy/terraform/tfdyn/convert_postgres_endpoint.go deleted file mode 100644 index b603abfcb75..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_postgres_endpoint.go +++ /dev/null @@ -1,63 +0,0 @@ -package tfdyn - -import ( - "context" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" -) - -type postgresEndpointConverter struct{} - -func (c postgresEndpointConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - // The bundle config has flattened EndpointSpec fields at the top level. - // Terraform expects them nested in a "spec" block. - specFields := specFieldNames(schema.ResourcePostgresEndpointSpec{}) - topLevelFields := []string{"endpoint_id", "parent", "replace_existing"} - - // Build the spec block from the flattened fields - specMap := make(map[string]dyn.Value) - for _, field := range specFields { - if v := vin.Get(field); v.Kind() != dyn.KindInvalid { - specMap[field] = v - } - } - - // Build the output with top-level fields and spec - outMap := make(map[string]dyn.Value) - - // Keep top-level fields - for _, field := range topLevelFields { - if v := vin.Get(field); v.Kind() != dyn.KindInvalid { - outMap[field] = v - } - } - - // Add spec block if we have any spec fields - if len(specMap) > 0 { - outMap["spec"] = dyn.V(specMap) - } - - vout := dyn.V(outMap) - - // Normalize the output value to the Terraform schema. - vout, diags := convert.Normalize(schema.ResourcePostgresEndpoint{}, vout) - for _, diag := range diags { - log.Debugf(ctx, "postgres endpoint normalization diagnostic: %s", diag.Summary) - } - - vout, err := convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - out.PostgresEndpoint[key] = vout.AsAny() - - return nil -} - -func init() { - registerConverter("postgres_endpoints", postgresEndpointConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_postgres_endpoint_test.go b/bundle/deploy/terraform/tfdyn/convert_postgres_endpoint_test.go deleted file mode 100644 index 27f6ec5391e..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_postgres_endpoint_test.go +++ /dev/null @@ -1,134 +0,0 @@ -package tfdyn - -import ( - "testing" - "time" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/common/types/duration" - "github.com/databricks/databricks-sdk-go/service/postgres" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertPostgresEndpoint(t *testing.T) { - src := resources.PostgresEndpoint{ - PostgresEndpointConfig: resources.PostgresEndpointConfig{ - EndpointId: "my-endpoint", - Parent: "projects/my-project/branches/main", - EndpointSpec: postgres.EndpointSpec{ - EndpointType: postgres.EndpointTypeEndpointTypeReadWrite, - AutoscalingLimitMinCu: 0.5, - AutoscalingLimitMaxCu: 4, - SuspendTimeoutDuration: duration.New(300 * time.Second), - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresEndpointConverter{}.Convert(ctx, "my_postgres_endpoint", vin, out) - require.NoError(t, err) - - postgresEndpoint := out.PostgresEndpoint["my_postgres_endpoint"] - assert.Equal(t, map[string]any{ - "endpoint_id": "my-endpoint", - "parent": "projects/my-project/branches/main", - "spec": map[string]any{ - "endpoint_type": "ENDPOINT_TYPE_READ_WRITE", - "autoscaling_limit_min_cu": 0.5, - "autoscaling_limit_max_cu": float64(4), - "suspend_timeout_duration": "300s", - }, - }, postgresEndpoint) -} - -func TestConvertPostgresEndpointReadOnly(t *testing.T) { - src := resources.PostgresEndpoint{ - PostgresEndpointConfig: resources.PostgresEndpointConfig{ - EndpointId: "readonly-endpoint", - Parent: "projects/my-project/branches/main", - EndpointSpec: postgres.EndpointSpec{ - EndpointType: postgres.EndpointTypeEndpointTypeReadOnly, - NoSuspension: true, - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresEndpointConverter{}.Convert(ctx, "readonly_postgres_endpoint", vin, out) - require.NoError(t, err) - - postgresEndpoint := out.PostgresEndpoint["readonly_postgres_endpoint"] - assert.Equal(t, map[string]any{ - "endpoint_id": "readonly-endpoint", - "parent": "projects/my-project/branches/main", - "spec": map[string]any{ - "endpoint_type": "ENDPOINT_TYPE_READ_ONLY", - "no_suspension": true, - }, - }, postgresEndpoint) -} - -func TestConvertPostgresEndpointWithSettings(t *testing.T) { - src := resources.PostgresEndpoint{ - PostgresEndpointConfig: resources.PostgresEndpointConfig{ - EndpointId: "settings-endpoint", - Parent: "projects/my-project/branches/main", - EndpointSpec: postgres.EndpointSpec{ - EndpointType: postgres.EndpointTypeEndpointTypeReadWrite, - Settings: &postgres.EndpointSettings{ - PgSettings: map[string]string{ - "max_connections": "100", - "shared_buffers": "256MB", - "effective_cache_size": "1GB", - "maintenance_work_mem": "64MB", - "checkpoint_timeout": "15min", - "work_mem": "4MB", - "random_page_cost": "1.1", - "effective_io_concurrency": "200", - }, - }, - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresEndpointConverter{}.Convert(ctx, "settings_postgres_endpoint", vin, out) - require.NoError(t, err) - - postgresEndpoint := out.PostgresEndpoint["settings_postgres_endpoint"] - assert.Equal(t, map[string]any{ - "endpoint_id": "settings-endpoint", - "parent": "projects/my-project/branches/main", - "spec": map[string]any{ - "endpoint_type": "ENDPOINT_TYPE_READ_WRITE", - "settings": map[string]any{ - "pg_settings": map[string]any{ - "max_connections": "100", - "shared_buffers": "256MB", - "effective_cache_size": "1GB", - "maintenance_work_mem": "64MB", - "checkpoint_timeout": "15min", - "work_mem": "4MB", - "random_page_cost": "1.1", - "effective_io_concurrency": "200", - }, - }, - }, - }, postgresEndpoint) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_postgres_project.go b/bundle/deploy/terraform/tfdyn/convert_postgres_project.go deleted file mode 100644 index a9525c1cece..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_postgres_project.go +++ /dev/null @@ -1,70 +0,0 @@ -package tfdyn - -import ( - "context" - "fmt" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" -) - -type postgresProjectConverter struct{} - -func (c postgresProjectConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - // The bundle config has flattened ProjectSpec fields at the top level. - // Terraform expects them nested in a "spec" block. - specFields := specFieldNames(schema.ResourcePostgresProjectSpec{}) - topLevelFields := []string{"project_id", "purge_on_delete"} - - // Build the spec block from the flattened fields - specMap := make(map[string]dyn.Value) - for _, field := range specFields { - if v := vin.Get(field); v.Kind() != dyn.KindInvalid { - specMap[field] = v - } - } - - // Build the output with project_id, purge_on_delete and spec - outMap := make(map[string]dyn.Value) - - // Keep top-level fields outside the spec block - for _, field := range topLevelFields { - if v := vin.Get(field); v.Kind() != dyn.KindInvalid { - outMap[field] = v - } - } - - // Add spec block if we have any spec fields - if len(specMap) > 0 { - outMap["spec"] = dyn.V(specMap) - } - - vout := dyn.V(outMap) - - // Normalize the output value to the Terraform schema. - vout, diags := convert.Normalize(schema.ResourcePostgresProject{}, vout) - for _, diag := range diags { - log.Debugf(ctx, "postgres project normalization diagnostic: %s", diag.Summary) - } - - vout, err := convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - out.PostgresProject[key] = vout.AsAny() - - // Configure permissions for this resource. - if permissions := convertPermissionsResource(ctx, vin); permissions != nil { - permissions.DatabaseProjectName = fmt.Sprintf("${databricks_postgres_project.%s.project_id}", key) - out.Permissions["postgres_project_"+key] = permissions - } - - return nil -} - -func init() { - registerConverter("postgres_projects", postgresProjectConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_postgres_project_test.go b/bundle/deploy/terraform/tfdyn/convert_postgres_project_test.go deleted file mode 100644 index 30251a4ada8..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_postgres_project_test.go +++ /dev/null @@ -1,159 +0,0 @@ -package tfdyn - -import ( - "testing" - "time" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/common/types/duration" - "github.com/databricks/databricks-sdk-go/service/postgres" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertPostgresProject(t *testing.T) { - src := resources.PostgresProject{ - PostgresProjectConfig: resources.PostgresProjectConfig{ - ProjectId: "my-project", - ProjectSpec: postgres.ProjectSpec{ - DisplayName: "My Postgres Project", - PgVersion: 17, - HistoryRetentionDuration: duration.New(86400 * time.Second), - DefaultEndpointSettings: &postgres.ProjectDefaultEndpointSettings{ - AutoscalingLimitMinCu: 0.5, - AutoscalingLimitMaxCu: 4, - SuspendTimeoutDuration: duration.New(300 * time.Second), - }, - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresProjectConverter{}.Convert(ctx, "my_postgres_project", vin, out) - require.NoError(t, err) - - postgresProject := out.PostgresProject["my_postgres_project"] - assert.Equal(t, map[string]any{ - "project_id": "my-project", - "spec": map[string]any{ - "display_name": "My Postgres Project", - "pg_version": int64(17), - "history_retention_duration": "86400s", - "default_endpoint_settings": map[string]any{ - "autoscaling_limit_min_cu": 0.5, - "autoscaling_limit_max_cu": float64(4), - "suspend_timeout_duration": "300s", - }, - }, - }, postgresProject) -} - -func TestConvertPostgresProjectWithPermissions(t *testing.T) { - src := resources.PostgresProject{ - PostgresProjectConfig: resources.PostgresProjectConfig{ - ProjectId: "my-project", - ProjectSpec: postgres.ProjectSpec{ - DisplayName: "My Postgres Project", - PgVersion: 17, - }, - }, - Permissions: []resources.Permission{ - { - Level: "CAN_USE", - UserName: "user@example.com", - }, - { - Level: "CAN_MANAGE", - ServicePrincipalName: "sp-name", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresProjectConverter{}.Convert(ctx, "my_postgres_project", vin, out) - require.NoError(t, err) - - postgresProject := out.PostgresProject["my_postgres_project"] - assert.Equal(t, map[string]any{ - "project_id": "my-project", - "spec": map[string]any{ - "display_name": "My Postgres Project", - "pg_version": int64(17), - }, - }, postgresProject) - - assert.Equal(t, &schema.ResourcePermissions{ - DatabaseProjectName: "${databricks_postgres_project.my_postgres_project.project_id}", - AccessControl: []schema.ResourcePermissionsAccessControl{ - { - PermissionLevel: "CAN_USE", - UserName: "user@example.com", - }, - { - PermissionLevel: "CAN_MANAGE", - ServicePrincipalName: "sp-name", - }, - }, - }, out.Permissions["postgres_project_my_postgres_project"]) -} - -func TestConvertPostgresProjectPurgeOnDelete(t *testing.T) { - src := resources.PostgresProject{ - PostgresProjectConfig: resources.PostgresProjectConfig{ - ProjectId: "my-project", - PurgeOnDelete: true, - ProjectSpec: postgres.ProjectSpec{ - DisplayName: "My Postgres Project", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresProjectConverter{}.Convert(ctx, "my_postgres_project", vin, out) - require.NoError(t, err) - - postgresProject := out.PostgresProject["my_postgres_project"] - assert.Equal(t, map[string]any{ - "project_id": "my-project", - "purge_on_delete": true, - "spec": map[string]any{ - "display_name": "My Postgres Project", - }, - }, postgresProject) -} - -func TestConvertPostgresProjectMinimal(t *testing.T) { - src := resources.PostgresProject{ - PostgresProjectConfig: resources.PostgresProjectConfig{ - ProjectId: "minimal-project", - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresProjectConverter{}.Convert(ctx, "minimal_postgres_project", vin, out) - require.NoError(t, err) - - postgresProject := out.PostgresProject["minimal_postgres_project"] - assert.Equal(t, map[string]any{ - "project_id": "minimal-project", - }, postgresProject) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_postgres_role.go b/bundle/deploy/terraform/tfdyn/convert_postgres_role.go deleted file mode 100644 index 0704db4e50d..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_postgres_role.go +++ /dev/null @@ -1,63 +0,0 @@ -package tfdyn - -import ( - "context" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" -) - -type postgresRoleConverter struct{} - -func (c postgresRoleConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - // The bundle config has flattened RoleRoleSpec fields at the top level. - // Terraform expects them nested in a "spec" block. - specFields := specFieldNames(schema.ResourcePostgresRoleSpec{}) - topLevelFields := []string{"role_id", "parent", "replace_existing"} - - // Build the spec block from the flattened fields - specMap := make(map[string]dyn.Value) - for _, field := range specFields { - if v := vin.Get(field); v.Kind() != dyn.KindInvalid { - specMap[field] = v - } - } - - // Build the output with top-level fields and spec - outMap := make(map[string]dyn.Value) - - // Keep top-level fields - for _, field := range topLevelFields { - if v := vin.Get(field); v.Kind() != dyn.KindInvalid { - outMap[field] = v - } - } - - // Add spec block if we have any spec fields - if len(specMap) > 0 { - outMap["spec"] = dyn.V(specMap) - } - - vout := dyn.V(outMap) - - // Normalize the output value to the Terraform schema. - vout, diags := convert.Normalize(schema.ResourcePostgresRole{}, vout) - for _, diag := range diags { - log.Debugf(ctx, "postgres role normalization diagnostic: %s", diag.Summary) - } - - vout, err := convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - out.PostgresRole[key] = vout.AsAny() - - return nil -} - -func init() { - registerConverter("postgres_roles", postgresRoleConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_postgres_role_test.go b/bundle/deploy/terraform/tfdyn/convert_postgres_role_test.go deleted file mode 100644 index 2fd11988ec0..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_postgres_role_test.go +++ /dev/null @@ -1,81 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/postgres" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertPostgresRole(t *testing.T) { - src := resources.PostgresRole{ - PostgresRoleConfig: resources.PostgresRoleConfig{ - RoleId: "my-role", - Parent: "projects/my-project/branches/main", - RoleRoleSpec: postgres.RoleRoleSpec{ - PostgresRole: "my_postgres_role", - IdentityType: postgres.RoleIdentityTypeUser, - AuthMethod: postgres.RoleAuthMethodLakebaseOauthV1, - Attributes: &postgres.RoleAttributes{ - Createdb: true, - }, - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresRoleConverter{}.Convert(ctx, "my_postgres_role", vin, out) - require.NoError(t, err) - - postgresRole := out.PostgresRole["my_postgres_role"] - assert.Equal(t, map[string]any{ - "role_id": "my-role", - "parent": "projects/my-project/branches/main", - "spec": map[string]any{ - "postgres_role": "my_postgres_role", - "identity_type": "USER", - "auth_method": "LAKEBASE_OAUTH_V1", - "attributes": map[string]any{ - "createdb": true, - }, - }, - }, postgresRole) -} - -func TestConvertPostgresRoleMinimal(t *testing.T) { - src := resources.PostgresRole{ - PostgresRoleConfig: resources.PostgresRoleConfig{ - RoleId: "minimal-role", - Parent: "projects/my-project/branches/main", - RoleRoleSpec: postgres.RoleRoleSpec{ - PostgresRole: "minimal_role", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresRoleConverter{}.Convert(ctx, "minimal_postgres_role", vin, out) - require.NoError(t, err) - - postgresRole := out.PostgresRole["minimal_postgres_role"] - assert.Equal(t, map[string]any{ - "role_id": "minimal-role", - "parent": "projects/my-project/branches/main", - "spec": map[string]any{ - "postgres_role": "minimal_role", - }, - }, postgresRole) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_postgres_synced_table.go b/bundle/deploy/terraform/tfdyn/convert_postgres_synced_table.go deleted file mode 100644 index 2f777294295..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_postgres_synced_table.go +++ /dev/null @@ -1,56 +0,0 @@ -package tfdyn - -import ( - "context" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" -) - -type postgresSyncedTableConverter struct{} - -func (c postgresSyncedTableConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - // The bundle config has flattened SyncedTableSyncedTableSpec fields at the top level. - // Terraform expects them nested in a "spec" block. - specFields := specFieldNames(schema.ResourcePostgresSyncedTableSpec{}) - topLevelFields := []string{"synced_table_id"} - - specMap := make(map[string]dyn.Value) - for _, field := range specFields { - if v := vin.Get(field); v.Kind() != dyn.KindInvalid { - specMap[field] = v - } - } - - outMap := make(map[string]dyn.Value) - for _, field := range topLevelFields { - if v := vin.Get(field); v.Kind() != dyn.KindInvalid { - outMap[field] = v - } - } - if len(specMap) > 0 { - outMap["spec"] = dyn.V(specMap) - } - - vout := dyn.V(outMap) - - vout, diags := convert.Normalize(schema.ResourcePostgresSyncedTable{}, vout) - for _, diag := range diags { - log.Debugf(ctx, "postgres synced table normalization diagnostic: %s", diag.Summary) - } - - vout, err := convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - out.PostgresSyncedTable[key] = vout.AsAny() - - return nil -} - -func init() { - registerConverter("postgres_synced_tables", postgresSyncedTableConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_postgres_synced_table_test.go b/bundle/deploy/terraform/tfdyn/convert_postgres_synced_table_test.go deleted file mode 100644 index 84e854e6e03..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_postgres_synced_table_test.go +++ /dev/null @@ -1,95 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/postgres" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertPostgresSyncedTable(t *testing.T) { - src := resources.PostgresSyncedTable{ - PostgresSyncedTableConfig: resources.PostgresSyncedTableConfig{ - SyncedTableId: "shop_lakebase.public.orders_synced", - SyncedTableSyncedTableSpec: postgres.SyncedTableSyncedTableSpec{ - Branch: "projects/my-shop/branches/production", - PostgresDatabase: "appdb", - SourceTableFullName: "main.raw.orders", - PrimaryKeyColumns: []string{"order_id"}, - TimeseriesKey: "updated_at", - SchedulingPolicy: postgres.SyncedTableSyncedTableSpecSyncedTableSchedulingPolicySnapshot, - CreateDatabaseObjectsIfMissing: true, - NewPipelineSpec: &postgres.NewPipelineSpec{ - StorageCatalog: "main", - StorageSchema: "pipelines", - }, - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresSyncedTableConverter{}.Convert(ctx, "my_postgres_synced_table", vin, out) - require.NoError(t, err) - - postgresSyncedTable := out.PostgresSyncedTable["my_postgres_synced_table"] - assert.Equal(t, map[string]any{ - "synced_table_id": "shop_lakebase.public.orders_synced", - "spec": map[string]any{ - "branch": "projects/my-shop/branches/production", - "postgres_database": "appdb", - "source_table_full_name": "main.raw.orders", - "primary_key_columns": []any{"order_id"}, - "timeseries_key": "updated_at", - "scheduling_policy": "SNAPSHOT", - "create_database_objects_if_missing": true, - "new_pipeline_spec": map[string]any{ - "storage_catalog": "main", - "storage_schema": "pipelines", - }, - }, - }, postgresSyncedTable) -} - -func TestConvertPostgresSyncedTableMinimal(t *testing.T) { - src := resources.PostgresSyncedTable{ - PostgresSyncedTableConfig: resources.PostgresSyncedTableConfig{ - SyncedTableId: "shop_lakebase.public.orders_synced", - SyncedTableSyncedTableSpec: postgres.SyncedTableSyncedTableSpec{ - Branch: "projects/my-shop/branches/production", - PostgresDatabase: "appdb", - SourceTableFullName: "main.raw.orders", - PrimaryKeyColumns: []string{"order_id"}, - SchedulingPolicy: postgres.SyncedTableSyncedTableSpecSyncedTableSchedulingPolicySnapshot, - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = postgresSyncedTableConverter{}.Convert(ctx, "minimal_postgres_synced_table", vin, out) - require.NoError(t, err) - - postgresSyncedTable := out.PostgresSyncedTable["minimal_postgres_synced_table"] - assert.Equal(t, map[string]any{ - "synced_table_id": "shop_lakebase.public.orders_synced", - "spec": map[string]any{ - "branch": "projects/my-shop/branches/production", - "postgres_database": "appdb", - "source_table_full_name": "main.raw.orders", - "primary_key_columns": []any{"order_id"}, - "scheduling_policy": "SNAPSHOT", - }, - }, postgresSyncedTable) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_quality_monitor.go b/bundle/deploy/terraform/tfdyn/convert_quality_monitor.go deleted file mode 100644 index 3e78bacc702..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_quality_monitor.go +++ /dev/null @@ -1,42 +0,0 @@ -package tfdyn - -import ( - "context" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" -) - -func convertQualityMonitorResource(ctx context.Context, vin dyn.Value) (dyn.Value, error) { - // Normalize the output value to the target schema. - vout, diags := convert.Normalize(schema.ResourceQualityMonitor{}, vin) - for _, diag := range diags { - log.Debugf(ctx, "monitor normalization diagnostic: %s", diag.Summary) - } - return vout, nil -} - -type qualityMonitorConverter struct{} - -func (qualityMonitorConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - vout, err := convertQualityMonitorResource(ctx, vin) - if err != nil { - return err - } - - vout, err = convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - // Add the converted resource to the output. - out.QualityMonitor[key] = vout.AsAny() - - return nil -} - -func init() { - registerConverter("quality_monitors", qualityMonitorConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_quality_monitor_test.go b/bundle/deploy/terraform/tfdyn/convert_quality_monitor_test.go deleted file mode 100644 index ad14945ff51..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_quality_monitor_test.go +++ /dev/null @@ -1,45 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/catalog" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertQualityMonitor(t *testing.T) { - src := resources.QualityMonitor{ - TableName: "test_table_name", - CreateMonitor: catalog.CreateMonitor{ - AssetsDir: "assets_dir", - OutputSchemaName: "output_schema_name", - InferenceLog: &catalog.MonitorInferenceLog{ - ModelIdCol: "model_id", - PredictionCol: "test_prediction_col", - ProblemType: "PROBLEM_TYPE_CLASSIFICATION", - }, - }, - } - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - ctx := t.Context() - out := schema.NewResources() - err = qualityMonitorConverter{}.Convert(ctx, "my_monitor", vin, out) - - require.NoError(t, err) - assert.Equal(t, map[string]any{ - "assets_dir": "assets_dir", - "output_schema_name": "output_schema_name", - "table_name": "test_table_name", - "inference_log": map[string]any{ - "model_id_col": "model_id", - "prediction_col": "test_prediction_col", - "problem_type": "PROBLEM_TYPE_CLASSIFICATION", - }, - }, out.QualityMonitor["my_monitor"]) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_registered_model.go b/bundle/deploy/terraform/tfdyn/convert_registered_model.go deleted file mode 100644 index 49e05b47e54..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_registered_model.go +++ /dev/null @@ -1,50 +0,0 @@ -package tfdyn - -import ( - "context" - "fmt" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" -) - -func convertRegisteredModelResource(ctx context.Context, vin dyn.Value) (dyn.Value, error) { - // Normalize the output value to the target schema. - vout, diags := convert.Normalize(schema.ResourceRegisteredModel{}, vin) - for _, diag := range diags { - log.Debugf(ctx, "registered model normalization diagnostic: %s", diag.Summary) - } - - return vout, nil -} - -type registeredModelConverter struct{} - -func (registeredModelConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - vout, err := convertRegisteredModelResource(ctx, vin) - if err != nil { - return err - } - - vout, err = convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - // Add the converted resource to the output. - out.RegisteredModel[key] = vout.AsAny() - - // Configure grants for this resource. - if grants := convertGrantsResource(ctx, vin); grants != nil { - grants.Function = fmt.Sprintf("${databricks_registered_model.%s.id}", key) - out.Grants["registered_model_"+key] = grants - } - - return nil -} - -func init() { - registerConverter("registered_models", registeredModelConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_registered_model_test.go b/bundle/deploy/terraform/tfdyn/convert_registered_model_test.go deleted file mode 100644 index dab20f45eb8..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_registered_model_test.go +++ /dev/null @@ -1,57 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/catalog" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertRegisteredModel(t *testing.T) { - src := resources.RegisteredModel{ - CreateRegisteredModelRequest: catalog.CreateRegisteredModelRequest{ - Name: "name", - CatalogName: "catalog", - SchemaName: "schema", - Comment: "comment", - }, - Grants: []catalog.PrivilegeAssignment{ - { - Privileges: []catalog.Privilege{catalog.PrivilegeExecute}, - Principal: "jane@doe.com", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = registeredModelConverter{}.Convert(ctx, "my_registered_model", vin, out) - require.NoError(t, err) - - // Assert equality on the registered model - assert.Equal(t, map[string]any{ - "name": "name", - "catalog_name": "catalog", - "schema_name": "schema", - "comment": "comment", - }, out.RegisteredModel["my_registered_model"]) - - // Assert equality on the grants - assert.Equal(t, &schema.ResourceGrants{ - Function: "${databricks_registered_model.my_registered_model.id}", - Grant: []schema.ResourceGrantsGrant{ - { - Privileges: []string{"EXECUTE"}, - Principal: "jane@doe.com", - }, - }, - }, out.Grants["registered_model_my_registered_model"]) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_schema.go b/bundle/deploy/terraform/tfdyn/convert_schema.go deleted file mode 100644 index 33fd8aab046..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_schema.go +++ /dev/null @@ -1,58 +0,0 @@ -package tfdyn - -import ( - "context" - "fmt" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" -) - -func convertSchemaResource(ctx context.Context, vin dyn.Value) (dyn.Value, error) { - // Normalize the output value to the target schema. - v, diags := convert.Normalize(schema.ResourceSchema{}, vin) - for _, diag := range diags { - log.Debugf(ctx, "schema normalization diagnostic: %s", diag.Summary) - } - - // We always set force destroy as it allows DABs to manage the lifecycle - // of the schema. It's the responsibility of the CLI to ensure the user - // is adequately warned when they try to delete a UC schema. - vout, err := dyn.SetByPath(v, dyn.MustPathFromString("force_destroy"), dyn.V(true)) - if err != nil { - return dyn.InvalidValue, err - } - - return vout, nil -} - -type schemaConverter struct{} - -func (schemaConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - vout, err := convertSchemaResource(ctx, vin) - if err != nil { - return err - } - - vout, err = convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - // Add the converted resource to the output. - out.Schema[key] = vout.AsAny() - - // Configure grants for this resource. - if grants := convertGrantsResource(ctx, vin); grants != nil { - grants.Schema = fmt.Sprintf("${databricks_schema.%s.id}", key) - out.Grants["schema_"+key] = grants - } - - return nil -} - -func init() { - registerConverter("schemas", schemaConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_schema_test.go b/bundle/deploy/terraform/tfdyn/convert_schema_test.go deleted file mode 100644 index 1d2431a5e16..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_schema_test.go +++ /dev/null @@ -1,74 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/catalog" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertSchema(t *testing.T) { - src := resources.Schema{ - CreateSchema: catalog.CreateSchema{ - Name: "name", - CatalogName: "catalog", - Comment: "comment", - Properties: map[string]string{ - "k1": "v1", - "k2": "v2", - }, - StorageRoot: "root", - }, - Grants: []catalog.PrivilegeAssignment{ - { - Privileges: []catalog.Privilege{catalog.PrivilegeExecute}, - Principal: "jack@gmail.com", - }, - { - Privileges: []catalog.Privilege{catalog.PrivilegeSelect}, - Principal: "jane@gmail.com", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = schemaConverter{}.Convert(ctx, "my_schema", vin, out) - require.NoError(t, err) - - // Assert equality on the schema - assert.Equal(t, map[string]any{ - "name": "name", - "catalog_name": "catalog", - "comment": "comment", - "properties": map[string]any{ - "k1": "v1", - "k2": "v2", - }, - "force_destroy": true, - "storage_root": "root", - }, out.Schema["my_schema"]) - - // Assert equality on the grants - assert.Equal(t, &schema.ResourceGrants{ - Schema: "${databricks_schema.my_schema.id}", - Grant: []schema.ResourceGrantsGrant{ - { - Privileges: []string{"EXECUTE"}, - Principal: "jack@gmail.com", - }, - { - Privileges: []string{"SELECT"}, - Principal: "jane@gmail.com", - }, - }, - }, out.Grants["schema_my_schema"]) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_secret_scope.go b/bundle/deploy/terraform/tfdyn/convert_secret_scope.go deleted file mode 100644 index fe6dfce79c9..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_secret_scope.go +++ /dev/null @@ -1,89 +0,0 @@ -package tfdyn - -import ( - "context" - "fmt" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" - "github.com/databricks/databricks-sdk-go/service/workspace" -) - -type resourceSecretAcl struct { - schema.ResourceSecretAcl - DependsOn []string `json:"depends_on,omitempty"` -} - -type secretScopeConverter struct{} - -func convertPermissionsSecretScope(key, scopeName string, permissions []dyn.Value, out *schema.Resources) { - var previousAclKey string - - for idx, permission := range permissions { - level, _ := permission.Get("level").AsString() - userName, _ := permission.Get("user_name").AsString() - groupName, _ := permission.Get("group_name").AsString() - servicePrincipalName, _ := permission.Get("service_principal_name").AsString() - - principal := "" - if userName != "" { - principal = userName - } else if groupName != "" { - principal = groupName - } else if servicePrincipalName != "" { - principal = servicePrincipalName - } - - // Build depends_on list - always depend on scope, plus previous ACL if exists. - // This forces Terraform to execute ACL operations sequentially, avoiding - // a backend race condition where parallel ACL modifications return inconsistent results. - dependsOn := []string{"databricks_secret_scope." + key} - if previousAclKey != "" { - dependsOn = append(dependsOn, "databricks_secret_acl."+previousAclKey) - } - - acl := &resourceSecretAcl{ - ResourceSecretAcl: schema.ResourceSecretAcl{ - Permission: level, - Principal: principal, - Scope: scopeName, - }, - DependsOn: dependsOn, - } - - aclKey := fmt.Sprintf("secret_acl_%s_%d", key, idx) - out.SecretAcl[aclKey] = acl - - previousAclKey = aclKey - } -} - -func (s secretScopeConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - // Normalize the output value to the target schema. - vout, diags := convert.Normalize(workspace.SecretScope{}, vin) - for _, diag := range diags { - log.Debugf(ctx, "secret scope normalization diagnostic: %s", diag.Summary) - } - - vout, err := convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - out.SecretScope[key] = vout.AsAny() - - // Configure permissions for this resource - scopeName, _ := vin.Get("name").AsString() - permissions, ok := vin.Get("permissions").AsSequence() - if ok && len(permissions) > 0 { - convertPermissionsSecretScope(key, scopeName, permissions, out) - } - - return nil -} - -func init() { - registerConverter("secret_scopes", secretScopeConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_secret_scope_test.go b/bundle/deploy/terraform/tfdyn/convert_secret_scope_test.go deleted file mode 100644 index a90916e281c..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_secret_scope_test.go +++ /dev/null @@ -1,101 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertSecretScopeWithPermissions(t *testing.T) { - src := resources.SecretScope{ - Name: "my_scope", - Permissions: []resources.SecretScopePermission{ - {UserName: "user@example.com", Level: resources.SecretScopePermissionLevelWrite}, - {GroupName: "data-team", Level: resources.SecretScopePermissionLevelRead}, - {ServicePrincipalName: "sp-uuid", Level: resources.SecretScopePermissionLevelManage}, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = secretScopeConverter{}.Convert(ctx, "my_scope", vin, out) - require.NoError(t, err) - - // Verify ACL count - assert.Len(t, out.SecretAcl, 3) - - // Verify first ACL depends only on scope - acl0 := out.SecretAcl["secret_acl_my_scope_0"].(*resourceSecretAcl) - assert.Equal(t, "user@example.com", acl0.Principal) - assert.Equal(t, "WRITE", acl0.Permission) - assert.Equal(t, []string{"databricks_secret_scope.my_scope"}, acl0.DependsOn) - - // Verify second ACL depends on scope + first ACL (sequential execution) - acl1 := out.SecretAcl["secret_acl_my_scope_1"].(*resourceSecretAcl) - assert.Equal(t, "data-team", acl1.Principal) - assert.Equal(t, "READ", acl1.Permission) - assert.Equal(t, []string{ - "databricks_secret_scope.my_scope", - "databricks_secret_acl.secret_acl_my_scope_0", - }, acl1.DependsOn) - - // Verify third ACL depends on scope + second ACL (sequential execution) - acl2 := out.SecretAcl["secret_acl_my_scope_2"].(*resourceSecretAcl) - assert.Equal(t, "sp-uuid", acl2.Principal) - assert.Equal(t, "MANAGE", acl2.Permission) - assert.Equal(t, []string{ - "databricks_secret_scope.my_scope", - "databricks_secret_acl.secret_acl_my_scope_1", - }, acl2.DependsOn) -} - -func TestConvertSecretScopeSinglePermission(t *testing.T) { - src := resources.SecretScope{ - Name: "single_scope", - Permissions: []resources.SecretScopePermission{ - {UserName: "user@example.com", Level: resources.SecretScopePermissionLevelManage}, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = secretScopeConverter{}.Convert(ctx, "single_scope", vin, out) - require.NoError(t, err) - - // Single ACL should only depend on scope (no chaining needed) - assert.Len(t, out.SecretAcl, 1) - acl := out.SecretAcl["secret_acl_single_scope_0"].(*resourceSecretAcl) - assert.Equal(t, "user@example.com", acl.Principal) - assert.Equal(t, []string{"databricks_secret_scope.single_scope"}, acl.DependsOn) -} - -func TestConvertSecretScopeNoPermissions(t *testing.T) { - src := resources.SecretScope{ - Name: "no_permissions_scope", - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = secretScopeConverter{}.Convert(ctx, "no_permissions_scope", vin, out) - require.NoError(t, err) - - // No ACLs should be created - assert.Empty(t, out.SecretAcl) - - // But the scope should still be created - assert.Contains(t, out.SecretScope, "no_permissions_scope") -} diff --git a/bundle/deploy/terraform/tfdyn/convert_sql_warehouse.go b/bundle/deploy/terraform/tfdyn/convert_sql_warehouse.go deleted file mode 100644 index 0107ba24601..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_sql_warehouse.go +++ /dev/null @@ -1,50 +0,0 @@ -package tfdyn - -import ( - "context" - "fmt" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" - "github.com/databricks/databricks-sdk-go/service/sql" -) - -func convertSqlWarehouseResource(ctx context.Context, vin dyn.Value) (dyn.Value, error) { - vout, diags := convert.Normalize(sql.CreateWarehouseRequest{}, vin) - for _, diag := range diags { - log.Debugf(ctx, "sql warehouse normalization diagnostic: %s", diag.Summary) - } - - return vout, nil -} - -type sqlWarehouseConverter struct{} - -func (sqlWarehouseConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - vout, err := convertSqlWarehouseResource(ctx, vin) - if err != nil { - return err - } - - vout, err = convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - // Add the converted resource to the output. - out.SqlEndpoint[key] = vout.AsAny() - - // Configure permissions for this resource. - if permissions := convertPermissionsResource(ctx, vin); permissions != nil { - permissions.SqlEndpointId = fmt.Sprintf("${databricks_sql_endpoint.%s.id}", key) - out.Permissions["sql_endpoint_"+key] = permissions - } - - return nil -} - -func init() { - registerConverter("sql_warehouses", sqlWarehouseConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_sql_warehouse_test.go b/bundle/deploy/terraform/tfdyn/convert_sql_warehouse_test.go deleted file mode 100644 index a8be3a12d6f..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_sql_warehouse_test.go +++ /dev/null @@ -1,66 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/sql" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertSqlWarehouse(t *testing.T) { - src := resources.SqlWarehouse{ - CreateWarehouseRequest: sql.CreateWarehouseRequest{ - AutoStopMins: 120, - ClusterSize: "X-Large", - EnableServerlessCompute: true, - MaxNumClusters: 1, - MinNumClusters: 1, - Name: "test_sql_warehouse", - Tags: &sql.EndpointTags{ - CustomTags: []sql.EndpointTagPair{ - { - Key: "key", - Value: "value", - }, - }, - }, - Channel: &sql.Channel{ - Name: "CHANNEL_NAME", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = sqlWarehouseConverter{}.Convert(ctx, "test_sql_warehouse", vin, out) - require.NoError(t, err) - - sqlWarehouse := out.SqlEndpoint["test_sql_warehouse"] - assert.Equal(t, map[string]any{ - "name": "test_sql_warehouse", - "tags": map[string]any{ - "custom_tags": []any{ - map[string]any{ - "key": "key", - "value": "value", - }, - }, - }, - "channel": map[string]any{ - "name": "CHANNEL_NAME", - }, - "auto_stop_mins": int64(120), - "cluster_size": "X-Large", - "enable_serverless_compute": true, - "max_num_clusters": int64(1), - "min_num_clusters": int64(1), - }, sqlWarehouse) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_synced_database_table.go b/bundle/deploy/terraform/tfdyn/convert_synced_database_table.go deleted file mode 100644 index 5e64711629c..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_synced_database_table.go +++ /dev/null @@ -1,34 +0,0 @@ -package tfdyn - -import ( - "context" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" - "github.com/databricks/databricks-sdk-go/service/database" -) - -type syncedDatabaseTableConverter struct{} - -func (s syncedDatabaseTableConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - // Normalize the output value to the target schema. - vout, diags := convert.Normalize(database.SyncedDatabaseTable{}, vin) - for _, diag := range diags { - log.Debugf(ctx, "synced database table normalization diagnostic: %s", diag.Summary) - } - - var err error - vout, err = convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - out.DatabaseSyncedDatabaseTable[key] = vout.AsAny() - - return nil -} - -func init() { - registerConverter("synced_database_tables", syncedDatabaseTableConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_volume.go b/bundle/deploy/terraform/tfdyn/convert_volume.go deleted file mode 100644 index e8becaea175..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_volume.go +++ /dev/null @@ -1,56 +0,0 @@ -package tfdyn - -import ( - "context" - "fmt" - - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/cli/libs/log" -) - -func convertVolumeResource(ctx context.Context, vin dyn.Value) (dyn.Value, error) { - // volume_path is computed by the API and cannot be configured in Terraform. - vin, err := dyn.DropKeys(vin, []string{"volume_path"}) - if err != nil { - return dyn.InvalidValue, err - } - - // Normalize the output value to the target schema. - vout, diags := convert.Normalize(schema.ResourceVolume{}, vin) - for _, diag := range diags { - log.Debugf(ctx, "volume normalization diagnostic: %s", diag.Summary) - } - - return vout, nil -} - -type volumeConverter struct{} - -func (volumeConverter) Convert(ctx context.Context, key string, vin dyn.Value, out *schema.Resources) error { - vout, err := convertVolumeResource(ctx, vin) - if err != nil { - return err - } - - vout, err = convertLifecycle(ctx, vout, vin.Get("lifecycle")) - if err != nil { - return err - } - - // Add the converted resource to the output. - out.Volume[key] = vout.AsAny() - - // Configure grants for this resource. - if grants := convertGrantsResource(ctx, vin); grants != nil { - grants.Volume = fmt.Sprintf("${databricks_volume.%s.id}", key) - out.Grants["volume_"+key] = grants - } - - return nil -} - -func init() { - registerConverter("volumes", volumeConverter{}) -} diff --git a/bundle/deploy/terraform/tfdyn/convert_volume_test.go b/bundle/deploy/terraform/tfdyn/convert_volume_test.go deleted file mode 100644 index f21b1024483..00000000000 --- a/bundle/deploy/terraform/tfdyn/convert_volume_test.go +++ /dev/null @@ -1,70 +0,0 @@ -package tfdyn - -import ( - "testing" - - "github.com/databricks/cli/bundle/config/resources" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/convert" - "github.com/databricks/databricks-sdk-go/service/catalog" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func TestConvertVolume(t *testing.T) { - src := resources.Volume{ - CreateVolumeRequestContent: catalog.CreateVolumeRequestContent{ - CatalogName: "catalog", - Comment: "comment", - Name: "name", - SchemaName: "schema", - StorageLocation: "s3://bucket/path", - VolumeType: "EXTERNAL", - }, - VolumePath: "/Volumes/catalog/schema/name", - Grants: []catalog.PrivilegeAssignment{ - { - Privileges: []catalog.Privilege{catalog.PrivilegeReadVolume}, - Principal: "jack@gmail.com", - }, - { - Privileges: []catalog.Privilege{catalog.PrivilegeWriteVolume}, - Principal: "jane@gmail.com", - }, - }, - } - - vin, err := convert.FromTyped(src, dyn.NilValue) - require.NoError(t, err) - - ctx := t.Context() - out := schema.NewResources() - err = volumeConverter{}.Convert(ctx, "my_volume", vin, out) - require.NoError(t, err) - - // Assert equality on the volume - require.Equal(t, map[string]any{ - "catalog_name": "catalog", - "comment": "comment", - "name": "name", - "schema_name": "schema", - "storage_location": "s3://bucket/path", - "volume_type": "EXTERNAL", - }, out.Volume["my_volume"]) - - // Assert equality on the grants - assert.Equal(t, &schema.ResourceGrants{ - Volume: "${databricks_volume.my_volume.id}", - Grant: []schema.ResourceGrantsGrant{ - { - Privileges: []string{"READ_VOLUME"}, - Principal: "jack@gmail.com", - }, - { - Privileges: []string{"WRITE_VOLUME"}, - Principal: "jane@gmail.com", - }, - }, - }, out.Grants["volume_my_volume"]) -} diff --git a/bundle/deploy/terraform/tfdyn/lifecycle.go b/bundle/deploy/terraform/tfdyn/lifecycle.go deleted file mode 100644 index 669aa830400..00000000000 --- a/bundle/deploy/terraform/tfdyn/lifecycle.go +++ /dev/null @@ -1,32 +0,0 @@ -package tfdyn - -import ( - "context" - - "github.com/databricks/cli/libs/dyn" -) - -func convertLifecycle(ctx context.Context, vout, vLifecycle dyn.Value) (dyn.Value, error) { - if !vLifecycle.IsValid() { - return vout, nil - } - - // Strip lifecycle.started: it is a DABs-only field not understood by Terraform. - var err error - vLifecycle, err = dyn.DropKeys(vLifecycle, []string{"started"}) - if err != nil { - return dyn.InvalidValue, err - } - - // If only lifecycle.started was set (now empty), skip setting the lifecycle block. - if m, ok := vLifecycle.AsMap(); ok && m.Len() == 0 { - return vout, nil - } - - vout, err = dyn.Set(vout, "lifecycle", vLifecycle) - if err != nil { - return dyn.InvalidValue, err - } - - return vout, nil -} diff --git a/bundle/deploy/terraform/tfdyn/rename_keys.go b/bundle/deploy/terraform/tfdyn/rename_keys.go deleted file mode 100644 index 95904575f87..00000000000 --- a/bundle/deploy/terraform/tfdyn/rename_keys.go +++ /dev/null @@ -1,45 +0,0 @@ -package tfdyn - -import ( - "github.com/databricks/cli/libs/dyn" - "github.com/databricks/cli/libs/dyn/merge" -) - -// renameKeys renames keys in the given map value. -// -// Terraform resources sometimes use singular names for repeating blocks where the API -// definition uses the plural name. This function can convert between the two. -func renameKeys(v dyn.Value, rename map[string]string) (dyn.Value, error) { - var err error - acc := dyn.V(map[string]dyn.Value{}) - - nv, err := dyn.Walk(v, func(p dyn.Path, v dyn.Value) (dyn.Value, error) { - if len(p) == 0 { - return v, nil - } - - // Check if this key should be renamed. - for oldKey, newKey := range rename { - if p[0].Key() != oldKey { - continue - } - - // Add the new key to the accumulator. - p[0] = dyn.Key(newKey) - acc, err = dyn.SetByPath(acc, p, v) - if err != nil { - return dyn.InvalidValue, err - } - return dyn.InvalidValue, dyn.ErrDrop - } - - // Pass through all other values. - return v, dyn.ErrSkip - }) - if err != nil { - return dyn.InvalidValue, err - } - - // Merge the accumulator with the original value. - return merge.Merge(nv, acc) -} diff --git a/bundle/deploy/terraform/tfdyn/spec_fields.go b/bundle/deploy/terraform/tfdyn/spec_fields.go deleted file mode 100644 index 189e82f4b78..00000000000 --- a/bundle/deploy/terraform/tfdyn/spec_fields.go +++ /dev/null @@ -1,31 +0,0 @@ -package tfdyn - -import ( - "reflect" - - "github.com/databricks/cli/libs/structs/structpath" - "github.com/databricks/cli/libs/structs/structwalk" -) - -// specFieldNames returns the JSON field names from a struct type's top-level fields. -// It is used by postgres resource converters to dynamically determine which fields -// belong in the "spec" block when converting bundle config to Terraform config. -// Using reflection ensures new fields added to the Terraform schema are automatically -// included without manual updates to the converters. -func specFieldNames(v any) []string { - var names []string - _ = structwalk.WalkType(reflect.TypeOf(v), func(path *structpath.PatternNode, typ reflect.Type, field *reflect.StructField) bool { - // Skip root node (path is nil) - if path == nil { - return true - } - // Collect top-level field names only (depth 1) - if path.Parent() == nil { - if key, ok := path.StringKey(); ok { - names = append(names, key) - } - } - return false - }) - return names -} diff --git a/bundle/deploy/terraform/unbind.go b/bundle/deploy/terraform/unbind.go deleted file mode 100644 index 25cc8271921..00000000000 --- a/bundle/deploy/terraform/unbind.go +++ /dev/null @@ -1,59 +0,0 @@ -package terraform - -import ( - "context" - "fmt" - - "github.com/databricks/cli/bundle" - "github.com/databricks/cli/libs/diag" -) - -type unbind struct { - bundleType string - tfResourceType string - resourceKey string -} - -func (m *unbind) Apply(ctx context.Context, b *bundle.Bundle) diag.Diagnostics { - diags := Initialize(ctx, b) - if diags.HasError() { - return diags - } - tf := b.Terraform - - err := tf.StateRm(ctx, fmt.Sprintf("%s.%s", m.tfResourceType, m.resourceKey)) - if err != nil { - return diag.Errorf("terraform state rm: %v", err) - } - - // Also remove the permission if it exists - // First check terraform state list to see if the permission exists - state, err := tf.Show(ctx) - if err != nil { - return diag.Errorf("terraform show: %v", err) - } - - if state.Values == nil || state.Values.RootModule == nil || state.Values.RootModule.Resources == nil { - return nil - } - - for _, resource := range state.Values.RootModule.Resources { - if resource.Address == fmt.Sprintf("databricks_permissions.%s_%s", m.bundleType, m.resourceKey) || - resource.Address == fmt.Sprintf("databricks_grants.%s_%s", m.bundleType, m.resourceKey) { - err = tf.StateRm(ctx, resource.Address) - if err != nil { - return diag.Errorf("terraform state rm: %v", err) - } - } - } - - return nil -} - -func (*unbind) Name() string { - return "terraform.Unbind" -} - -func Unbind(bundleType, tfResourceType, resourceKey string) bundle.Mutator { - return &unbind{bundleType: bundleType, tfResourceType: tfResourceType, resourceKey: resourceKey} -} diff --git a/bundle/deploy/terraform/write.go b/bundle/deploy/terraform/write.go deleted file mode 100644 index 3a87d1baabe..00000000000 --- a/bundle/deploy/terraform/write.go +++ /dev/null @@ -1,57 +0,0 @@ -package terraform - -import ( - "context" - "encoding/json" - "os" - "path/filepath" - - "github.com/databricks/cli/bundle" - "github.com/databricks/cli/bundle/internal/tf/schema" - "github.com/databricks/cli/libs/diag" - "github.com/databricks/cli/libs/dyn" -) - -type write struct{} - -func (w *write) Name() string { - return "terraform.Write" -} - -func (w *write) Apply(ctx context.Context, b *bundle.Bundle) diag.Diagnostics { - dir, err := Dir(ctx, b) - if err != nil { - return diag.FromErr(err) - } - - var root *schema.Root - err = b.Config.Mutate(func(v dyn.Value) (dyn.Value, error) { - root, err = BundleToTerraformWithDynValue(ctx, v, b.MigratingToDirect) - return v, err - }) - if err != nil { - return diag.FromErr(err) - } - - f, err := os.Create(filepath.Join(dir, TerraformConfigFileName)) - if err != nil { - return diag.FromErr(err) - } - - defer f.Close() - - enc := json.NewEncoder(f) - enc.SetIndent("", " ") - err = enc.Encode(root) - if err != nil { - return diag.FromErr(err) - } - - return nil -} - -// Write returns a [bundle.Mutator] that converts resources in a bundle configuration -// to the equivalent Terraform JSON representation and writes the result to a file. -func Write() bundle.Mutator { - return &write{} -} diff --git a/bundle/deployplan/plan.go b/bundle/deployplan/plan.go index 87654c7d69b..5192141a498 100644 --- a/bundle/deployplan/plan.go +++ b/bundle/deployplan/plan.go @@ -86,15 +86,6 @@ func NewPlanDirect() *Plan { } } -// NewPlanTerraform creates a new Plan for terraform engine without plan_version. -func NewPlanTerraform() *Plan { - return &Plan{ - CLIVersion: build.GetInfo().Version, - Plan: make(map[string]*PlanEntry), - lockmap: newLockmap(), - } -} - // LoadPlanFromFile reads a plan from a JSON file. func LoadPlanFromFile(path string) (*Plan, error) { file, err := os.Open(path) diff --git a/bundle/internal/schema/annotations.yml b/bundle/internal/schema/annotations.yml index e275e928478..4a9d0193b12 100644 --- a/bundle/internal/schema/annotations.yml +++ b/bundle/internal/schema/annotations.yml @@ -120,18 +120,14 @@ bundle: Whether to force this lock if it is enabled. "engine": "description": |- - The deployment engine to use. Valid values are `terraform` and `direct`. Takes priority over `DATABRICKS_BUNDLE_ENGINE` environment variable. Default is "direct". + The deployment engine to use. Only `direct` is supported; the Terraform engine was removed in v1.19.0. Takes priority over `DATABRICKS_BUNDLE_ENGINE` environment variable. Default is "direct". "$type": "enum": - - |- - terraform - |- direct "x-databricks-enum-descriptions": "direct": |- Deploy by calling the Databricks APIs directly. This is the default. - "terraform": |- - Deploy through Terraform. Deprecated: Migrate to `direct`, see https://docs.databricks.com/aws/en/dev-tools/bundles/direct "git": "description": |- The Git version control details that are associated with your bundle. diff --git a/bundle/phases/bind.go b/bundle/phases/bind.go index 4f3d2b6c776..655fb36aaf3 100644 --- a/bundle/phases/bind.go +++ b/bundle/phases/bind.go @@ -33,14 +33,18 @@ func Bind(ctx context.Context, b *bundle.Bundle, opts *terraform.BindOptions, st bundle.ApplyContext(ctx, b, lock.Release(lock.GoalBind)) }() - if engine.IsDirect() { + if !engine.IsDirect() { + logdiag.LogError(ctx, errors.New(TerraformStateRemovedMessage)) + return + } + + { if stateDesc.IsDMS() { 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 - // This follows the same pattern as terraform import groupName, ok := terraform.TerraformToGroupName[opts.ResourceType] if !ok { groupName = opts.ResourceType @@ -98,17 +102,6 @@ func Bind(ctx context.Context, b *bundle.Bundle, opts *terraform.BindOptions, st logdiag.LogError(ctx, err) return } - } else { - // Terraform engine: use terraform import - bundle.ApplySeqContext( - ctx, b, - terraform.Interpolate(), - terraform.Write(), - terraform.Import(opts), - ) - if logdiag.HasError(ctx) { - return - } } statemgmt.PushResourcesState(ctx, b, engine) @@ -135,28 +128,21 @@ func Unbind(ctx context.Context, b *bundle.Bundle, bundleType, tfResourceType, r bundle.ApplyContext(ctx, b, lock.Release(lock.GoalUnbind)) }() - if engine.IsDirect() { - groupName, ok := terraform.TerraformToGroupName[tfResourceType] - if !ok { - groupName = tfResourceType - } - fullResourceKey := fmt.Sprintf("resources.%s.%s", groupName, resourceKey) - _, statePath := b.StateFilenameDirect(ctx) - err := b.DeploymentBundle.Unbind(ctx, statePath, fullResourceKey) - if err != nil { - logdiag.LogError(ctx, err) - return - } - } else { - bundle.ApplySeqContext( - ctx, b, - terraform.Interpolate(), - terraform.Write(), - terraform.Unbind(bundleType, tfResourceType, resourceKey), - ) - if logdiag.HasError(ctx) { - return - } + if !engine.IsDirect() { + logdiag.LogError(ctx, errors.New(TerraformStateRemovedMessage)) + return + } + + groupName, ok := terraform.TerraformToGroupName[tfResourceType] + if !ok { + groupName = tfResourceType + } + fullResourceKey := fmt.Sprintf("resources.%s.%s", groupName, resourceKey) + _, statePath := b.StateFilenameDirect(ctx) + err := b.DeploymentBundle.Unbind(ctx, statePath, fullResourceKey) + if err != nil { + logdiag.LogError(ctx, err) + return } statemgmt.PushResourcesState(ctx, b, engine) diff --git a/bundle/phases/deploy.go b/bundle/phases/deploy.go index 8a8ef56be25..445ddba77a6 100644 --- a/bundle/phases/deploy.go +++ b/bundle/phases/deploy.go @@ -15,7 +15,6 @@ import ( "github.com/databricks/cli/bundle/deploy/lock" "github.com/databricks/cli/bundle/deploy/metadata" "github.com/databricks/cli/bundle/deploy/snapshot" - "github.com/databricks/cli/bundle/deploy/terraform" "github.com/databricks/cli/bundle/deployplan" "github.com/databricks/cli/bundle/libraries" "github.com/databricks/cli/bundle/metrics" @@ -86,17 +85,12 @@ func deployCore(ctx context.Context, b *bundle.Bundle, plan *deployplan.Plan, st state statemgmt.ExportedResourcesMap err error ) - if stateEngine.IsDirect() { - b.DeploymentBundle.Apply(ctx, b.WorkspaceClient(ctx), plan, reportPerResource(b)) - state, err = b.DeploymentBundle.StateDB.Finalize(ctx) - // Capture the finalized state for deploy telemetry. It carries each - // resource's state-size in bytes (from the WAL replay Finalize just - // did), so telemetry needs no extra read or parse of the state file. - b.Metrics.ResourceState = state - } else { - bundle.ApplyContext(ctx, b, terraform.Apply()) - state, err = terraform.ParseResourcesState(ctx, b) - } + b.DeploymentBundle.Apply(ctx, b.WorkspaceClient(ctx), plan, reportPerResource(b)) + state, err = b.DeploymentBundle.StateDB.Finalize(ctx) + // Capture the finalized state for deploy telemetry. It carries each + // resource's state-size in bytes (from the WAL replay Finalize just + // did), so telemetry needs no extra read or parse of the state file. + b.Metrics.ResourceState = state if err != nil { logdiag.LogError(ctx, err) } @@ -381,76 +375,22 @@ func Deploy(ctx context.Context, b *bundle.Bundle, outputHandler sync.OutputHand logDeploySummary(ctx, b, plan, stateEngine) bundle.ApplyContext(ctx, b, scripts.Execute(config.ScriptPostDeploy)) - - // Migrate the state to the direct engine, if the user opted in (via - // bundle.engine or DATABRICKS_BUNDLE_ENGINE) and a dry-run of the migration - // comes back clean. Without the opt-in, or when the dry-run reports problems, - // nothing is written: only the outcome is recorded in telemetry, and the - // deploy is unaffected. - // - // Last, after the deploy has reported what it did: this is post-deploy work, - // and its warnings read as belonging to the deploy if they precede the - // summary. - // - // Gated on the deploy alone, which the early return above already guarantees - // — not on the postdeploy script. The resources were applied before that - // script ran, so the state is worth migrating even if it failed, the same - // reasoning that prints the summary ahead of it. - if !stateEngine.IsDirect() { - statemgmt.MigrateToDirect(ctx, b, requestedEngine) - } } func RunPlan(ctx context.Context, b *bundle.Bundle, engine engine.EngineType) *deployplan.Plan { - if engine.IsDirect() { - plan, err := b.DeploymentBundle.CalculatePlan(ctx, b.WorkspaceClient(ctx), &b.Config) - if err != nil { - logdiag.LogError(ctx, err) - return nil - } - if len(b.Select) > 0 { - plan.FilterToSelected(b.Select) - } - return plan - } - - // b.Select is rejected for the terraform engine in ProcessBundleRet, so it is - // never set here. - - bundle.ApplySeqContext( - ctx, b, - terraform.Interpolate(), - terraform.Write(), - terraform.Plan(terraform.PlanGoal("deploy")), - ) - - if logdiag.HasError(ctx) { - return nil - } - - tf := b.Terraform - if tf == nil { - logdiag.LogError(ctx, errors.New("terraform not initialized")) + if !engine.IsDirect() { + logdiag.LogError(ctx, errors.New(TerraformStateRemovedMessage)) return nil } - plan, err := terraform.ShowPlanFile(ctx, tf, b.TerraformPlanPath) + plan, err := b.DeploymentBundle.CalculatePlan(ctx, b.WorkspaceClient(ctx), &b.Config) if err != nil { logdiag.LogError(ctx, err) return nil } - - for _, group := range b.Config.Resources.AllResources() { - for rKey := range group.Resources { - resourceKey := "resources." + group.Description.PluralName + "." + rKey - if _, ok := plan.Plan[resourceKey]; !ok { - plan.Plan[resourceKey] = &deployplan.PlanEntry{ - Action: deployplan.Skip, - } - } - } + if len(b.Select) > 0 { + plan.FilterToSelected(b.Select) } - return plan } diff --git a/bundle/phases/destroy.go b/bundle/phases/destroy.go index 5cb2d615b58..4445be6a7f7 100644 --- a/bundle/phases/destroy.go +++ b/bundle/phases/destroy.go @@ -12,10 +12,8 @@ import ( "github.com/databricks/cli/bundle" "github.com/databricks/cli/bundle/config/engine" - "github.com/databricks/cli/bundle/config/mutator" "github.com/databricks/cli/bundle/deploy/files" "github.com/databricks/cli/bundle/deploy/lock" - "github.com/databricks/cli/bundle/deploy/terraform" "github.com/databricks/cli/bundle/deployplan" "github.com/databricks/cli/libs/cmdio" "github.com/databricks/cli/libs/diag" @@ -141,24 +139,17 @@ func approvalForDestroy(ctx context.Context, b *bundle.Bundle, plan *deployplan. } func destroyCore(ctx context.Context, b *bundle.Bundle, plan *deployplan.Plan, engine engine.EngineType) { - if engine.IsDirect() { - // Not reported per resource: destroy names them up front for consent and then - // reports only a count, so there is no per-resource output to report into. - b.DeploymentBundle.Apply(ctx, b.WorkspaceClient(ctx), plan, false) - } else { - // Core destructive mutators for destroy. These require informed user consent. - bundle.ApplyContext(ctx, b, terraform.Apply()) - } + // Not reported per resource: destroy names them up front for consent and then + // reports only a count, so there is no per-resource output to report into. + b.DeploymentBundle.Apply(ctx, b.WorkspaceClient(ctx), plan, false) // Flush WAL to local state file before deleting remote files. // Warn instead of hard-error: resources are already deleted, so proceed // with file cleanup regardless of whether state flush succeeds. - if engine.IsDirect() { - if _, err := b.DeploymentBundle.StateDB.Finalize(ctx); err != nil { - diags := diag.WarningFromErr(err) - if len(diags) > 0 { - logdiag.LogDiag(ctx, diags[0]) - } + if _, err := b.DeploymentBundle.StateDB.Finalize(ctx); err != nil { + diags := diag.WarningFromErr(err) + if len(diags) > 0 { + logdiag.LogDiag(ctx, diags[0]) } } @@ -166,7 +157,7 @@ func destroyCore(ctx context.Context, b *bundle.Bundle, plan *deployplan.Plan, e return } - if engine.IsDirect() && b.DeploymentBundle.StateDB.IsDeploymentMetadataService() { + if b.DeploymentBundle.StateDB.IsDeploymentMetadataService() { // Complete version before deleting remote files; the deployment node is under statePath. completed, err := b.DeploymentBundle.StateDB.CompleteVersion(ctx, true) if err != nil { @@ -214,12 +205,7 @@ func destroyCore(ctx context.Context, b *bundle.Bundle, plan *deployplan.Plan, e // mismatch. Destroy runs on a single engine, so remove only that engine's // state file. Log a removal failure but keep going; the destroy already // succeeded and its summary is printed above. - var localStatePath string - if engine.IsDirect() { - _, localStatePath = b.StateFilenameDirect(ctx) - } else { - _, localStatePath = b.StateFilenameTerraform(ctx) - } + _, localStatePath := b.StateFilenameDirect(ctx) if err := os.Remove(localStatePath); err != nil && !errors.Is(err, fs.ErrNotExist) { logdiag.LogError(ctx, err) } @@ -282,6 +268,11 @@ func removeEmptyDirs(dir string, depth int) (bool, error) { func Destroy(ctx context.Context, b *bundle.Bundle, engine engine.EngineType) { log.Info(ctx, "Phase: destroy") + if !engine.IsDirect() { + logdiag.LogError(ctx, errors.New(TerraformStateRemovedMessage)) + return + } + ok, err := assertRootPathExists(ctx, b) if err != nil { logdiag.LogError(ctx, err) @@ -316,46 +307,12 @@ func Destroy(ctx context.Context, b *bundle.Bundle, engine engine.EngineType) { bundle.ApplyContext(ctx, b, lock.Release(lock.GoalDestroy)) }() - if !engine.IsDirect() { - bundle.ApplySeqContext( - ctx, b, - // We need to resolve artifact variable (how we do it in build phase) - // because some of the to-be-destroyed resource might use this variable. - // Not resolving might lead to terraform "Reference to undeclared resource" error - mutator.ResolveVariableReferencesWithoutResources("artifacts"), - mutator.ResolveVariableReferencesOnlyResources("artifacts"), - - terraform.Interpolate(), - terraform.Write(), - terraform.Plan(terraform.PlanGoal("destroy")), - ) - } - - if logdiag.HasError(ctx) { + plan, err := b.DeploymentBundle.CalculatePlan(ctx, b.WorkspaceClient(ctx), nil) + if err != nil { + logdiag.LogError(ctx, err) return } - var plan *deployplan.Plan - if engine.IsDirect() { - plan, err = b.DeploymentBundle.CalculatePlan(ctx, b.WorkspaceClient(ctx), nil) - if err != nil { - logdiag.LogError(ctx, err) - return - } - } else { - tf := b.Terraform - if tf == nil { - logdiag.LogError(ctx, errors.New("terraform not initialized")) - return - } - - plan, err = terraform.ShowPlanFile(ctx, tf, b.TerraformPlanPath) - if err != nil { - logdiag.LogError(ctx, err) - return - } - } - hasApproval, err := approvalForDestroy(ctx, b, plan, engine) if err != nil { logdiag.LogError(ctx, err) diff --git a/bundle/phases/messages.go b/bundle/phases/messages.go index 388c0faa067..9653343da3e 100644 --- a/bundle/phases/messages.go +++ b/bundle/phases/messages.go @@ -1,5 +1,13 @@ package phases +// TerraformStateRemovedMessage is the error text shown when a bundle operation +// (deploy, plan, destroy, bind, unbind) finds an existing Terraform state file. +// The Terraform deployment engine was removed in v1.19.0; automatic in-place +// migration is reintroduced separately. +const TerraformStateRemovedMessage = `this deployment's state uses the Terraform engine, which has been removed in Databricks CLI v1.19.0 + +Run "databricks bundle deployment migrate" to convert the state to the direct engine, or downgrade to CLI v1.18.x` + // Messages for bundle deploy. const ( deleteOrRecreateSchemaMessage = ` diff --git a/bundle/schema/jsonschema.json b/bundle/schema/jsonschema.json index cfa257d0ed8..0bb91f71ab1 100644 --- a/bundle/schema/jsonschema.json +++ b/bundle/schema/jsonschema.json @@ -64,11 +64,9 @@ { "type": "string", "enum": [ - "terraform", "direct" ], "enumDescriptions": [ - "Deploy through Terraform. Deprecated: Migrate to `direct`, see https://docs.databricks.com/aws/en/dev-tools/bundles/direct", "Deploy by calling the Databricks APIs directly. This is the default." ] }, @@ -3726,7 +3724,7 @@ "markdownDescription": "The definition of the bundle deployment. For supported attributes see [link](https://docs.databricks.com/dev-tools/bundles/deployment-modes.html)." }, "engine": { - "description": "The deployment engine to use. Valid values are `terraform` and `direct`. Takes priority over `DATABRICKS_BUNDLE_ENGINE` environment variable. Default is \"direct\".", + "description": "The deployment engine to use. Only `direct` is supported; the Terraform engine was removed in v1.19.0. Takes priority over `DATABRICKS_BUNDLE_ENGINE` environment variable. Default is \"direct\".", "$ref": "#/$defs/github.com/databricks/cli/bundle/config/engine.EngineType" }, "git": { diff --git a/bundle/statemgmt/direct_migration.go b/bundle/statemgmt/direct_migration.go index cab2e5cc115..7aaf696a530 100644 --- a/bundle/statemgmt/direct_migration.go +++ b/bundle/statemgmt/direct_migration.go @@ -41,6 +41,55 @@ Please forward these warnings to dabs-feedback@databricks.com` // migration is skipped. const autoMigrateStoppedNotice = `Direct engine was selected but the migration reported issues; automatic migration to the direct deployment engine is stopped. Address the issues above or run "databricks bundle deployment migrate" manually.` +// OpenMigratedTerraformState converts the bundle's terraform state to a direct-engine +// state in memory and opens b.DeploymentBundle.StateDB with it, pointed at the +// resources.json path in read mode. Nothing is written to disk: the deploy's normal +// Finalize persists resources.json only if the WAL records changes, and +// BackupTerraformState is called afterwards only when it does. Returns false when there +// is no terraform state to migrate (the caller then opens the direct state normally). +func OpenMigratedTerraformState(ctx context.Context, b *bundle.Bundle) (bool, error) { + _, localTerraformPath := b.StateFilenameTerraform(ctx) + tfState, err := migrate.ParseTFStateFull(ctx, localTerraformPath) + if err != nil { + return false, fmt.Errorf("parsing terraform state: %w", err) + } + if tfState == nil { + return false, nil + } + + _, localDirectPath := b.StateFilenameDirect(ctx) + + // A terraform state with no managed resources carries nothing to migrate; seed an + // empty direct database at the incremented serial so the deploy runs on direct. + if len(tfState.IDs) == 0 && len(tfState.Attrs) == 0 { + b.DeploymentBundle.StateDB.OpenWithData(localDirectPath, dstate.NewDatabase(tfState.Lineage, tfState.Serial+1)) + return true, nil + } + + tempStatePath, _, _, _, err := convertTFStateToDirect(ctx, b, tfState) + if tempStatePath != "" { + defer os.Remove(tempStatePath) + defer os.Remove(tempStatePath + ".wal") + } + if err != nil { + return false, err + } + + // Load the converted state file into memory. It was just written by this CLI, so it + // is at the current schema version and needs no migration. + raw, err := os.ReadFile(tempStatePath) + if err != nil { + return false, fmt.Errorf("reading migrated state: %w", err) + } + var data dstate.Database + if err := json.Unmarshal(raw, &data); err != nil { + return false, fmt.Errorf("parsing migrated state: %w", err) + } + + b.DeploymentBundle.StateDB.OpenWithData(localDirectPath, data) + return true, nil +} + // MigrateToDirect performs a dry-run migration of the just-deployed terraform // state to the direct engine and records the outcome in deploy telemetry. // @@ -51,6 +100,8 @@ const autoMigrateStoppedNotice = `Direct engine was selected but the migration r // backed up, and the new state is pushed to the workspace). Otherwise the temp // state is deleted and only telemetry is recorded. Any failure is surfaced as a // warning so it never fails a deploy that already succeeded. +// +//deadcode:allow reused by the pre-deploy terraform-state migration (wired in a follow-up commit on this PR) func MigrateToDirect(ctx context.Context, b *bundle.Bundle, requestedEngine engine.EngineSetting) { _, localTerraformPath := b.StateFilenameTerraform(ctx) tfState, err := migrate.ParseTFStateFull(ctx, localTerraformPath) @@ -83,7 +134,7 @@ func MigrateToDirect(ctx context.Context, b *bundle.Bundle, requestedEngine engi return } cmdio.LogString(ctx, "Removing empty terraform state; direct engine will be used on the next deploy (selected via "+requestedEngine.Source+")...") - if err := backupTerraformState(ctx, b); err != nil { + if err := BackupTerraformState(ctx, b); err != nil { b.Metrics.SetBoolValue(metrics.DirectMigrateCommitError, true) log.Warnf(ctx, "automatic migration to direct engine failed: %v", err) return @@ -158,6 +209,8 @@ func MigrateToDirect(ctx context.Context, b *bundle.Bundle, requestedEngine engi // Individual planning errors are emitted as warnings with warnPrefix so they // are visible without failing the deploy. The plan is run in an isolated // context so its diagnostics do not affect the deploy's own error state. +// +//deadcode:allow reused by the pre-deploy terraform-state migration (wired in a follow-up commit on this PR) func checkPlanOnTempState(ctx context.Context, b *bundle.Bundle, tempStatePath string, cfg *config.Root) error { planCtx := logdiag.IsolatedContext(ctx) logdiag.SetCollect(planCtx, true) @@ -186,6 +239,8 @@ func checkPlanOnTempState(ctx context.Context, b *bundle.Bundle, tempStatePath s // recordDryRunNoop records dry-run telemetry for a no-op case (no state, or // state with no managed resources) when direct was NOT selected. On the // migrating paths the caller uses direct_migrate_* keys instead. +// +//deadcode:allow reused by the pre-deploy terraform-state migration (wired in a follow-up commit on this PR) func recordDryRunNoop(b *bundle.Bundle, requestedEngine engine.EngineSetting) { if requestedEngine.Type == engine.EngineDirect { return @@ -200,6 +255,8 @@ func recordDryRunNoop(b *bundle.Bundle, requestedEngine engine.EngineSetting) { // set only when the config populated the setting, so it's the correct signal for // "was this a durable opt-in?" — env-only opt-ins are the ones with // ConfigType == EngineNotSet and IsDefault false. +// +//deadcode:allow reused by the pre-deploy terraform-state migration (wired in a follow-up commit on this PR) func recordAutoMigrateSource(b *bundle.Bundle, requestedEngine engine.EngineSetting) { switch { case requestedEngine.IsDefault: @@ -211,7 +268,7 @@ func recordAutoMigrateSource(b *bundle.Bundle, requestedEngine engine.EngineSett } } -// backupTerraformState moves the terraform state to .backup both remotely +// BackupTerraformState moves the terraform state to .backup both remotely // (read → write .backup → delete) and locally (rename). Every step must // succeed, so callers get an accurate error path — a stale terraform state // left anywhere lets it win over remote direct in PullResourcesState when @@ -220,7 +277,9 @@ func recordAutoMigrateSource(b *bundle.Bundle, requestedEngine engine.EngineSett // Contrast with BackupRemoteTerraformState, which only handles the remote // half and swallows errors via log.Warnf for best-effort direct-engine // cleanup on unrelated code paths. -func backupTerraformState(ctx context.Context, b *bundle.Bundle) error { +// +//deadcode:allow reused by the pre-deploy terraform-state migration (wired in a follow-up commit on this PR) +func BackupTerraformState(ctx context.Context, b *bundle.Bundle) error { f, err := deploy.StateFiler(ctx, b) if err != nil { return err @@ -254,6 +313,8 @@ func backupTerraformState(ctx context.Context, b *bundle.Bundle) error { // one resource ID (the empty and nil cases are handled by MigrateToDirect // directly, since they take different commit paths). The caller is responsible // for deleting the temp state's parent directory when it is done with the file. +// +//deadcode:allow reused by the pre-deploy terraform-state migration (wired in a follow-up commit on this PR) func convertTFStateToDirect(ctx context.Context, b *bundle.Bundle, tfState *migrate.TFState) (string, int, bool, *config.Root, error) { // Write the converted state to a sibling of the final resources.json // path so commitMigration's os.Rename stays within one filesystem @@ -356,6 +417,8 @@ func convertTFStateToDirect(ctx context.Context, b *bundle.Bundle, tfState *migr // the remote terraform state. Remote push happens FIRST: if we swapped local // state and then failed to push, this machine would prefer direct state while // the workspace still has terraform state, so other machines would diverge. +// +//deadcode:allow reused by the pre-deploy terraform-state migration (wired in a follow-up commit on this PR) func commitMigration(ctx context.Context, b *bundle.Bundle, tempStatePath string, resourceCount int) error { _, localTerraformPath := b.StateFilenameTerraform(ctx) _, localDirectPath := b.StateFilenameDirect(ctx) @@ -407,6 +470,8 @@ func commitMigration(ctx context.Context, b *bundle.Bundle, tempStatePath string // direct state landed but the terraform state stayed, the workspace has two // authoritative files, and an older CLI (or `validateStates`) will refuse to // use them. Fail loudly so the caller can record telemetry and warn the user. +// +//deadcode:allow reused by the pre-deploy terraform-state migration (wired in a follow-up commit on this PR) func pushDirectState(ctx context.Context, b *bundle.Bundle, localPath string) error { f, err := deploy.StateFiler(ctx, b) if err != nil { diff --git a/cmd/bundle/utils/process.go b/cmd/bundle/utils/process.go index 379fc7c521d..5413d862e41 100644 --- a/cmd/bundle/utils/process.go +++ b/cmd/bundle/utils/process.go @@ -4,6 +4,7 @@ import ( "context" "errors" "fmt" + "os" "path" "path/filepath" "strconv" @@ -234,23 +235,23 @@ func ProcessBundleRet(cmd *cobra.Command, opts ProcessOptions) (b *bundle.Bundle // it even when the deploy fails or is cancelled before deployCore runs. b.Metrics.StateEngine = stateDesc.Engine.ThisOrDefault() - b.MigratingToDirect = requiredEngine.Type == engine.EngineDirect && !stateDesc.Engine.IsDirect() - - // Announce the auto-migration path here (only on deploy) so the user - // isn't surprised when MigrateToDirect commits state changes at the - // end. PullResourcesState is shared with non-deploy commands like - // `bundle debug states`, which would otherwise print the same hint - // even though they will not migrate. - if opts.Deploy && b.MigratingToDirect { - if requiredEngine.IsDefault { - // The user did not ask for direct; it is the default. Frame the - // auto-migration as an informational notice rather than a warning, - // and do not claim the user selected anything. - cmdio.LogString(ctx, "Notice: the direct deployment engine is the default as of CLI v1.14.0.\n\n"+ - "This bundle will be automatically migrated to use the direct deployment engine after this deployment.\n\n"+ - "Learn more: https://docs.databricks.com/dev-tools/bundles/direct\n") - } else { - log.Warnf(ctx, "Direct engine selected via %s but the existing state uses %q. Deploying on %q; will attempt to migrate the state to the direct engine after this deploy.", requiredEngine.Source, stateDesc.Engine, stateDesc.Engine) + // The Terraform deployment engine was removed in v1.19.0. When the existing + // state still uses Terraform, migrate it to the direct engine in memory before + // planning/deploying: the converted state is opened read-only, and the deploy's + // normal Finalize commits resources.json (and terraform.tfstate is backed up) + // only if the deploy records changes. Read-only commands such as "bundle debug + // states" set none of these options and keep reading the Terraform state as-is, + // and "bundle deployment migrate" reads it itself and is not routed here. + needsState := opts.InitIDs || opts.ErrorOnEmptyState || opts.Deploy || opts.ReadPlanPath != "" || opts.PreDeployChecks || opts.PostStateFunc != nil + if needsState && !stateDesc.Engine.IsDirect() { + migrated, err := statemgmt.OpenMigratedTerraformState(ctx, b) + if err != nil { + logdiag.LogError(ctx, fmt.Errorf("migrating Terraform state to the direct engine: %w", err)) + return b, stateDesc, root.ErrAlreadyPrinted + } + if migrated { + b.MigratingToDirect = true + stateDesc.Engine = engine.EngineDirect } } @@ -264,8 +265,9 @@ func ProcessBundleRet(cmd *cobra.Command, opts ProcessOptions) (b *bundle.Bundle } // Open direct engine state once for all subsequent operations (ExportState, CalculatePlan, Apply, etc.) + // A migrated-from-Terraform state is already open (seeded in memory above), so skip the disk open. needDirectState := stateDesc.Engine.IsDirect() && (opts.InitIDs || opts.ErrorOnEmptyState || opts.Deploy || opts.ReadPlanPath != "" || opts.PreDeployChecks || opts.PostStateFunc != nil) - if needDirectState { + if needDirectState && !b.DeploymentBundle.StateDB.IsOpen() { _, localPath := b.StateFilenameDirect(ctx) if stateDesc.IsDMS() { @@ -487,11 +489,25 @@ func ProcessBundleRet(cmd *cobra.Command, opts ProcessOptions) (b *bundle.Bundle return b, stateDesc, root.ErrAlreadyPrinted } - if b != nil && stateDesc != nil && stateDesc.Engine.IsDirect() && stateDesc.HasRemoteTerraformState() { - statemgmt.BackupRemoteTerraformState(ctx, b) - - if logdiag.HasError(ctx) { - return b, stateDesc, root.ErrAlreadyPrinted + if b != nil && stateDesc != nil && stateDesc.Engine.IsDirect() { + if b.MigratingToDirect { + // Migrated from Terraform in memory this deploy: resources.json exists only + // if Finalize committed a non-empty WAL (the deploy recorded changes). Back + // up terraform.tfstate (local + remote) in that case; when the WAL was empty + // nothing was committed, so leave the Terraform state intact and let the next + // deploy migrate again. + _, localDirectPath := b.StateFilenameDirect(ctx) + if _, err := os.Stat(localDirectPath); err == nil { + if err := statemgmt.BackupTerraformState(ctx, b); err != nil { + logdiag.LogError(ctx, err) + return b, stateDesc, root.ErrAlreadyPrinted + } + } + } else if stateDesc.HasRemoteTerraformState() { + statemgmt.BackupRemoteTerraformState(ctx, b) + if logdiag.HasError(ctx) { + return b, stateDesc, root.ErrAlreadyPrinted + } } } } @@ -511,19 +527,29 @@ func ResolveEngineSetting(ctx context.Context, b *bundle.Bundle) (engine.EngineS configEngine := b.Config.Bundle.Engine if configEngine != engine.EngineNotSet { + parsed, ok := engine.Parse(string(configEngine)) + if !ok { + return engine.EngineSetting{}, fmt.Errorf("invalid value %q for bundle.engine (expected %q)", configEngine, engine.EngineDirect) + } + if parsed == engine.EngineTerraform { + return engine.EngineSetting{}, errors.New(engine.TerraformRemovedMessage) + } source := "bundle.engine setting" v := dyn.GetValue(b.Config.Value(), "bundle.engine") if locs := v.Locations(); len(locs) > 0 { loc := locs[0] source = fmt.Sprintf("bundle.engine setting at %s:%d:%d", filepath.ToSlash(loc.File), loc.Line, loc.Column) } - return engine.EngineSetting{Type: configEngine, Source: source, ConfigType: configEngine}, nil + return engine.EngineSetting{Type: parsed, Source: source, ConfigType: parsed}, nil } envEngine, err := engine.FromEnv(ctx) if err != nil { return engine.EngineSetting{}, err } + if envEngine == engine.EngineTerraform { + return engine.EngineSetting{}, errors.New(engine.TerraformRemovedMessage) + } if envEngine != engine.EngineNotSet { return engine.EngineSetting{Type: envEngine, Source: engine.EnvVar + " environment variable"}, nil } diff --git a/go.mod b/go.mod index fa103cd5e6f..76ab022f329 100644 --- a/go.mod +++ b/go.mod @@ -18,8 +18,6 @@ require ( github.com/google/uuid v1.6.0 // BSD-3-Clause github.com/gorilla/websocket v1.5.3 // BSD-2-Clause github.com/hashicorp/go-version v1.9.0 // MPL-2.0 - github.com/hashicorp/hc-install v0.9.5 // MPL-2.0 - github.com/hashicorp/terraform-exec v0.25.3 // MPL-2.0 github.com/hashicorp/terraform-json v0.28.0 // MPL-2.0 github.com/hexops/gotextdiff v1.0.3 // BSD-3-Clause github.com/jackc/pgx/v5 v5.10.0 // MIT @@ -59,7 +57,6 @@ require ( cloud.google.com/go/auth v0.18.2 // indirect cloud.google.com/go/auth/oauth2adapt v0.2.8 // indirect cloud.google.com/go/compute/metadata v0.9.0 // indirect - github.com/ProtonMail/go-crypto v1.4.1 // indirect github.com/apparentlymart/go-textseg/v15 v15.0.0 // indirect github.com/atotto/clipboard v0.1.4 // indirect github.com/aymanbagabas/go-osc52/v2 v2.0.1 // indirect @@ -71,7 +68,6 @@ require ( github.com/charmbracelet/x/term v0.2.2 // indirect github.com/clipperhouse/displaywidth v0.11.0 // indirect github.com/clipperhouse/uax29/v2 v2.7.0 // indirect - github.com/cloudflare/circl v1.6.3 // indirect github.com/danieljoos/wincred v1.2.3 // indirect github.com/dustin/go-humanize v1.0.1 // indirect github.com/erikgeiser/coninput v0.0.0-20211004153227-1c3628e74d0f // indirect @@ -83,14 +79,11 @@ require ( github.com/google/s2a-go v0.1.9 // indirect github.com/googleapis/enterprise-certificate-proxy v0.3.11 // indirect github.com/googleapis/gax-go/v2 v2.17.0 // indirect - github.com/hashicorp/go-cleanhttp v0.5.2 // indirect - github.com/hashicorp/go-retryablehttp v0.7.8 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/jackc/pgpassfile v1.0.0 // indirect github.com/jackc/pgservicefile v0.0.0-20240606120523-5a60cdf6a761 // indirect github.com/klauspost/compress v1.19.2 // indirect github.com/lucasb-eyer/go-colorful v1.4.0 // indirect - github.com/mattn/go-colorable v0.1.14 // indirect github.com/mattn/go-localereader v0.0.1 // indirect github.com/mattn/go-runewidth v0.0.24 // indirect github.com/mitchellh/hashstructure/v2 v2.0.2 // indirect diff --git a/go.sum b/go.sum index 501f8ff2357..5ffaf465d83 100644 --- a/go.sum +++ b/go.sum @@ -12,10 +12,6 @@ github.com/MakeNowJust/heredoc v1.0.0 h1:cXCdzVdstXyiTqTvfqk9SDHpKNjxuom+DOlyEeQ github.com/MakeNowJust/heredoc v1.0.0/go.mod h1:mG5amYoWBHf8vpLOuehzbGGw0EHxpZZ6lCpQ4fNJ8LE= github.com/Masterminds/semver/v3 v3.5.0 h1:kQceYJfbupGfZOKZQg0kou0DgAKhzDg2NZPAwZ/2OOE= github.com/Masterminds/semver/v3 v3.5.0/go.mod h1:4V+yj/TJE1HU9XfppCwVMZq3I84lprf4nC11bSS5beM= -github.com/Microsoft/go-winio v0.6.2 h1:F2VQgta7ecxGYO8k3ZZz3RS8fVIXVxONVUPlNERoyfY= -github.com/Microsoft/go-winio v0.6.2/go.mod h1:yd8OoFMLzJbo9gZq8j5qaps8bJ9aShtEA8Ipt1oGCvU= -github.com/ProtonMail/go-crypto v1.4.1 h1:9RfcZHqEQUvP8RzecWEUafnZVtEvrBVL9BiF67IQOfM= -github.com/ProtonMail/go-crypto v1.4.1/go.mod h1:e1OaTyu5SYVrO9gKOEhTc+5UcXtTUa+P3uLudwcgPqo= github.com/apparentlymart/go-textseg/v15 v15.0.0 h1:uYvfpb3DyLSCGWnctWKGj857c6ew1u1fNQOlOtuGxQY= github.com/apparentlymart/go-textseg/v15 v15.0.0/go.mod h1:K8XmNZdhEBkdlyDdvbmmsvpAG721bKi0joRfFdHIWJ4= github.com/atotto/clipboard v0.1.4 h1:EH0zSVneZPSuFR11BlR9YppQTVDbh5+16AmcJi4g1z4= @@ -60,13 +56,9 @@ github.com/clipperhouse/displaywidth v0.11.0 h1:lBc6kY44VFw+TDx4I8opi/EtL9m20WSE github.com/clipperhouse/displaywidth v0.11.0/go.mod h1:bkrFNkf81G8HyVqmKGxsPufD3JhNl3dSqnGhOoSD/o0= github.com/clipperhouse/uax29/v2 v2.7.0 h1:+gs4oBZ2gPfVrKPthwbMzWZDaAFPGYK72F0NJv2v7Vk= github.com/clipperhouse/uax29/v2 v2.7.0/go.mod h1:EFJ2TJMRUaplDxHKj1qAEhCtQPW2tJSwu5BF98AuoVM= -github.com/cloudflare/circl v1.6.3 h1:9GPOhQGF9MCYUeXyMYlqTR6a5gTrgR/fBLXvUgtVcg8= -github.com/cloudflare/circl v1.6.3/go.mod h1:2eXP6Qfat4O/Yhh8BznvKnJ+uzEoTQ6jVKJRn81BiS4= github.com/cpuguy83/go-md2man/v2 v2.0.6/go.mod h1:oOW0eioCTA6cOiMLiUPZOpcVxMig6NIQQ7OS05n1F4g= github.com/creack/pty v1.1.24 h1:bJrF4RRfyJnbTJqzRLHzcGaZK1NeM5kTC9jGgovnR1s= github.com/creack/pty v1.1.24/go.mod h1:08sCNb52WyoAwi2QDyzUCTgcvVFhUzewun7wtTfvcwE= -github.com/cyphar/filepath-securejoin v0.6.1 h1:5CeZ1jPXEiYt3+Z6zqprSAgSWiggmpVyciv8syjIpVE= -github.com/cyphar/filepath-securejoin v0.6.1/go.mod h1:A8hd4EnAeyujCJRrICiOWqjS1AX0a9kM5XL+NwKoYSc= github.com/danieljoos/wincred v1.2.3 h1:v7dZC2x32Ut3nEfRH+vhoZGvN72+dQ/snVXo/vMFLdQ= github.com/danieljoos/wincred v1.2.3/go.mod h1:6qqX0WNrS4RzPZ1tnroDzq9kY3fu1KwE7MRLQK4X0bs= github.com/databricks/databricks-sdk-go v0.178.0 h1:OLHhYYTGCZ4iAEUYoARPeeCYFIvAmpLT+L4sxRayqIc= @@ -84,20 +76,10 @@ github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/dustin/go-humanize v1.0.1 h1:GzkhY7T5VNhEkwH0PVJgjz+fX1rhBrR7pRT3mDkpeCY= github.com/dustin/go-humanize v1.0.1/go.mod h1:Mu1zIs6XwVuF/gI1OepvI0qD18qycQx+mFykh5fBlto= -github.com/emirpasic/gods v1.18.1 h1:FXtiHYKDGKCW2KzwZKx0iC0PQmdlorYgdFG9jPXJ1Bc= -github.com/emirpasic/gods v1.18.1/go.mod h1:8tpGGwCnJ5H4r6BWwaV6OrWmMoPhUl5jm/FMNAnJvWQ= github.com/erikgeiser/coninput v0.0.0-20211004153227-1c3628e74d0f h1:Y/CXytFA4m6baUTXGLOoWe4PQhGxaX0KpnayAqC48p4= github.com/erikgeiser/coninput v0.0.0-20211004153227-1c3628e74d0f/go.mod h1:vw97MGsxSvLiUE2X8qFplwetxpGLQrlU1Q9AUEIzCaM= -github.com/fatih/color v1.16.0 h1:zmkK9Ngbjj+K0yRhTVONQh1p/HknKYSlNT+vZCzyokM= -github.com/fatih/color v1.16.0/go.mod h1:fL2Sau1YI5c0pdGEVCbKQbLXB6edEj1ZgiY4NijnWvE= github.com/felixge/httpsnoop v1.0.4 h1:NFTV2Zj1bL4mc9sqWACXbQFVBBg2W3GPvqp8/ESS2Wg= github.com/felixge/httpsnoop v1.0.4/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= -github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376 h1:+zs/tPmkDkHx3U66DAb0lQFJrpS6731Oaa12ikc+DiI= -github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376/go.mod h1:an3vInlBmSxCcxctByoQdvwPiA7DTK7jaaFDBTtu0ic= -github.com/go-git/go-billy/v5 v5.9.0 h1:jItGXszUDRtR/AlferWPTMN4j38BQ88XnXKbilmmBPA= -github.com/go-git/go-billy/v5 v5.9.0/go.mod h1:jCnQMLj9eUgGU7+ludSTYoZL/GGmii14RxKFj7ROgHw= -github.com/go-git/go-git/v5 v5.19.2 h1:wkfn7vOlUBu8ivAWKBWisTiwJK4jYHzTF8Ndv1LyGqY= -github.com/go-git/go-git/v5 v5.19.2/go.mod h1:QqCBE1EFN5ddFmrliLQ3/ntRCUjZU3EJuwuB/jWEHjk= github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= github.com/go-logr/logr v1.4.3 h1:CjnDlHq8ikf6E492q6eKboGOC0T8CDaOvkHCIg8idEI= github.com/go-logr/logr v1.4.3/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= @@ -105,8 +87,6 @@ github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= github.com/godbus/dbus/v5 v5.2.2 h1:TUR3TgtSVDmjiXOgAAyaZbYmIeP3DPkld3jgKGV8mXQ= github.com/godbus/dbus/v5 v5.2.2/go.mod h1:3AAv2+hPq5rdnr5txxxRwiGjPXamgoIHgz9FPBfOp3c= -github.com/golang/groupcache v0.0.0-20241129210726-2c02b8208cf8 h1:f+oWsMOmNPc8JmEHVZIycC7hBoQxHH9pNKQORJNozsQ= -github.com/golang/groupcache v0.0.0-20241129210726-2c02b8208cf8/go.mod h1:wcDNUvekVysuuOpQKo3191zZyTpiI6se1N1ULghS0sw= github.com/golang/protobuf v1.5.4 h1:i7eJL8qZTpSEXOPTxNKhASYpMn+8e5Q6AdndVa1dWek= github.com/golang/protobuf v1.5.4/go.mod h1:lnTiLA8Wa4RWRcIUkrtSVa5nRhsEGBg48fD6rSs7xps= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= @@ -126,18 +106,8 @@ github.com/googleapis/gax-go/v2 v2.17.0 h1:RksgfBpxqff0EZkDWYuz9q/uWsTVz+kf43LsZ github.com/googleapis/gax-go/v2 v2.17.0/go.mod h1:mzaqghpQp4JDh3HvADwrat+6M3MOIDp5YKHhb9PAgDY= github.com/gorilla/websocket v1.5.3 h1:saDtZ6Pbx/0u+bgYQ3q96pZgCzfhKXGPqt7kZ72aNNg= github.com/gorilla/websocket v1.5.3/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= -github.com/hashicorp/go-cleanhttp v0.5.2 h1:035FKYIWjmULyFRBKPs8TBQoi0x6d9G4xc9neXJWAZQ= -github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48= -github.com/hashicorp/go-hclog v1.6.3 h1:Qr2kF+eVWjTiYmU7Y31tYlP1h0q/X3Nl3tPGdaB11/k= -github.com/hashicorp/go-hclog v1.6.3/go.mod h1:W4Qnvbt70Wk/zYJryRzDRU/4r0kIg0PVHBcfoyhpF5M= -github.com/hashicorp/go-retryablehttp v0.7.8 h1:ylXZWnqa7Lhqpk0L1P1LzDtGcCR0rPVUrx/c8Unxc48= -github.com/hashicorp/go-retryablehttp v0.7.8/go.mod h1:rjiScheydd+CxvumBsIrFKlx3iS0jrZ7LvzFGFmuKbw= github.com/hashicorp/go-version v1.9.0 h1:CeOIz6k+LoN3qX9Z0tyQrPtiB1DFYRPfCIBtaXPSCnA= github.com/hashicorp/go-version v1.9.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= -github.com/hashicorp/hc-install v0.9.5 h1:XHCjcMn2563ysuaQ9v9ec2FNc7c2PJOIEEGobAFeIx4= -github.com/hashicorp/hc-install v0.9.5/go.mod h1:ihEW4LshrNkxq2bU/MpVbKyn+yt1is2hYqUTHDGhG84= -github.com/hashicorp/terraform-exec v0.25.3 h1:Xr9DBt2LX4deJnahlbhw7N25MFPDMxzj/VzE7cdFBoc= -github.com/hashicorp/terraform-exec v0.25.3/go.mod h1:NeE9+ss4hLaLuVlOIr+M6FK7Bqyy+JLZUHo5kQph+ME= github.com/hashicorp/terraform-json v0.28.0 h1:dOkJT55rWfU6T1/VklHde51ym4LfNP+9xYR3ZizAJe4= github.com/hashicorp/terraform-json v0.28.0/go.mod h1:PJIRf+Yzu5iLb52c/xYp1tUOL4jzMzfIAB5gvWWKIWE= github.com/hexops/gotextdiff v1.0.3 h1:gitA9+qJrrTCsiCl7+kh75nPqQt1cx4ZkudSTLoUqJM= @@ -152,14 +122,8 @@ github.com/jackc/pgx/v5 v5.10.0 h1:VhSvgU2jSli8o3AqIEOTJr7rZwAEUVo4E4XhR94Zfr0= github.com/jackc/pgx/v5 v5.10.0/go.mod h1:mal1tBGAFfLHvZzaYh77YS/eC6IX9OWbRV1QIIM0Jn4= github.com/jackc/puddle/v2 v2.2.2 h1:PR8nw+E/1w0GLuRFSmiioY6UooMp6KJv0/61nB7icHo= github.com/jackc/puddle/v2 v2.2.2/go.mod h1:vriiEXHvEE654aYKXXjOvZM39qJ0q+azkZFrfEOc3H4= -github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 h1:BQSFePA1RWJOlocH6Fxy8MmwDt+yVQYULKfN0RoTN8A= -github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99/go.mod h1:1lJo3i6rXxKeerYnT8Nvf0QmHCRC1n8sfWVwXF2Frvo= -github.com/kevinburke/ssh_config v1.2.0 h1:x584FjTGwHzMwvHx18PXxbBVzfnxogHaAReU4gf13a4= -github.com/kevinburke/ssh_config v1.2.0/go.mod h1:CT57kijsi8u/K/BOFA39wgDQJ9CxiF4nAY/ojJ6r6mM= github.com/klauspost/compress v1.19.2 h1:hMRETovs/pu/dVWN7zIT1PGG8t509MwT6bO7XSi26R8= github.com/klauspost/compress v1.19.2/go.mod h1:cwPg85FWrGar70rWktvGQj8/hthj3wpl0PGDogxkrSQ= -github.com/klauspost/cpuid/v2 v2.3.0 h1:S4CRMLnYUhGeDFDqkGriYKdfoFlDnMtqTiI/sFzhA9Y= -github.com/klauspost/cpuid/v2 v2.3.0/go.mod h1:hqwkgyIinND0mEev00jJYCxPNVRVXFQeu1XKlok6oO0= github.com/klauspost/pgzip v1.2.6 h1:8RXeL5crjEUFnR2/Sn6GJNWtSQ3Dk8pq4CL3jvdDyjU= github.com/klauspost/pgzip v1.2.6/go.mod h1:Ch1tH69qFZu15pkjo5kYi6mth2Zzwzt50oCQKQE9RUs= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= @@ -168,8 +132,6 @@ github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= github.com/lucasb-eyer/go-colorful v1.4.0 h1:UtrWVfLdarDgc44HcS7pYloGHJUjHV/4FwW4TvVgFr4= github.com/lucasb-eyer/go-colorful v1.4.0/go.mod h1:R4dSotOR9KMtayYi1e77YzuveK+i7ruzyGqttikkLy0= -github.com/mattn/go-colorable v0.1.14 h1:9A9LHSqF/7dyVVX6g0U9cwm9pG3kP9gSzcuIPHPsaIE= -github.com/mattn/go-colorable v0.1.14/go.mod h1:6LmQG8QLFO4G5z1gPvYEzlUgJ2wF+stgPZH1UqBm1s8= github.com/mattn/go-isatty v0.0.24 h1:tGZZoVgT/KiqK1c8ocVLeDS8BSWMRd47J3Lbz7vsReI= github.com/mattn/go-isatty v0.0.24/go.mod h1:nMCL3Zebbrt45jsMDgnfIwz6ydEQApk5oEI3HqDio6A= github.com/mattn/go-localereader v0.0.1 h1:ygSAOl7ZXTx4RdPYinUpg6W99U8jWvWi9Ye2JC/oIi4= @@ -186,8 +148,6 @@ github.com/muesli/termenv v0.16.0 h1:S5AlUN9dENB57rsbnkPyfdGuWIlkmzJjbFf0Tf5FWUc github.com/muesli/termenv v0.16.0/go.mod h1:ZRfOIKPFDYQoDFF4Olj7/QJbW60Ol/kL1pU3VfY/Cnk= github.com/palantir/pkg/yamlpatch v1.5.0 h1:186RUlcHFVf64onUhaI7nUCPzPIaRTQ5HJlKuv0d6NM= github.com/palantir/pkg/yamlpatch v1.5.0/go.mod h1:45cYAIiv9E0MiZnHjIIT2hGqi6Wah/DL6J1omJf2ny0= -github.com/pjbgf/sha1cd v0.6.0 h1:3WJ8Wz8gvDz29quX1OcEmkAlUg9diU4GxJHqs0/XiwU= -github.com/pjbgf/sha1cd v0.6.0/go.mod h1:lhpGlyHLpQZoxMv8HcgXvZEhcGs0PG/vsZnEJ7H0iCM= github.com/pkg/browser v0.0.0-20240102092130-5ac0b6a4141c h1:+mdjkGKdHQG3305AYmdv1U2eRNDiU2ErMBj1gwrq8eQ= github.com/pkg/browser v0.0.0-20240102092130-5ac0b6a4141c/go.mod h1:7rwL4CYBLnjLxUqIJNnCWiEdr3bn6IUYi15bNlnbCCU= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= @@ -202,10 +162,6 @@ github.com/rogpeppe/go-internal v1.14.1/go.mod h1:MaRKkUm5W0goXpeCfT7UZI6fk/L7L7 github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/sabhiram/go-gitignore v0.0.0-20210923224102-525f6e181f06 h1:OkMGxebDjyw0ULyrTYWeN0UNCCkmCWfjPnIA2W6oviI= github.com/sabhiram/go-gitignore v0.0.0-20210923224102-525f6e181f06/go.mod h1:+ePHsJ1keEjQtpvf9HHw0f4ZeJ0TLRsxhunSI2hYJSs= -github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3 h1:n661drycOFuPLCN3Uc8sB6B/s6Z4t2xvBgU1htSHuq8= -github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3/go.mod h1:A0bzQcvG0E7Rwjx0REVgAGH58e96+X0MeOfepqsbeW4= -github.com/skeema/knownhosts v1.3.1 h1:X2osQ+RAjK76shCbvhHHHVl3ZlgDm8apHEHFqRjnBY8= -github.com/skeema/knownhosts v1.3.1/go.mod h1:r7KTdC8l4uxWRyK2TpQZ/1o5HaSzh06ePQNxPwTcfiY= github.com/spf13/cobra v1.10.2 h1:DMTTonx5m65Ic0GOoRY2c16WCbHxOOw6xxezuLaBpcU= github.com/spf13/cobra v1.10.2/go.mod h1:7C1pvHqHw5A4vrJfjNwvOdzYu0Gml16OCs2GRiTUUS4= github.com/spf13/pflag v1.0.9/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= @@ -228,8 +184,6 @@ github.com/stretchr/testify v1.12.1 h1:EuwCh5fleGS7H32xRwO3wRGT7DxrDhLAT6FF8MpWD github.com/stretchr/testify v1.12.1/go.mod h1:MDEgiDPPsNp5cuIrHPPCyornHKgEVbtFUmoNlxoYthg= github.com/tailscale/hujson v0.0.0-20250605163823-992244df8c5a h1:a6TNDN9CgG+cYjaeN8l2mc4kSz2iMiCDQxPEyltUV/I= github.com/tailscale/hujson v0.0.0-20250605163823-992244df8c5a/go.mod h1:EbW0wDK/qEUYI0A5bqq0C2kF8JTQwWONmGDBbzsxxHo= -github.com/xanzy/ssh-agent v0.3.3 h1:+/15pJfg/RsTxqYcX6fHqOXZwwMP+2VyYWJeWM2qQFM= -github.com/xanzy/ssh-agent v0.3.3/go.mod h1:6dzNDKs0J9rVPHPhaGCukekBHKqfl+L3KghI1Bc68Uw= github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e h1:JVG44RsyaB9T2KIHavMF/ppJZNG9ZpyihvCd0w101no= github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e/go.mod h1:RbqR21r5mrJuqunuUZ/Dhy/avygyECGrLceyNeo4LiM= github.com/zalando/go-keyring v0.2.8 h1:6sD/Ucpl7jNq10rM2pgqTs0sZ9V3qMrqfIIy5YPccHs= @@ -292,8 +246,6 @@ gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntN gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= gopkg.in/ini.v1 v1.67.3 h1:iM9Lhz5MRSGhHVGGwCuzG9KO8PoirCXj/m/qTmOJJQw= gopkg.in/ini.v1 v1.67.3/go.mod h1:x/cyOwCgZqOkJoDIJ3c1KNHMo10+nLGAhh+kn3Zizss= -gopkg.in/warnings.v0 v0.1.2 h1:wFXVbFY8DY5/xOe1ECiWdKCzZlxgshcYVNkBHstARME= -gopkg.in/warnings.v0 v0.1.2/go.mod h1:jksf8JmL6Qr/oQM2OXTHunEvvTAsrWBLb6OOjuVWRNI= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= diff --git a/internal/build/notice_test.go b/internal/build/notice_test.go index ea71f1f77a8..359caeb4381 100644 --- a/internal/build/notice_test.go +++ b/internal/build/notice_test.go @@ -30,9 +30,7 @@ var noticeExclude = map[string]bool{ // Additional entries required in the NOTICE file that are not direct go.mod // dependencies (e.g. bundled binaries). -var noticeExtra = map[string][]string{ - "hashicorp/terraform": {"MPL-2.0"}, -} +var noticeExtra = map[string][]string{} // Expected order of license sections in the NOTICE file. var expectedSectionOrder = []string{