Check the project zone quota when accepting zone transfer.
Change-Id: I3cb6cf8c804f008244e34968101f7343be192d48 Closes-Bug: 1789876
This commit is contained in:
parent
f6a7ea7d47
commit
709b272354
|
@ -2564,6 +2564,10 @@ class Service(service.RPCService, service.Service):
|
|||
if zone.action == 'DELETE':
|
||||
raise exceptions.BadRequest('Can not transfer a deleting zone')
|
||||
|
||||
# Ensure the accepting tenant has enough quota to continue
|
||||
self._enforce_zone_quota(context,
|
||||
zone_transfer_accept.tenant_id)
|
||||
|
||||
zone.tenant_id = zone_transfer_accept.tenant_id
|
||||
self.storage.update_zone(elevated_context, zone)
|
||||
|
||||
|
|
Loading…
Reference in New Issue