Replacement _ on _LW in all LOG.warning part 2

oslo.i18n uses different marker functions to separate the
translatable messages into different catalogs, which the translation
teams can prioritize translating. For details, please refer to:
http://docs.openstack.org/developer/oslo.i18n/guidelines.html#guidelines-for-use-in-openstack

There were not marker fuctions some places in directory network.
This commit makes changes:
* Add missing marker functions
* Use ',' instead of '%' while adding variables to log messages

Change-Id: I5ab13610d3e10a68ae49f9fd7fac151aa66ea98d
This commit is contained in:
Mike Durnosvistov
2014-11-19 17:55:18 +02:00
parent e8c0b822f0
commit b4ee0d16ae
20 changed files with 154 additions and 146 deletions

View File

@@ -70,7 +70,7 @@ def pipeline_factory(loader, global_conf, **local_conf):
# If the configuration file still contains 'ratelimit_v3', just ignore it.
# We will remove this code at next release (J)
if 'ratelimit_v3' in pipeline:
LOG.warn(_LW('ratelimit_v3 is removed from v3 api.'))
LOG.warning(_LW('ratelimit_v3 is removed from v3 api.'))
pipeline.remove('ratelimit_v3')
return _load_pipeline(loader, pipeline)
@@ -161,6 +161,6 @@ class NovaKeystoneContext(wsgi.Middleware):
# Fallback to deprecated role header:
roles = req.headers.get('X_ROLE', '')
if roles:
LOG.warn(_LW("Sourcing roles from deprecated X-Role HTTP "
"header"))
LOG.warning(_LW("Sourcing roles from deprecated X-Role HTTP "
"header"))
return [r.strip() for r in roles.split(',')]