Skip to content

Commit

Permalink
Retry on "HTTP Response code: 504" in Databricks tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ebyhr committed Sep 21, 2023
1 parent 5b21814 commit ec62980
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,9 @@ public final class DeltaLakeTestUtils
public static final String DATABRICKS_COMMUNICATION_FAILURE_ISSUE = "https://github.com/trinodb/trino/issues/14391";
@Language("RegExp")
public static final String DATABRICKS_COMMUNICATION_FAILURE_MATCH =
"\\Q[Databricks][DatabricksJDBCDriver](500593) Communication link failure. Failed to connect to server. Reason: HTTP retry after response received with no Retry-After header, error: HTTP Response code: 503, Error message: Unknown.";
"\\Q[Databricks][DatabricksJDBCDriver](500593) Communication link failure. Failed to connect to server. Reason: \\E" +
"(HTTP retry after response received with no Retry-After header, error: HTTP Response code: 503|HTTP Response code: 504)" +
", Error message: Unknown.";
private static final RetryPolicy<QueryResult> CONCURRENT_MODIFICATION_EXCEPTION_RETRY_POLICY = RetryPolicy.<QueryResult>builder()
.handleIf(throwable -> Throwables.getRootCause(throwable) instanceof ConcurrentModificationException)
.handleIf(throwable -> throwable.getMessage() != null && throwable.getMessage().contains("Table being modified concurrently"))
Expand Down

0 comments on commit ec62980

Please sign in to comment.