summaryrefslogtreecommitdiff
path: root/nova/volume
diff options
context:
space:
mode:
authorStephen Finucane <stephenfin@redhat.com>2020-05-18 16:51:14 +0100
committerStephen Finucane <stephenfin@redhat.com>2020-05-18 16:52:20 +0100
commiteee57f2380518131338dbff3d63803e15b68e7fa (patch)
tree25b9884d148174e37d0998692baf40346e27a57c /nova/volume
parentb8fe7fac846d441f133088c35086f46896875d71 (diff)
downloadnova-eee57f2380518131338dbff3d63803e15b68e7fa.tar.gz
trivial: Remove remaining '_LE' instances
We've been slowly removing these as we go. Remove the final few '_LE' occurrences now. Change-Id: I75ebd2e95a0c77585d7b4329ca01e4bacc1dd7c4 Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
Diffstat (limited to 'nova/volume')
-rw-r--r--nova/volume/cinder.py38
1 files changed, 18 insertions, 20 deletions
diff --git a/nova/volume/cinder.py b/nova/volume/cinder.py
index 2c6c936f0d..3c384e35ee 100644
--- a/nova/volume/cinder.py
+++ b/nova/volume/cinder.py
@@ -42,7 +42,6 @@ from nova import availability_zones as az
import nova.conf
from nova import exception
from nova.i18n import _
-from nova.i18n import _LE
from nova.i18n import _LW
from nova import service_auth
@@ -610,28 +609,27 @@ class API(object):
return connection_info
except cinder_exception.ClientException as ex:
with excutils.save_and_reraise_exception():
- LOG.error(_LE('Initialize connection failed for volume '
- '%(vol)s on host %(host)s. Error: %(msg)s '
- 'Code: %(code)s. Attempting to terminate '
- 'connection.'),
- {'vol': volume_id,
- 'host': connector.get('host'),
- 'msg': six.text_type(ex),
- 'code': ex.code})
+ LOG.error(
+ 'Initialize connection failed for volume %(vol)s on host '
+ '%(host)s. Error: %(msg)s Code: %(code)s. '
+ 'Attempting to terminate connection.',
+ {'vol': volume_id,
+ 'host': connector.get('host'),
+ 'msg': six.text_type(ex),
+ 'code': ex.code})
try:
self.terminate_connection(context, volume_id, connector)
except Exception as exc:
- LOG.error(_LE('Connection between volume %(vol)s and host '
- '%(host)s might have succeeded, but attempt '
- 'to terminate connection has failed. '
- 'Validate the connection and determine if '
- 'manual cleanup is needed. Error: %(msg)s '
- 'Code: %(code)s.'),
- {'vol': volume_id,
- 'host': connector.get('host'),
- 'msg': six.text_type(exc),
- 'code': (
- exc.code if hasattr(exc, 'code') else None)})
+ LOG.error(
+ 'Connection between volume %(vol)s and host %(host)s '
+ 'might have succeeded, but attempt to terminate '
+ 'connection has failed. Validate the connection and '
+ 'determine if manual cleanup is needed. '
+ 'Error: %(msg)s Code: %(code)s.',
+ {'vol': volume_id,
+ 'host': connector.get('host'),
+ 'msg': six.text_type(exc),
+ 'code': exc.code if hasattr(exc, 'code') else None})
@translate_volume_exception
@retrying.retry(stop_max_attempt_number=5,