From 7f17eae68ecf465135a8627cb15791f02f1c782c Mon Sep 17 00:00:00 2001 From: Gary Kotton Date: Sun, 1 Nov 2015 04:48:36 -0800 Subject: [PATCH] Claims: fix log message Add log hint to info message. In addition to this follow the logging convention of using a , instead of a %. TrivialFix Change-Id: Ie9992835420aacf65b0962b51581e0e05c5bac72 --- nova/compute/claims.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/nova/compute/claims.py b/nova/compute/claims.py index 3e4ffb0357..60ef76e739 100644 --- a/nova/compute/claims.py +++ b/nova/compute/claims.py @@ -140,11 +140,10 @@ class Claim(NopClaim): vcpus_limit = limits.get('vcpu') numa_topology_limit = limits.get('numa_topology') - msg = _("Attempting claim: memory %(memory_mb)d MB, " - "disk %(disk_gb)d GB, vcpus %(vcpus)d CPU") - params = {'memory_mb': self.memory_mb, 'disk_gb': self.disk_gb, - 'vcpus': self.vcpus} - LOG.info(msg % params, instance=self.instance) + LOG.info(_LI("Attempting claim: memory %(memory_mb)d MB, " + "disk %(disk_gb)d GB, vcpus %(vcpus)d CPU"), + {'memory_mb': self.memory_mb, 'disk_gb': self.disk_gb, + 'vcpus': self.vcpus}, instance=self.instance) reasons = [self._test_memory(resources, memory_mb_limit), self._test_disk(resources, disk_gb_limit),