Merge pull request #11783 from ioito/hotfix/qx-mongodb-fix

fix(region): mongodb sync fix
This commit is contained in:
Zexi Li
2021-08-04 10:23:41 +08:00
committed by GitHub
+8
View File
@@ -252,6 +252,14 @@ func (self *SRegion) GetMongoDBsByType(mongoType string) ([]SMongoDB, error) {
return dbs, nil
}
func (self *SRegion) GetICloudMongoDBById(id string) (cloudprovider.ICloudMongoDB, error) {
db, err := self.GetMongoDB(id)
if err != nil {
return nil, errors.Wrapf(err, "GetMongoDB(%s)", id)
}
return db, nil
}
func (self *SRegion) GetICloudMongoDBs() ([]cloudprovider.ICloudMongoDB, error) {
dbs := []SMongoDB{}
for _, mongoType := range []string{"sharding", "replicate", "serverless"} {