Merge "Replace LOG.warn with LOG.warning"

This commit is contained in:
Jenkins 2016-12-13 09:09:23 +00:00 committed by Gerrit Code Review
commit 49ad7b6197
3 changed files with 7 additions and 7 deletions

View File

@ -143,7 +143,7 @@ class RoleMiddleware(om.ConfigurableMiddleware):
roles = headers.get(_X_ROLES)
if not roles:
LOG.warn('Couldn\'t locate %s header, or it was empty', _X_ROLES)
LOG.warning('Couldn\'t locate %s header,or it was empty', _X_ROLES)
return False, False
else:
roles = _ensure_lower_roles(roles.split(','))

View File

@ -85,8 +85,8 @@ def get_client(dimensions=None):
if key not in _DEFAULT_DIMENSIONS:
dims[key] = val
else:
LOG.warn('Cannot override fixed dimension %s=%s', key,
_DEFAULT_DIMENSIONS[key])
LOG.warning('Cannot override fixed dimension %s=%s', key,
_DEFAULT_DIMENSIONS[key])
connection = monascastatsd.Connection(
host=CONF.monitoring.statsd_host,

View File

@ -195,10 +195,10 @@ class LogPublisher(object):
if diff_size > 1:
truncated_by = diff_size + _TRUNCATED_PROPERTY_SIZE
LOG.warn(('Detected message that exceeds %d bytes,'
'message will be truncated by %d bytes'),
self.max_message_size,
truncated_by)
LOG.warning(('Detected message that exceeds %d bytes,'
'message will be truncated by %d bytes'),
self.max_message_size,
truncated_by)
log_msg = envelope['log']['message']
truncated_log_msg = log_msg[:-truncated_by]