Skip to content

Commit 75842c1

Browse files
authored
Deprecate legacy classes and use new when possible (#4154)
* Deprecate legacy classes and use new when possible * Fix checkstyle and add some more validation * Add missing @deprecated annotation * Add missing dependency to the retries-api module
1 parent 64648eb commit 75842c1

File tree

43 files changed

+134
-175
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+134
-175
lines changed

core/aws-core/src/main/java/software/amazon/awssdk/awscore/retry/AwsRetryPolicy.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,11 @@
2525

2626
/**
2727
* Retry Policy used by clients when communicating with AWS services.
28+
*
29+
* @deprecated Use instead {@link AwsRetryStrategy}
2830
*/
2931
@SdkPublicApi
32+
@Deprecated
3033
public final class AwsRetryPolicy {
3134

3235
private AwsRetryPolicy() {

core/aws-core/src/test/java/software/amazon/awssdk/awscore/client/utils/HttpTestUtils.java

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -21,13 +21,13 @@
2121
import java.util.concurrent.Executors;
2222
import software.amazon.awssdk.auth.credentials.DefaultCredentialsProvider;
2323
import software.amazon.awssdk.awscore.client.config.AwsClientOption;
24+
import software.amazon.awssdk.awscore.retry.AwsRetryStrategy;
2425
import software.amazon.awssdk.core.client.config.SdkAdvancedAsyncClientOption;
2526
import software.amazon.awssdk.core.client.config.SdkAdvancedClientOption;
2627
import software.amazon.awssdk.core.client.config.SdkClientConfiguration;
2728
import software.amazon.awssdk.core.client.config.SdkClientOption;
2829
import software.amazon.awssdk.core.internal.http.AmazonSyncHttpClient;
2930
import software.amazon.awssdk.core.internal.http.loader.DefaultSdkHttpClientBuilder;
30-
import software.amazon.awssdk.core.retry.RetryPolicy;
3131
import software.amazon.awssdk.core.signer.NoOpSigner;
3232
import software.amazon.awssdk.http.SdkHttpClient;
3333
import software.amazon.awssdk.http.SdkHttpConfigurationOption;
@@ -51,7 +51,7 @@ public static SdkClientConfiguration testClientConfiguration() {
5151
return SdkClientConfiguration.builder()
5252
.option(SdkClientOption.EXECUTION_INTERCEPTORS, new ArrayList<>())
5353
.option(SdkClientOption.ENDPOINT, URI.create("http://localhost:8080"))
54-
.option(SdkClientOption.RETRY_POLICY, RetryPolicy.defaultRetryPolicy())
54+
.option(SdkClientOption.RETRY_STRATEGY, AwsRetryStrategy.defaultRetryStrategy())
5555
.option(SdkClientOption.ADDITIONAL_HTTP_HEADERS, new HashMap<>())
5656
.option(SdkClientOption.CRC32_FROM_COMPRESSED_DATA_ENABLED, false)
5757
.option(AwsClientOption.CREDENTIALS_PROVIDER, DefaultCredentialsProvider.create())
@@ -64,14 +64,8 @@ public static SdkClientConfiguration testClientConfiguration() {
6464
}
6565

6666
public static class TestClientBuilder {
67-
private RetryPolicy retryPolicy;
6867
private SdkHttpClient httpClient;
6968

70-
public TestClientBuilder retryPolicy(RetryPolicy retryPolicy) {
71-
this.retryPolicy = retryPolicy;
72-
return this;
73-
}
74-
7569
public TestClientBuilder httpClient(SdkHttpClient sdkHttpClient) {
7670
this.httpClient = sdkHttpClient;
7771
return this;
@@ -81,14 +75,7 @@ public AmazonSyncHttpClient build() {
8175
SdkHttpClient sdkHttpClient = this.httpClient != null ? this.httpClient : testSdkHttpClient();
8276
return new AmazonSyncHttpClient(testClientConfiguration().toBuilder()
8377
.option(SdkClientOption.SYNC_HTTP_CLIENT, sdkHttpClient)
84-
.applyMutation(this::configureRetryPolicy)
8578
.build());
8679
}
87-
88-
private void configureRetryPolicy(SdkClientConfiguration.Builder builder) {
89-
if (retryPolicy != null) {
90-
builder.option(SdkClientOption.RETRY_POLICY, retryPolicy);
91-
}
92-
}
9380
}
9481
}

core/retries-api/src/main/java/software/amazon/awssdk/retries/api/RetryStrategy.java

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -204,6 +204,13 @@ default B retryOnRootCauseInstanceOf(Class<? extends Throwable> throwable) {
204204
*/
205205
B maxAttempts(int maxAttempts);
206206

207+
/**
208+
* Configure the backoff strategy used by this executor.
209+
*
210+
* <p>By default, this uses jittered exponential backoff.
211+
*/
212+
B backoffStrategy(BackoffStrategy backoffStrategy);
213+
207214
/**
208215
* Build a new {@link RetryStrategy} with the current configuration on this builder.
209216
*/

core/retries-api/src/main/java/software/amazon/awssdk/retries/api/internal/backoff/BackoffStrategiesConstants.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ private BackoffStrategiesConstants() {
4242
* get capped to 30.
4343
*/
4444
static int calculateExponentialDelay(int retriesAttempted, Duration baseDelay, Duration maxBackoffTime) {
45-
int cappedRetries = Math.min(retriesAttempted, BackoffStrategiesConstants.RETRIES_ATTEMPTED_CEILING);
45+
int cappedRetries = Math.min(retriesAttempted, RETRIES_ATTEMPTED_CEILING);
4646
return (int) Math.min(baseDelay.multipliedBy(1L << (cappedRetries - 2)).toMillis(), maxBackoffTime.toMillis());
4747
}
4848
}

core/retries-api/src/test/java/software/amazon/awssdk/retries/api/RetryStrategyBuilderTest.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,11 @@ public BuilderToTestDefaults maxAttempts(int maxAttempts) {
153153
return this;
154154
}
155155

156+
@Override
157+
public BuilderToTestDefaults backoffStrategy(BackoffStrategy backoffStrategy) {
158+
return this;
159+
}
160+
156161
@Override
157162
public DummyRetryStrategy build() {
158163
return null;

core/retries/src/main/java/software/amazon/awssdk/retries/DefaultRetryStrategy.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ public static AdaptiveRetryStrategy.Builder adaptiveStrategyBuilder() {
9595

9696
static final class Standard {
9797
static final int MAX_ATTEMPTS = 3;
98-
static final Duration BASE_DELAY = Duration.ofSeconds(1);
98+
static final Duration BASE_DELAY = Duration.ofMillis(100);
9999
static final Duration MAX_BACKOFF = Duration.ofSeconds(20);
100100
static final int TOKEN_BUCKET_SIZE = 500;
101101
static final int DEFAULT_EXCEPTION_TOKEN_COST = 5;

core/retries/src/main/java/software/amazon/awssdk/retries/LegacyRetryStrategy.java

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -74,13 +74,6 @@ static Builder builder() {
7474
Builder toBuilder();
7575

7676
interface Builder extends RetryStrategy.Builder<Builder, LegacyRetryStrategy> {
77-
/**
78-
* Configure the backoff strategy used by this strategy.
79-
*
80-
* <p>By default, this uses jittered exponential backoff.
81-
*/
82-
Builder backoffStrategy(BackoffStrategy backoffStrategy);
83-
8477
/**
8578
* Configure the backoff strategy used for throttling exceptions by this strategy.
8679
*

core/retries/src/main/java/software/amazon/awssdk/retries/StandardRetryStrategy.java

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -70,13 +70,6 @@ static Builder builder() {
7070
Builder toBuilder();
7171

7272
interface Builder extends RetryStrategy.Builder<Builder, StandardRetryStrategy> {
73-
/**
74-
* Configure the backoff strategy used by this executor.
75-
*
76-
* <p>By default, this uses jittered exponential backoff.
77-
*/
78-
Builder backoffStrategy(BackoffStrategy backoffStrategy);
79-
8073
/**
8174
* Whether circuit breaking is enabled for this executor.
8275
*

core/retries/src/main/java/software/amazon/awssdk/retries/internal/BaseRetryStrategy.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,6 @@ public int maxAttempts() {
146146
@Override
147147
public abstract B toBuilder();
148148

149-
150149
/**
151150
* Computes the backoff before the first attempt, by default
152151
* {@link Duration#ZERO}. Extending classes can override

core/retries/src/main/java/software/amazon/awssdk/retries/internal/DefaultAdaptiveRetryStrategy.java

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -111,13 +111,14 @@ public Builder treatAsThrottling(Predicate<Throwable> treatAsThrottling) {
111111
return this;
112112
}
113113

114-
public Builder circuitBreakerEnabled(Boolean circuitBreakerEnabled) {
115-
setCircuitBreakerEnabled(circuitBreakerEnabled);
114+
@Override
115+
public Builder backoffStrategy(BackoffStrategy backoffStrategy) {
116+
setBackoffStrategy(backoffStrategy);
116117
return this;
117118
}
118119

119-
public Builder backoffStrategy(BackoffStrategy backoffStrategy) {
120-
setBackoffStrategy(backoffStrategy);
120+
public Builder circuitBreakerEnabled(Boolean circuitBreakerEnabled) {
121+
setCircuitBreakerEnabled(circuitBreakerEnabled);
121122
return this;
122123
}
123124

core/retries/src/main/java/software/amazon/awssdk/retries/internal/DefaultLegacyRetryStrategy.java

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
import software.amazon.awssdk.retries.api.RefreshRetryTokenRequest;
2424
import software.amazon.awssdk.retries.internal.circuitbreaker.TokenBucketStore;
2525
import software.amazon.awssdk.utils.Logger;
26+
import software.amazon.awssdk.utils.Validate;
2627

2728
@SdkInternalApi
2829
public final class DefaultLegacyRetryStrategy
@@ -34,9 +35,9 @@ public final class DefaultLegacyRetryStrategy
3435

3536
DefaultLegacyRetryStrategy(Builder builder) {
3637
super(LOG, builder);
37-
this.throttlingExceptionCost = builder.throttlingExceptionCost;
38-
this.throttlingBackoffStrategy = builder.throttlingBackoffStrategy;
39-
this.treatAsThrottling = builder.treatAsThrottling;
38+
this.throttlingExceptionCost = Validate.paramNotNull(builder.throttlingExceptionCost, "throttlingExceptionCost");
39+
this.throttlingBackoffStrategy = Validate.paramNotNull(builder.throttlingBackoffStrategy, "throttlingBackoffStrategy");
40+
this.treatAsThrottling = Validate.paramNotNull(builder.treatAsThrottling, "treatAsThrottling");
4041
}
4142

4243
@Override

core/sdk-core/src/it/java/software/amazon/awssdk/core/http/AmazonHttpClientSslHandshakeTimeoutTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,10 @@
2828
import software.amazon.awssdk.core.exception.SdkClientException;
2929
import software.amazon.awssdk.core.internal.http.AmazonSyncHttpClient;
3030
import software.amazon.awssdk.core.internal.http.response.NullErrorResponseHandler;
31-
import software.amazon.awssdk.core.retry.RetryPolicy;
3231
import software.amazon.awssdk.http.SdkHttpFullRequest;
3332
import software.amazon.awssdk.http.SdkHttpMethod;
3433
import software.amazon.awssdk.http.apache.ApacheHttpClient;
34+
import software.amazon.awssdk.retries.DefaultRetryStrategy;
3535
import utils.HttpTestUtils;
3636

3737
/**
@@ -48,7 +48,7 @@ public class AmazonHttpClientSslHandshakeTimeoutTest extends UnresponsiveMockSer
4848
@Test(timeout = 60 * 1000)
4949
public void testSslHandshakeTimeout() {
5050
AmazonSyncHttpClient httpClient = HttpTestUtils.testClientBuilder()
51-
.retryPolicy(RetryPolicy.none())
51+
.retryStrategy(DefaultRetryStrategy.none())
5252
.httpClient(ApacheHttpClient.builder()
5353
.socketTimeout(CLIENT_SOCKET_TO)
5454
.build())

core/sdk-core/src/it/java/software/amazon/awssdk/core/http/ConnectionPoolMaxConnectionsIntegrationTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,10 @@
3030
import software.amazon.awssdk.core.http.server.MockServer;
3131
import software.amazon.awssdk.core.internal.http.AmazonSyncHttpClient;
3232
import software.amazon.awssdk.core.internal.http.response.EmptySdkResponseHandler;
33-
import software.amazon.awssdk.core.retry.RetryPolicy;
3433
import software.amazon.awssdk.http.SdkHttpFullRequest;
3534
import software.amazon.awssdk.http.SdkHttpMethod;
3635
import software.amazon.awssdk.http.apache.ApacheHttpClient;
36+
import software.amazon.awssdk.retries.DefaultRetryStrategy;
3737
import utils.HttpTestUtils;
3838

3939
public class ConnectionPoolMaxConnectionsIntegrationTest {
@@ -57,7 +57,7 @@ public static void tearDown() {
5757
public void leasing_a_new_connection_fails_with_connection_pool_timeout() {
5858

5959
AmazonSyncHttpClient httpClient = HttpTestUtils.testClientBuilder()
60-
.retryPolicy(RetryPolicy.none())
60+
.retryStrategy(DefaultRetryStrategy.none())
6161
.httpClient(ApacheHttpClient.builder()
6262
.connectionTimeout(Duration.ofMillis(100))
6363
.maxConnections(1)

core/sdk-core/src/main/java/software/amazon/awssdk/core/internal/retry/RetryPolicyAdapter.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
import software.amazon.awssdk.core.retry.RetryUtils;
2828
import software.amazon.awssdk.retries.api.AcquireInitialTokenRequest;
2929
import software.amazon.awssdk.retries.api.AcquireInitialTokenResponse;
30+
import software.amazon.awssdk.retries.api.BackoffStrategy;
3031
import software.amazon.awssdk.retries.api.RecordSuccessRequest;
3132
import software.amazon.awssdk.retries.api.RecordSuccessResponse;
3233
import software.amazon.awssdk.retries.api.RefreshRetryTokenRequest;
@@ -164,6 +165,11 @@ public Builder maxAttempts(int maxAttempts) {
164165
throw new UnsupportedOperationException("RetryPolicyAdapter does not support calling retryOnException");
165166
}
166167

168+
@Override
169+
public Builder backoffStrategy(BackoffStrategy backoffStrategy) {
170+
throw new UnsupportedOperationException("RetryPolicyAdapter does not support calling backoffStrategy");
171+
}
172+
167173
public Builder retryPolicy(RetryPolicy retryPolicy) {
168174
this.retryPolicy = retryPolicy;
169175
return this;

core/sdk-core/src/main/java/software/amazon/awssdk/core/retry/RetryPolicy.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,9 +42,12 @@
4242
*
4343
* @see RetryCondition for a list of SDK provided retry condition strategies
4444
* @see BackoffStrategy for a list of SDK provided backoff strategies
45+
*
46+
* @deprecated Use instead {@link software.amazon.awssdk.retries.api.RetryStrategy}.
4547
*/
4648
@Immutable
4749
@SdkPublicApi
50+
@Deprecated
4851
public final class RetryPolicy implements ToCopyableBuilder<RetryPolicy.Builder, RetryPolicy> {
4952
private final boolean additionalRetryConditionsAllowed;
5053
private final RetryMode retryMode;

core/sdk-core/src/main/java/software/amazon/awssdk/core/retry/RetryPolicyContext.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,13 @@
2121
import software.amazon.awssdk.core.exception.SdkException;
2222
import software.amazon.awssdk.core.interceptor.ExecutionAttributes;
2323
import software.amazon.awssdk.http.SdkHttpFullRequest;
24+
import software.amazon.awssdk.retries.api.RetryStrategy;
2425
import software.amazon.awssdk.utils.builder.CopyableBuilder;
2526
import software.amazon.awssdk.utils.builder.ToCopyableBuilder;
2627

2728
/**
2829
* Contains useful information about a failed request that can be used to make retry and backoff decisions. See {@link
29-
* RetryPolicy}.
30+
* RetryPolicy} and {@link RetryStrategy}.
3031
*/
3132
@Immutable
3233
@SdkPublicApi
@@ -163,5 +164,4 @@ public RetryPolicyContext build() {
163164
}
164165

165166
}
166-
167167
}

core/sdk-core/src/main/java/software/amazon/awssdk/core/retry/backoff/BackoffStrategy.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,12 @@
2121
import software.amazon.awssdk.core.retry.RetryMode;
2222
import software.amazon.awssdk.core.retry.RetryPolicyContext;
2323

24+
/**
25+
* @deprecated Use instead {@link software.amazon.awssdk.retries.api.BackoffStrategy}
26+
*/
2427
@SdkPublicApi
2528
@FunctionalInterface
29+
@Deprecated
2630
public interface BackoffStrategy {
2731

2832
/**

core/sdk-core/src/main/java/software/amazon/awssdk/core/retry/backoff/EqualJitterBackoffStrategy.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,12 @@
3939
*
4040
* This is in contrast to {@link FullJitterBackoffStrategy} where the final computed delay before the next retry will be
4141
* between 0 and the computed exponential delay.
42+
*
43+
* @deprecated Use instead {@link software.amazon.awssdk.retries.api.BackoffStrategy} and
44+
* {@link software.amazon.awssdk.retries.api.BackoffStrategy#fixedDelayWithoutJitter(Duration)}
4245
*/
4346
@SdkPublicApi
47+
@Deprecated
4448
public final class EqualJitterBackoffStrategy implements BackoffStrategy,
4549
ToCopyableBuilder<EqualJitterBackoffStrategy.Builder,
4650
EqualJitterBackoffStrategy> {

core/sdk-core/src/main/java/software/amazon/awssdk/core/retry/backoff/FixedDelayBackoffStrategy.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,12 @@
2424

2525
/**
2626
* Simple backoff strategy that always uses a fixed delay for the delay before the next retry attempt.
27+
*
28+
* @deprecated Use instead {@link software.amazon.awssdk.retries.api.BackoffStrategy} and
29+
* {@link software.amazon.awssdk.retries.api.BackoffStrategy#fixedDelay(Duration)}.
2730
*/
2831
@SdkPublicApi
32+
@Deprecated
2933
public final class FixedDelayBackoffStrategy implements BackoffStrategy {
3034

3135
private final Duration fixedBackoff;

core/sdk-core/src/main/java/software/amazon/awssdk/core/retry/backoff/FullJitterBackoffStrategy.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,12 @@
3636
*
3737
* This is in contrast to {@link EqualJitterBackoffStrategy} that computes a new random delay where the final
3838
* computed delay before the next retry will be at least half of the computed exponential delay.
39+
*
40+
* @deprecated Use instead {@link software.amazon.awssdk.retries.api.BackoffStrategy} and
41+
* {@link software.amazon.awssdk.retries.api.BackoffStrategy#exponentialDelayWithoutJitter(Duration, Duration)}.
3942
*/
4043
@SdkPublicApi
44+
@Deprecated
4145
public final class FullJitterBackoffStrategy implements BackoffStrategy,
4246
ToCopyableBuilder<FullJitterBackoffStrategy.Builder,
4347
FullJitterBackoffStrategy> {

core/sdk-core/src/main/java/software/amazon/awssdk/core/retry/conditions/RetryCondition.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,17 @@
1515

1616
package software.amazon.awssdk.core.retry.conditions;
1717

18+
import java.util.function.Predicate;
1819
import software.amazon.awssdk.annotations.SdkPublicApi;
1920
import software.amazon.awssdk.core.internal.retry.SdkDefaultRetrySetting;
2021
import software.amazon.awssdk.core.retry.RetryPolicyContext;
2122

23+
/**
24+
* @deprecated Use instead {@link software.amazon.awssdk.retries.api.RetryStrategy.Builder#retryOnException(Predicate)}.
25+
*/
2226
@SdkPublicApi
2327
@FunctionalInterface
28+
@Deprecated
2429
public interface RetryCondition {
2530
/**
2631
* Determine whether a request should or should not be retried.

core/sdk-core/src/test/java/software/amazon/awssdk/core/client/handler/SyncClientHandlerTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@
4242
import software.amazon.awssdk.core.exception.SdkServiceException;
4343
import software.amazon.awssdk.core.http.HttpResponseHandler;
4444
import software.amazon.awssdk.core.protocol.VoidSdkResponse;
45-
import software.amazon.awssdk.core.retry.RetryPolicy;
4645
import software.amazon.awssdk.core.runtime.transform.Marshaller;
4746
import software.amazon.awssdk.core.sync.ResponseTransformer;
4847
import software.amazon.awssdk.http.AbortableInputStream;
@@ -51,6 +50,7 @@
5150
import software.amazon.awssdk.http.SdkHttpClient;
5251
import software.amazon.awssdk.http.SdkHttpFullRequest;
5352
import software.amazon.awssdk.http.SdkHttpResponse;
53+
import software.amazon.awssdk.retries.DefaultRetryStrategy;
5454
import utils.HttpTestUtils;
5555
import utils.ValidSdkObjects;
5656

@@ -205,7 +205,7 @@ private ClientExecutionParams<SdkRequest, SdkResponse> clientExecutionParams() {
205205
public SdkClientConfiguration clientConfiguration() {
206206
return HttpTestUtils.testClientConfiguration().toBuilder()
207207
.option(SdkClientOption.SYNC_HTTP_CLIENT, httpClient)
208-
.option(SdkClientOption.RETRY_POLICY, RetryPolicy.none())
208+
.option(SdkClientOption.RETRY_STRATEGY, DefaultRetryStrategy.none())
209209
.build();
210210
}
211211
}

core/sdk-core/src/test/java/software/amazon/awssdk/core/internal/http/timers/AsyncHttpClientApiCallTimeoutTests.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,12 +47,10 @@
4747
import software.amazon.awssdk.core.interceptor.InterceptorContext;
4848
import software.amazon.awssdk.core.internal.http.AmazonAsyncHttpClient;
4949
import software.amazon.awssdk.core.internal.http.request.SlowExecutionInterceptor;
50-
import software.amazon.awssdk.core.retry.RetryPolicy;
5150
import software.amazon.awssdk.core.signer.NoOpSigner;
5251
import software.amazon.awssdk.http.SdkHttpFullRequest;
5352
import software.amazon.awssdk.metrics.MetricCollector;
5453
import software.amazon.awssdk.retries.DefaultRetryStrategy;
55-
import software.amazon.awssdk.retries.api.RetryStrategy;
5654
import utils.ValidSdkObjects;
5755

5856
public class AsyncHttpClientApiCallTimeoutTests {
@@ -65,7 +63,6 @@ public class AsyncHttpClientApiCallTimeoutTests {
6563
@Before
6664
public void setup() {
6765
httpClient = testAsyncClientBuilder()
68-
.retryPolicy(RetryPolicy.none())
6966
.retryStrategy(DefaultRetryStrategy.none())
7067
.apiCallTimeout(API_CALL_TIMEOUT)
7168
.build();

0 commit comments

Comments
 (0)