Skip to content

Fix config-remote-sync writing dashboard etag into YAML#5589

Open
ilyakuz-db wants to merge 1 commit into
mainfrom
configsync-skip-dashboard-etag
Open

Fix config-remote-sync writing dashboard etag into YAML#5589
ilyakuz-db wants to merge 1 commit into
mainfrom
configsync-skip-dashboard-etag

Conversation

@ilyakuz-db

Copy link
Copy Markdown
Contributor

Changes

bundle config-remote-sync no longer writes the dashboard etag field into bundle configuration when the remote etag drifts (e.g. someone opened or edited the dashboard draft in the workspace UI).

Added resources.dashboards.*.etag to the configsync skip table. This is an intentionally minimal fix; a follow-up PR migrates the whole table to the resource lifecycle metadata in resources.yml.

Why

etag is output-only and never present in configuration. The deploy plan re-promotes etag drift to Update via ResourceDashboard.OverrideChangeDesc (required for deploy's modified-remotely detection), so configsync cannot rely on the plan's Skip action and must exclude the field explicitly. Without this, config-remote-sync --save hardcodes a stale etag into the dashboard YAML; the config then fails validation ("Etags must not be set in bundle configuration"), breaking subsequent deploys and even bundle destroy, and leaves CI/state/remote permanently inconsistent.

Tests

New acceptance test acceptance/bundle/config-remote-sync/dashboard_etag (local + cloud, both engines): deploys a dashboard, simulates an out-of-band modification via lakeview update (bumps the remote etag), and asserts config-remote-sync reports no changes and --save leaves the YAML untouched. Before the fix the test reproduces the leak (etag: add reported and written to databricks.yml). Also a unit test pinning the skip rule.

Verified on a real workspace via the cloud acceptance run for bundle/config-remote-sync.

@github-actions

github-actions Bot commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

Approval status: pending

/acceptance/bundle/ - needs approval

6 files changed
Eligible: @andrewnester, @anton-107, @denik, @janniklasrose, @pietern, @shreyas-goenka, @lennartkats-db

/bundle/ - needs approval

Files: bundle/configsync/defaults.go, bundle/configsync/diff_test.go
Eligible: @andrewnester, @anton-107, @denik, @janniklasrose, @pietern, @shreyas-goenka, @lennartkats-db

Any maintainer (@andrewnester, @anton-107, @denik, @pietern, @shreyas-goenka, @simonfaltum, @renaudhartert-db) can approve all areas.
See OWNERS for ownership rules.

@ilyakuz-db ilyakuz-db force-pushed the configsync-skip-dashboard-etag branch from c9295ba to 74fe136 Compare June 12, 2026 20:27
The deploy plan promotes dashboard etag drift to an Update action via
ResourceDashboard.OverrideChangeDesc so that out-of-band modifications
are detected during deploy. config-remote-sync consumed that plan entry
and, since etag is never present in config, classified it as an add,
writing the output-only etag field into the user's databricks.yml with
--save. The resulting config then fails validation (etags must not be
set in bundle configuration).

Skip the etag field explicitly in configsync's server-side defaults and
add an acceptance test that bumps the remote etag out of band and
verifies config-remote-sync reports no changes and --save leaves the
config untouched.
@ilyakuz-db ilyakuz-db force-pushed the configsync-skip-dashboard-etag branch from 74fe136 to f4c45ef Compare June 13, 2026 01:35
@ilyakuz-db ilyakuz-db temporarily deployed to test-trigger-is June 13, 2026 01:36 — with GitHub Actions Inactive
@ilyakuz-db ilyakuz-db temporarily deployed to test-trigger-is June 13, 2026 01:36 — with GitHub Actions Inactive
@eng-dev-ecosystem-bot

Copy link
Copy Markdown
Collaborator

Integration test report

Commit: f4c45ef

Run: 27452721226

Env 🟨​KNOWN 💚​RECOVERED 🙈​SKIP ✅​pass 🙈​skip Time
🟨​ aws linux 7 15 264 978 7:34
🟨​ aws windows 7 15 266 976 16:12
💚​ aws-ucws linux 7 15 360 892 6:50
💚​ aws-ucws windows 7 15 362 890 12:34
💚​ azure linux 1 17 267 976 6:24
💚​ azure windows 1 17 269 974 11:23
💚​ azure-ucws linux 1 17 365 888 7:24
💚​ azure-ucws windows 1 17 367 886 12:29
💚​ gcp linux 1 17 263 979 7:53
💚​ gcp windows 1 17 265 977 12:02
22 interesting tests: 15 SKIP, 7 KNOWN
Test Name aws linux aws windows aws-ucws linux aws-ucws windows azure linux azure windows azure-ucws linux azure-ucws windows gcp linux gcp windows
🟨​ TestAccept 🟨​K 🟨​K 💚​R 💚​R 💚​R 💚​R 💚​R 💚​R 💚​R 💚​R
🙈​ TestAccept/bundle/invariant/no_drift 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/permissions 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🟨​ TestAccept/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions 🟨​K 🟨​K 💚​R 💚​R 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🟨​ TestAccept/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/DATABRICKS_BUNDLE_ENGINE=direct 🟨​K 🟨​K 💚​R 💚​R
🟨​ TestAccept/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/DATABRICKS_BUNDLE_ENGINE=terraform 🟨​K 🟨​K 💚​R 💚​R
🟨​ TestAccept/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions 🟨​K 🟨​K 💚​R 💚​R 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🟨​ TestAccept/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/DATABRICKS_BUNDLE_ENGINE=direct 🟨​K 🟨​K 💚​R 💚​R
🟨​ TestAccept/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/DATABRICKS_BUNDLE_ENGINE=terraform 🟨​K 🟨​K 💚​R 💚​R
🙈​ TestAccept/bundle/resources/postgres_branches/basic 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/postgres_branches/recreate 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/postgres_branches/replace_existing 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/postgres_branches/update_protected 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/postgres_branches/without_branch_id 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/postgres_endpoints/basic 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/postgres_endpoints/recreate 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/postgres_projects/update_display_name 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/synced_database_tables/basic 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/vector_search_endpoints/drift/recreated_same_name 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/vector_search_indexes/basic 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/vector_search_indexes/grants/select 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/ssh/connection 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
Top 28 slowest tests (at least 2 minutes):
duration env testname
6:18 aws-ucws windows TestAccept
6:17 azure windows TestAccept
6:14 gcp windows TestAccept
6:13 azure-ucws windows TestAccept
4:44 gcp linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
4:36 gcp linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct
4:30 gcp windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct
4:19 gcp windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
3:24 azure windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
2:59 aws-ucws linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
2:57 gcp linux TestAccept
2:56 azure-ucws windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
2:54 aws windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
2:53 azure linux TestAccept
2:51 aws windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct
2:49 aws-ucws linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct
2:47 aws-ucws linux TestAccept
2:46 azure-ucws linux TestAccept
2:44 aws-ucws windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
2:43 azure linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
2:41 aws-ucws windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct
2:40 azure-ucws linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
2:40 azure-ucws windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct
2:37 aws linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
2:32 azure linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct
2:27 azure windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct
2:24 azure-ucws linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct
2:21 aws linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants