From b7d9b484af5aa68ef94d16df4a72663127ac2f7d Mon Sep 17 00:00:00 2001 From: Denis Bilenko Date: Thu, 28 May 2026 13:06:47 +0200 Subject: [PATCH 1/3] Extend retries to 5xx and 408 Follow up to #5349 --- NEXT_CHANGELOG.md | 2 +- bundle/direct/retry.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/NEXT_CHANGELOG.md b/NEXT_CHANGELOG.md index f28f0e6d257..7c91a5a01b8 100644 --- a/NEXT_CHANGELOG.md +++ b/NEXT_CHANGELOG.md @@ -8,6 +8,6 @@ * `experimental open` now opens every DABs resource type that has a workspace URL, picking up `catalogs`, `schemas`, `volumes`, `database_instances`, `database_catalogs`, `synced_database_tables`, `postgres_catalogs`, `postgres_synced_tables`, `quality_monitors`, `vector_search_endpoints`, and `vector_search_indexes` ([#5346](https://github.com/databricks/cli/pull/5346)). ### Bundles -* Retry transient HTTP 504 Gateway Timeout errors in direct deployment engine ([#5349](https://github.com/databricks/cli/pull/5349)). +* Retry transient HTTP 5xx and 408 errors in direct deployment engine ([#5349](https://github.com/databricks/cli/pull/5349)). ### Dependency updates diff --git a/bundle/direct/retry.go b/bundle/direct/retry.go index bbe066c6fee..3072ab6cffc 100644 --- a/bundle/direct/retry.go +++ b/bundle/direct/retry.go @@ -41,7 +41,7 @@ func isTransient(ctx context.Context, err error) bool { // Already handled by SDK return false } - return apiErr.StatusCode == http.StatusGatewayTimeout + return apiErr.StatusCode >= 500 && apiErr.StatusCode == http.StatusRequestTimeout } // retryWith retries fn while check returns true for the error, up to maxRetries times. From 15d8c3f89c11a0a633473ee4f71e9ce93495157e Mon Sep 17 00:00:00 2001 From: Denis Bilenko Date: Thu, 28 May 2026 13:24:44 +0200 Subject: [PATCH 2/3] update NEXT_CHANGELOG --- NEXT_CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/NEXT_CHANGELOG.md b/NEXT_CHANGELOG.md index 7c91a5a01b8..d348f0600bb 100644 --- a/NEXT_CHANGELOG.md +++ b/NEXT_CHANGELOG.md @@ -8,6 +8,6 @@ * `experimental open` now opens every DABs resource type that has a workspace URL, picking up `catalogs`, `schemas`, `volumes`, `database_instances`, `database_catalogs`, `synced_database_tables`, `postgres_catalogs`, `postgres_synced_tables`, `quality_monitors`, `vector_search_endpoints`, and `vector_search_indexes` ([#5346](https://github.com/databricks/cli/pull/5346)). ### Bundles -* Retry transient HTTP 5xx and 408 errors in direct deployment engine ([#5349](https://github.com/databricks/cli/pull/5349)). +* Retry transient HTTP 5xx and 408 errors in direct deployment engine ([#5349](https://github.com/databricks/cli/pull/5349), [#5364](https://github.com/databricks/cli/pull/5364)). ### Dependency updates From cbe3ea7e128980e4ec84d9248a0fb9383a32878a Mon Sep 17 00:00:00 2001 From: Denis Bilenko Date: Mon, 1 Jun 2026 10:26:39 +0200 Subject: [PATCH 3/3] fix(direct): use OR instead of AND in isTransient so 5xx and 408 are both retried The condition `StatusCode >= 500 && StatusCode == 408` is logically impossible (no code can satisfy both). Using `||` lets both 5xx errors and 408 Request Timeout trigger the retry path, which is the intended behaviour from the parent commit. Co-authored-by: Isaac --- bundle/direct/retry.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bundle/direct/retry.go b/bundle/direct/retry.go index 3072ab6cffc..43f5d6f0a4b 100644 --- a/bundle/direct/retry.go +++ b/bundle/direct/retry.go @@ -41,7 +41,7 @@ func isTransient(ctx context.Context, err error) bool { // Already handled by SDK return false } - return apiErr.StatusCode >= 500 && apiErr.StatusCode == http.StatusRequestTimeout + return apiErr.StatusCode >= 500 || apiErr.StatusCode == http.StatusRequestTimeout } // retryWith retries fn while check returns true for the error, up to maxRetries times.