Skip to content

Commit 15cdda5

Browse files
authored
acceptance: make generate/*_and_deploy bundle names unique (#5446)
## Changes Append `-$UNIQUE_NAME` to the bundle name in `generate/pipeline_and_deploy` and `python_job_and_deploy` (via `databricks.yml.tmpl` + `envsubst`). ## Why The static bundle name made all parallel cloud variants deploy to the same path, causing deploy-lock contention where all but one variant failed. ## Tests Regenerated outputs; both tests pass across all engine variants.
1 parent 0cbdd49 commit 15cdda5

8 files changed

Lines changed: 12 additions & 8 deletions

File tree

acceptance/bundle/generate/pipeline_and_deploy/databricks.yml

Lines changed: 0 additions & 2 deletions
This file was deleted.
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
bundle:
2+
name: pipeline_and_deploy-$UNIQUE_NAME

acceptance/bundle/generate/pipeline_and_deploy/output.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,13 @@ Pipeline configuration successfully saved to resources/out.pipeline.yml
1313
=== Verify generated yaml has expected fields
1414
=== Deploy the generated bundle
1515
>>> [CLI] bundle deploy
16-
Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/pipeline_and_deploy/default/files...
16+
Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/pipeline_and_deploy-[UNIQUE_NAME]/default/files...
1717
Deploying resources...
1818
Deployment complete!
1919

2020
=== Destroy the deployed bundle
2121
>>> [CLI] bundle destroy --auto-approve
22-
All files and directories at the following location will be deleted: /Workspace/Users/[USERNAME]/.bundle/pipeline_and_deploy/default
22+
All files and directories at the following location will be deleted: /Workspace/Users/[USERNAME]/.bundle/pipeline_and_deploy-[UNIQUE_NAME]/default
2323

2424
Deleting files...
2525
Destroy complete!

acceptance/bundle/generate/pipeline_and_deploy/script

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
envsubst < databricks.yml.tmpl > databricks.yml
2+
13
title "Upload files to workspace"
24
trace $CLI workspace import "/Workspace/Users/${CURRENT_USER_NAME}/notebook.py" --file notebook.py --format AUTO --overwrite
35
trace $CLI workspace import "/Workspace/Users/${CURRENT_USER_NAME}/test.py" --file test.py --format AUTO --overwrite

acceptance/bundle/generate/python_job_and_deploy/databricks.yml

Lines changed: 0 additions & 2 deletions
This file was deleted.
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
bundle:
2+
name: python_job_and_deploy-$UNIQUE_NAME

acceptance/bundle/generate/python_job_and_deploy/output.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,13 @@ Job configuration successfully saved to resources/out.job.yml
1212
=== Verify generated yaml has expected fields
1313
=== Deploy the generated bundle
1414
>>> [CLI] bundle deploy
15-
Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/python_job_and_deploy/default/files...
15+
Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/python_job_and_deploy-[UNIQUE_NAME]/default/files...
1616
Deploying resources...
1717
Deployment complete!
1818

1919
=== Destroy the deployed bundle
2020
>>> [CLI] bundle destroy --auto-approve
21-
All files and directories at the following location will be deleted: /Workspace/Users/[USERNAME]/.bundle/python_job_and_deploy/default
21+
All files and directories at the following location will be deleted: /Workspace/Users/[USERNAME]/.bundle/python_job_and_deploy-[UNIQUE_NAME]/default
2222

2323
Deleting files...
2424
Destroy complete!

acceptance/bundle/generate/python_job_and_deploy/script

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
envsubst < databricks.yml.tmpl > databricks.yml
2+
13
title "Upload notebook to a workspace path"
24
trace $CLI workspace import "/Workspace/Users/${CURRENT_USER_NAME}/test_notebook.py" --file test_notebook.py --format AUTO --overwrite
35

0 commit comments

Comments
 (0)