move lb from zonequota to regionquota

This commit is contained in:
Qiu Jian
2020-01-03 13:58:04 +08:00
parent bc7f62a2ad
commit 82f4885b3b
+3
View File
@@ -348,6 +348,9 @@ func (self *SRegionQuota) Allocable(request quotas.IQuota) int {
if self.Cache >= 0 && squota.Cache > 0 && (cnt < 0 || cnt > self.Cache/squota.Cache) {
cnt = self.Cache / squota.Cache
}
if self.Loadbalancer >= 0 && squota.Loadbalancer > 0 && (cnt < 0 || cnt > self.Loadbalancer/squota.Loadbalancer) {
cnt = self.Loadbalancer / squota.Loadbalancer
}
return cnt
}