File tree Expand file tree Collapse file tree 1 file changed +2
-6
lines changed Expand file tree Collapse file tree 1 file changed +2
-6
lines changed Original file line number Diff line number Diff line change @@ -22,16 +22,12 @@ const client = new S3Client({}); // default retry strategy included.
2222
2323### MaxAttempts
2424
25- If you want to change the number of attempts, you can use the ` StandardRetryStrategy ` from ` @aws-sdk/util-retry ` .
25+ If you want to change the number of attempts, you can provide ` maxAttempts ` configuration during client creation .
2626
2727``` js
2828import { S3Client } from " @aws-sdk/client-s3" ;
29- import { StandardRetryStrategy } from " @aws-sdk/util-retry" ;
3029
31- const client = new S3Client ({
32- // custom max number of attempts.
33- retryStrategy: new StandardRetryStrategy (4 ),
34- });
30+ const client = new S3Client ({ maxAttempts: 4 });
3531```
3632
3733This is recommended because the ` StandardRetryStrategy ` includes backoff calculation,
You can’t perform that action at this time.
0 commit comments