This repository was archived by the owner on Jan 28, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 8 files changed +41
-7
lines changed Expand file tree Collapse file tree 8 files changed +41
-7
lines changed Original file line number Diff line number Diff line change @@ -29,6 +29,13 @@ export type Credentials = {
29
29
export default ( {
30
30
credentials
31
31
} : CloudFrontClientFactoryOptions ) : CloudFrontClient => {
32
+ if ( AWS ?. config ) {
33
+ AWS . config . update ( {
34
+ maxRetries : parseInt ( process . env . SLS_NEXT_MAX_RETRIES ?? "10" ) ,
35
+ retryDelayOptions : { base : 200 }
36
+ } ) ;
37
+ }
38
+
32
39
const cloudFront = new AWS . CloudFront ( { credentials } ) ;
33
40
34
41
return {
Original file line number Diff line number Diff line change 75
75
"node-fetch" : " ^2.6.1" ,
76
76
"path-to-regexp" : " ^6.1.0" ,
77
77
"send" : " ^0.17.1"
78
+ },
79
+ "peerDependencies" : {
80
+ "builtin-modules" : " ^3.2.0"
78
81
}
79
82
}
Original file line number Diff line number Diff line change 1124
1124
picomatch "^2.2.2"
1125
1125
1126
1126
" @sls-next/core@link:../core " :
1127
- version "3.1.0-alpha.14"
1128
- dependencies :
1129
- " @hapi/accept" " ^5.0.1"
1130
- cookie "^0.4.1"
1131
- jsonwebtoken "^8.5.1"
1132
- path-to-regexp "^6.1.0"
1133
- regex-parser "^2.2.10"
1127
+ version "0.0.0"
1128
+ uid ""
1134
1129
1135
1130
" @tsconfig/node10@^1.0.7 " :
1136
1131
version "1.0.8"
Original file line number Diff line number Diff line change 21
21
"ramda" : " ^0.27.1"
22
22
},
23
23
"peerDependencies" : {
24
+ "@babel/core" : " 7.14.6" ,
24
25
"@serverless/core" : " ^1.1.2" ,
25
26
"aws-sdk" : " ^2.935.0"
26
27
},
Original file line number Diff line number Diff line change @@ -42,6 +42,13 @@ class CloudFront extends Component {
42
42
`Starting deployment of CloudFront distribution to the ${ inputs . region } region.`
43
43
) ;
44
44
45
+ if ( AWS ?. config ) {
46
+ AWS . config . update ( {
47
+ maxRetries : parseInt ( process . env . SLS_NEXT_MAX_RETRIES ?? "10" ) ,
48
+ retryDelayOptions : { base : 200 }
49
+ } ) ;
50
+ }
51
+
45
52
const cf = new AWS . CloudFront ( {
46
53
credentials : this . context . credentials . aws ,
47
54
region : inputs . region
Original file line number Diff line number Diff line change @@ -62,6 +62,13 @@ class AwsLambda extends Component {
62
62
`Starting deployment of lambda ${ config . name } to the ${ config . region } region.`
63
63
) ;
64
64
65
+ if ( AWS ?. config ) {
66
+ AWS . config . update ( {
67
+ maxRetries : parseInt ( process . env . SLS_NEXT_MAX_RETRIES ?? "10" ) ,
68
+ retryDelayOptions : { base : 200 }
69
+ } ) ;
70
+ }
71
+
65
72
const lambda = new AwsSdkLambda ( {
66
73
region : config . region ,
67
74
credentials : this . context . credentials . aws
Original file line number Diff line number Diff line change @@ -24,6 +24,13 @@ class AwsSqsQueue extends Component {
24
24
const config = mergeDeepRight ( getDefaults ( { defaults } ) , inputs ) ;
25
25
const accountId = await getAccountId ( aws ) ;
26
26
27
+ if ( aws && aws . config ) {
28
+ aws . config . update ( {
29
+ maxRetries : parseInt ( process . env . SLS_NEXT_MAX_RETRIES || "10" ) ,
30
+ retryDelayOptions : { base : 200 }
31
+ } ) ;
32
+ }
33
+
27
34
const arn = getArn ( {
28
35
aws,
29
36
accountId,
Original file line number Diff line number Diff line change @@ -9,6 +9,13 @@ const HOSTED_ZONE_ID = "Z2FDTNDATAQYW2"; // this is a constant that you can get
9
9
* - Gets AWS SDK clients to use within this Component
10
10
*/
11
11
const getClients = ( credentials , region = "us-east-1" ) => {
12
+ if ( aws && aws . config ) {
13
+ aws . config . update ( {
14
+ maxRetries : parseInt ( process . env . SLS_NEXT_MAX_RETRIES || "10" ) ,
15
+ retryDelayOptions : { base : 200 }
16
+ } ) ;
17
+ }
18
+
12
19
const route53 = new aws . Route53 ( {
13
20
credentials,
14
21
region
You can’t perform that action at this time.
0 commit comments