Add exception for communicate with glare api
Murano dashboard crashes if glare is down. It should act similarly as the situations when murano-api is down, show horizon's error message that it was impossible to communicate with glare api. Change-Id: I29687d45d4b6da6ef27bf09bee537efec3bacdeb Closes-Bug: #1595494
This commit is contained in:
parent
2960fff216
commit
1c18762ba1
@ -18,6 +18,7 @@ from django.conf import settings
|
||||
from django.contrib.messages import api as msg_api
|
||||
from django.utils.encoding import force_text
|
||||
from django.utils.translation import ugettext_lazy as _
|
||||
from glanceclient.common import exceptions as glance_exc
|
||||
from horizon import exceptions
|
||||
import muranoclient.client as client
|
||||
from muranoclient.common import exceptions as exc
|
||||
@ -59,6 +60,10 @@ def handled_exceptions(request):
|
||||
msg = _('Unable to communicate to murano-api server.')
|
||||
LOG.exception(msg)
|
||||
_handle_message(request, msg)
|
||||
except glance_exc.CommunicationError:
|
||||
msg = _('Unable to communicate to glare-api server.')
|
||||
LOG.exception(msg)
|
||||
_handle_message(request, msg)
|
||||
except exc.HTTPUnauthorized:
|
||||
msg = _('Check Keystone configuration of murano-api server.')
|
||||
LOG.exception(msg)
|
||||
|
Loading…
Reference in New Issue
Block a user