Skip to content

Commit e4f56e8

Browse files
olavloitesduskis
authored andcommitted
gax 1.45 uses totalTimeout also when retries have been disabled (#5283)
Gax 1.44 ignored the totalTimeout that had been set on RetrySettings if the retry codes had been set to an empty set, effectively disabling all retries. In gax 1.45, the totalTimeout setting is used and will cause a timeout also when no retry codes have been set.
1 parent 67072ee commit e4f56e8

3 files changed

Lines changed: 3 additions & 3 deletions

File tree

google-cloud-clients/google-cloud-spanner/src/test/java/com/google/cloud/spanner/DatabaseAdminGaxTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ public void setUp() throws Exception {
233233
.setInitialRpcTimeout(Duration.ofMillis(200L))
234234
.setMaxRpcTimeout(Duration.ofMillis(200L))
235235
.setMaxAttempts(3)
236-
.setTotalTimeout(Duration.ofMillis(500L))
236+
.setTotalTimeout(Duration.ofMillis(1500L))
237237
.build();
238238
SpannerOptions.Builder builder =
239239
SpannerOptions.newBuilder()

google-cloud-clients/google-cloud-spanner/src/test/java/com/google/cloud/spanner/InstanceAdminGaxTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -236,7 +236,7 @@ public void setUp() throws Exception {
236236
.setInitialRpcTimeout(Duration.ofMillis(200L))
237237
.setMaxRpcTimeout(Duration.ofMillis(200L))
238238
.setMaxAttempts(3)
239-
.setTotalTimeout(Duration.ofMillis(500L))
239+
.setTotalTimeout(Duration.ofMillis(1500L))
240240
.build();
241241
SpannerOptions.Builder builder =
242242
SpannerOptions.newBuilder()

google-cloud-clients/google-cloud-spanner/src/test/java/com/google/cloud/spanner/SpannerGaxRetryTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,7 @@ public void setUp() throws Exception {
201201
.setInitialRpcTimeout(Duration.ofMillis(500L))
202202
.setMaxRpcTimeout(Duration.ofMillis(500L))
203203
.setMaxAttempts(3)
204-
.setTotalTimeout(Duration.ofMillis(1000L))
204+
.setTotalTimeout(Duration.ofMillis(1500L))
205205
.build();
206206
RetrySettings commitRetrySettings =
207207
RetrySettings.newBuilder()

0 commit comments

Comments
 (0)