mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-09-24 16:03:43 +08:00
add elastic cache purge fix
This commit is contained in:
@@ -18,7 +18,7 @@ func NewElasticcacheManager(regionId string, projectId string, signer auth.Signe
|
||||
Region: regionId,
|
||||
ProjectId: projectId,
|
||||
version: "v1.0",
|
||||
Keyword: "instance",
|
||||
Keyword: "",
|
||||
KeywordPlural: "instances",
|
||||
|
||||
ResourceKeyword: "instances",
|
||||
|
||||
@@ -155,7 +155,13 @@ func (self *SElasticcache) GetVpcId() string {
|
||||
|
||||
func (self *SElasticcache) GetZoneId() string {
|
||||
if len(self.AvailableZones) > 0 {
|
||||
return self.AvailableZones[0]
|
||||
zone, err := self.region.getZoneById(self.AvailableZones[0])
|
||||
if err != nil {
|
||||
log.Errorf("elasticcache.GetZoneId %s", err)
|
||||
return ""
|
||||
}
|
||||
|
||||
return zone.GetGlobalId()
|
||||
}
|
||||
|
||||
return ""
|
||||
|
||||
Reference in New Issue
Block a user