summaryrefslogtreecommitdiff
path: root/openstack_dashboard/exceptions.py
diff options
context:
space:
mode:
authorGabriel Hurley <gabriel@strikeawe.com>2012-08-13 18:28:42 -0700
committerGabriel Hurley <gabriel@strikeawe.com>2012-08-14 14:50:15 -0700
commit0cd51d5c2814cf01ee31072fa3b68dc13f450212 (patch)
tree17613347af5d4693658f8cdf41cc7364d985698c /openstack_dashboard/exceptions.py
parentacb0516548f3e07541ec582bae9e2cac7fb465a6 (diff)
downloadhorizon-0cd51d5c2814cf01ee31072fa3b68dc13f450212.tar.gz
Switch to using cinderclient.
This is practically a transparent switch since it was copied out of novaclient and maintains API compatibility. NOTE: this will fail until python-cinderclient is published to PyPI properly. Implements blueprint switch-to-cinder-client Change-Id: Ic8cd6660735e172ff5d3402952265a15dc15f9e5
Diffstat (limited to 'openstack_dashboard/exceptions.py')
-rw-r--r--openstack_dashboard/exceptions.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/openstack_dashboard/exceptions.py b/openstack_dashboard/exceptions.py
index c025aeb34..8801fc982 100644
--- a/openstack_dashboard/exceptions.py
+++ b/openstack_dashboard/exceptions.py
@@ -18,6 +18,7 @@
# License for the specific language governing permissions and limitations
# under the License.
+from cinderclient import exceptions as cinderclient
from glanceclient.common import exceptions as glanceclient
from keystoneclient import exceptions as keystoneclient
from novaclient import exceptions as novaclient
@@ -27,6 +28,8 @@ from swiftclient import client as swiftclient
UNAUTHORIZED = (keystoneclient.Unauthorized,
keystoneclient.Forbidden,
+ cinderclient.Unauthorized,
+ cinderclient.Forbidden,
novaclient.Unauthorized,
novaclient.Forbidden,
glanceclient.Unauthorized,
@@ -34,6 +37,7 @@ UNAUTHORIZED = (keystoneclient.Unauthorized,
quantumclient.Forbidden)
NOT_FOUND = (keystoneclient.NotFound,
+ cinderclient.NotFound,
novaclient.NotFound,
glanceclient.NotFound,
quantumclient.NetworkNotFoundClient,
@@ -43,6 +47,7 @@ NOT_FOUND = (keystoneclient.NotFound,
RECOVERABLE = (keystoneclient.ClientException,
# AuthorizationFailure is raised when Keystone is "unavailable".
keystoneclient.AuthorizationFailure,
+ cinderclient.ClientException,
novaclient.ClientException,
glanceclient.ClientException,
# NOTE(amotoki): Quantum exceptions other than the first one