Skip to content

Commit

Permalink
Increase retries for trino-filesystem-gcs
Browse files Browse the repository at this point in the history
  • Loading branch information
elonazoulay authored and electrum committed Jan 11, 2024
1 parent 020cafe commit 554618a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,11 @@ public class GcsFileSystemConfig
private String jsonKey;
private String jsonKeyFilePath;
private int maxRetries = 20;
private double backoffScaleFactor = 2.0;
private Duration maxRetryTime = new Duration(20, TimeUnit.SECONDS);
private double backoffScaleFactor = 3.0;
private Duration maxRetryTime = new Duration(25, TimeUnit.SECONDS);
private Duration minBackoffDelay = new Duration(10, TimeUnit.MILLISECONDS);
// Note: there is no benefit to setting this much higher as the rpc quota is 1x per second: https://cloud.google.com/storage/docs/retry-strategy#java
private Duration maxBackoffDelay = new Duration(1100, TimeUnit.MILLISECONDS);
private Duration maxBackoffDelay = new Duration(2000, TimeUnit.MILLISECONDS);

@NotNull
public DataSize getReadBlockSize()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,10 @@ void testDefaults()
.setJsonKey(null)
.setJsonKeyFilePath(null)
.setMaxRetries(20)
.setBackoffScaleFactor(2.0)
.setMaxRetryTime(new Duration(20, SECONDS))
.setBackoffScaleFactor(3.0)
.setMaxRetryTime(new Duration(25, SECONDS))
.setMinBackoffDelay(new Duration(10, MILLISECONDS))
.setMaxBackoffDelay(new Duration(1100, MILLISECONDS)));
.setMaxBackoffDelay(new Duration(2000, MILLISECONDS)));
}

@Test
Expand Down

0 comments on commit 554618a

Please sign in to comment.