diff options
author | jichenjc <jichenjc@cn.ibm.com> | 2014-04-22 14:20:02 +0800 |
---|---|---|
committer | jichenjc <jichenjc@cn.ibm.com> | 2014-05-31 11:22:53 +0800 |
commit | cbdd56da309ab0b610ed1f383f11bea26fa7b8c0 (patch) | |
tree | de72d4e474c10b3a0f69ea61ec6f14baff59f3d3 /neutronclient/common/exceptions.py | |
parent | f6eba87aa1761de2425d4651a62e3d07d88de3fe (diff) | |
download | python-neutronclient-cbdd56da309ab0b610ed1f383f11bea26fa7b8c0.tar.gz |
Add OverQuotaClient as exception to neutronclient
In nova, there is no way to explictly knows whether the neutron
fails due to over quota or no more floating ips and fixed ips.
so nova need to check whether the return value is 409 in order to
raise an over quota exception. It's easier in neutronclient to
raise the exception then nova will handle it.
Related-Bug: #1210598
Change-Id: I8788993578ac872da9f676fe3e2fb8f98414289d
Diffstat (limited to 'neutronclient/common/exceptions.py')
-rw-r--r-- | neutronclient/common/exceptions.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/neutronclient/common/exceptions.py b/neutronclient/common/exceptions.py index f4085d3..65f1c26 100644 --- a/neutronclient/common/exceptions.py +++ b/neutronclient/common/exceptions.py @@ -139,6 +139,10 @@ class IpAddressInUseClient(Conflict): pass +class OverQuotaClient(Conflict): + pass + + # TODO(amotoki): It is unused in Neutron, but it is referred to # in Horizon code. After Horizon code is updated, remove it. class AlreadyAttachedClient(Conflict): |