s3: remove retry options for exists check
This commit is contained in:
@@ -65,7 +65,7 @@ function getS3Config(apiConfig, callback) {
|
||||
region: apiConfig.region || 'us-east-1',
|
||||
maxRetries: 10,
|
||||
retryDelayOptions: {
|
||||
customBackoff: () => 20000 // constant backoff - https://docs.aws.amazon.com/AWSJavaScriptSDK/latest/AWS/Config.html#retryDelayOptions-property
|
||||
customBackoff: (/* retryCount, error */) => 20000 // constant backoff - https://docs.aws.amazon.com/AWSJavaScriptSDK/latest/AWS/Config.html#retryDelayOptions-property
|
||||
},
|
||||
httpOptions: {
|
||||
connectTimeout: 60000, // https://github.com/aws/aws-sdk-js/pull/1446
|
||||
@@ -146,7 +146,7 @@ function exists(apiConfig, backupFilePath, callback) {
|
||||
getS3Config(apiConfig, function (error, credentials) {
|
||||
if (error) return callback(error);
|
||||
|
||||
const s3 = new AWS.S3(credentials);
|
||||
const s3 = new AWS.S3(_.omit(credentials, 'retryDelayOptions', 'maxRetries'));
|
||||
|
||||
if (!backupFilePath.endsWith('/')) { // check for file
|
||||
const params = {
|
||||
|
||||
Reference in New Issue
Block a user