File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " @kentico/kontent-cli" ,
3
- "version" : " 0.0.4 " ,
3
+ "version" : " 0.0.5 " ,
4
4
"description" : " Command line interface tool that can be used for generating and running Kontent migration scripts" ,
5
5
"main" : " ./lib/index.js" ,
6
6
"types" : " ./lib/types/index.d.ts" ,
44
44
},
45
45
"homepage" : " https://github.com/Kentico/kontent-migrations-boilerplate#readme" ,
46
46
"dependencies" : {
47
- "@kentico/kontent-management" : " 0.3.13" ,
48
47
"chalk" : " ^2.4.2" ,
49
- "yargs" : " ^14.2.0"
48
+ "yargs" : " ^14.2.0" ,
49
+ "@kentico/kontent-management" : " ~0.3.17"
50
50
},
51
51
"peerDependencies" : {
52
52
"rxjs" : " ^6.5.3"
Original file line number Diff line number Diff line change @@ -10,6 +10,8 @@ interface ICreateManagementClientParams {
10
10
readonly debugMode : boolean ;
11
11
}
12
12
13
+ const retryAbleCodes = [ 429 , 503 ] ;
14
+
13
15
dotEnv . config ( ) ;
14
16
15
17
export const createManagementClient = ( params : ICreateManagementClientParams ) : ManagementClient => {
@@ -49,7 +51,7 @@ export const createManagementClient = (params: ICreateManagementClientParams): M
49
51
maxCumulativeWaitTimeMs : 60000 ,
50
52
maxAttempts : 10 ,
51
53
canRetryError : ( error : any ) => {
52
- return true ;
54
+ return retryAbleCodes . includes ( error . response . status ) ;
53
55
}
54
56
}
55
57
} ) ;
You can’t perform that action at this time.
0 commit comments