From 4801c0f894b5e58e9b5bf46de31d1de271390eb9 Mon Sep 17 00:00:00 2001 From: Tetiana Lashchova Date: Tue, 2 Dec 2014 13:35:38 +0200 Subject: Use the right log marker functions According to [1] _LI() should be used for LOG.info(), _LE() for LOG.exception() and LOG.error(), _LW() for LOG.warning(). The log marker functions must only be used when the message is sent directly to the log. Debug level log messages should not be translated. [1] http://docs.openstack.org/developer/oslo.i18n/guidelines.html Change-Id: Ib9f92ef6696b9a95ddae74f0d4a0a557c06ecc91 --- bin/heat-api | 4 ++-- bin/heat-api-cfn | 4 ++-- bin/heat-api-cloudwatch | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) (limited to 'bin') diff --git a/bin/heat-api b/bin/heat-api index 7444f666c..77f11f8c5 100755 --- a/bin/heat-api +++ b/bin/heat-api @@ -35,7 +35,7 @@ from oslo.config import cfg from oslo import i18n from heat.common import config -from heat.common.i18n import _ +from heat.common.i18n import _LI from heat.common import messaging from heat.common import profiler from heat.common import wsgi @@ -56,7 +56,7 @@ if __name__ == '__main__': port = cfg.CONF.heat_api.bind_port host = cfg.CONF.heat_api.bind_host - LOG.info(_('Starting Heat ReST API on %(host)s:%(port)s'), + LOG.info(_LI('Starting Heat ReST API on %(host)s:%(port)s'), {'host': host, 'port': port}) profiler.setup('heat-api', host) server = wsgi.Server() diff --git a/bin/heat-api-cfn b/bin/heat-api-cfn index b21080777..2d1038bc2 100755 --- a/bin/heat-api-cfn +++ b/bin/heat-api-cfn @@ -37,7 +37,7 @@ from oslo.config import cfg from oslo import i18n from heat.common import config -from heat.common.i18n import _ +from heat.common.i18n import _LI from heat.common import messaging from heat.common import profiler from heat.common import wsgi @@ -58,7 +58,7 @@ if __name__ == '__main__': port = cfg.CONF.heat_api_cfn.bind_port host = cfg.CONF.heat_api_cfn.bind_host - LOG.info(_('Starting Heat API on %(host)s:%(port)s'), + LOG.info(_LI('Starting Heat API on %(host)s:%(port)s'), {'host': host, 'port': port}) profiler.setup('heat-api-cfn', host) server = wsgi.Server() diff --git a/bin/heat-api-cloudwatch b/bin/heat-api-cloudwatch index fea213bc2..0cecfffbd 100755 --- a/bin/heat-api-cloudwatch +++ b/bin/heat-api-cloudwatch @@ -37,7 +37,7 @@ from oslo.config import cfg from oslo import i18n from heat.common import config -from heat.common.i18n import _ +from heat.common.i18n import _LI from heat.common import messaging from heat.common import profiler from heat.common import wsgi @@ -58,7 +58,7 @@ if __name__ == '__main__': port = cfg.CONF.heat_api_cloudwatch.bind_port host = cfg.CONF.heat_api_cloudwatch.bind_host - LOG.info(_('Starting Heat CloudWatch API on %(host)s:%(port)s'), + LOG.info(_LI('Starting Heat CloudWatch API on %(host)s:%(port)s'), {'host': host, 'port': port}) profiler.setup('heat-api-cloudwatch', host) server = wsgi.Server() -- cgit v1.2.1