Merge pull request #3571 from ioito/hotfix/qx-dbinstance-retry

fix: 赋予rds账号权限失败后进行重试
This commit is contained in:
yunion-ci-robot
2019-11-12 00:57:20 +08:00
committed by GitHub
+7 -1
View File
@@ -100,7 +100,13 @@ func jsonRequest(client *sdk.Client, domain, apiVersion, apiName string, params
return nil, cloudprovider.ErrNotFound
}
}
for _, code := range []string{"SignatureNonceUsed", "InvalidInstance.NotSupported", "try later", "BackendServer.configuring"} {
for _, code := range []string{
"SignatureNonceUsed",
"InvalidInstance.NotSupported",
"try later",
"BackendServer.configuring",
"Another operation is being performed", //Another operation is being performed on the DB instance or the DB instance is faulty(赋予RDS账号权限)
} {
if strings.Contains(err.Error(), code) {
retry = true
break