fix too many requests error for upload

This commit is contained in:
xiaoyaofenfen 2022-12-06 19:48:31 +08:00
parent a1577f19c5
commit 98de5b931c

View File

@ -431,6 +431,11 @@ StepUploadPrepareUpload:
if apierr != nil {
result.Err = apierr
result.ResultMessage = "创建上传任务失败:" + apierr.Error()
if apierr.Code == apierror.ApiCodeTooManyRequests || apierr.Code == apierror.ApiCodeBadGateway {
logger.Verboseln("create upload file error: " + result.ResultMessage)
// 重试
result.NeedRetry = true
}
return
}