Skip to content

Commit 0932605

Browse files
authored
test: Reduce the LRO timeout value in Showcase tests (#3684)
fixes: #3277 I run the flaky test locally 1000 times but couldn't reproduce the issue. Despite that, reduce the LRO timeout values in the Showcase test `ITLongRunningOperation.testHttpJson_LROUnsuccessfulResponse_exceedsTotalTimeout_throwsDeadlineExceededException` could make the test scenario fail fast and less flaky.
1 parent 47ab198 commit 0932605

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

java-showcase/gapic-showcase/src/test/java/com/google/showcase/v1beta1/it/ITLongRunningOperation.java

+6-6
Original file line numberDiff line numberDiff line change
@@ -161,17 +161,17 @@ void testHttpJson_LROUnsuccessfulResponse_exceedsTotalTimeout_throwsDeadlineExce
161161
throws Exception {
162162
RetrySettings initialUnaryRetrySettings =
163163
RetrySettings.newBuilder()
164-
.setInitialRpcTimeout(Duration.ofMillis(5000L))
164+
.setInitialRpcTimeout(Duration.ofMillis(500L))
165165
.setRpcTimeoutMultiplier(1.0)
166-
.setMaxRpcTimeout(Duration.ofMillis(5000L))
167-
.setTotalTimeout(Duration.ofMillis(5000L))
166+
.setMaxRpcTimeout(Duration.ofMillis(500L))
167+
.setTotalTimeout(Duration.ofMillis(500L))
168168
.build();
169169
RetrySettings pollingRetrySettings =
170170
RetrySettings.newBuilder()
171-
.setInitialRetryDelay(Duration.ofMillis(1000L))
171+
.setInitialRetryDelay(Duration.ofMillis(100L))
172172
.setRetryDelayMultiplier(2.0)
173-
.setMaxRetryDelay(Duration.ofMillis(3000L))
174-
.setTotalTimeout(Duration.ofMillis(5000L))
173+
.setMaxRetryDelay(Duration.ofMillis(500L))
174+
.setTotalTimeout(Duration.ofMillis(1000L))
175175
.build();
176176
EchoClient httpjsonClient =
177177
TestClientInitializer.createHttpJsonEchoClientCustomWaitSettings(

0 commit comments

Comments
 (0)