File tree Expand file tree Collapse file tree 2 files changed +5
-1
lines changed Expand file tree Collapse file tree 2 files changed +5
-1
lines changed Original file line number Diff line number Diff line change 11{
22 "name" : " cos-nodejs-sdk-v5" ,
3- "version" : " 2.14.3 " ,
3+ "version" : " 2.14.4 " ,
44 "description" : " cos nodejs sdk v5" ,
55 "main" : " index.js" ,
66 "types" : " index.d.ts" ,
Original file line number Diff line number Diff line change @@ -4034,6 +4034,7 @@ function submitRequest(params, callback) {
40344034 networkError,
40354035 } ) ;
40364036 params . SwitchHost = switchHost ;
4037+ params . retry = true ;
40374038 next ( tryTimes + 1 ) ;
40384039 } else {
40394040 if ( err && params . Action === 'name/cos:UploadPart' ) {
@@ -4127,6 +4128,9 @@ function _submitRequest(params, callback) {
41274128
41284129 // 清理 undefined 和 null 字段
41294130 opt . headers && ( opt . headers = util . clearKey ( opt . headers ) ) ;
4131+ if ( params . retry ) {
4132+ opt . headers [ 'x-cos-sdk-retry' ] = true ;
4133+ }
41304134 opt = util . clearKey ( opt ) ;
41314135
41324136 var Ip = this . options . Ip ;
You can’t perform that action at this time.
0 commit comments