From 99d692daab239019908e5a7a369e554f2b7acdfc Mon Sep 17 00:00:00 2001 From: Andrew Laski Date: Thu, 8 Sep 2016 12:34:06 -0400 Subject: [PATCH] Remove misleading warning message There is a warning log while retrieving an instance which is true if a deployment has migrated to cellsv2, but is misleading and noisy if not on cellsv2 yet. For now it's best to remove it. Change-Id: I3bee1202b20a80de3d54b25f6f7ea4215dcfe762 --- nova/compute/api.py | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/nova/compute/api.py b/nova/compute/api.py index f323544d9bfb..0a05b91ba299 100644 --- a/nova/compute/api.py +++ b/nova/compute/api.py @@ -2185,12 +2185,13 @@ class API(base.Base): instance = objects.Instance.get_by_uuid( context, instance_uuid, expected_attrs=expected_attrs) else: - # This should not happen if we made it past the service_version - # check above. But it does not need to be an exception yet. - LOG.warning(_LW('No instance_mapping found for instance %s. This ' - 'should not be happening and will lead to errors ' - 'in the future. Please open a bug at ' - 'https://bugs.launchpad.net/nova'), instance_uuid) + # This should not happen once a deployment has migrated to cellsv2. + # If it happens after that point we handle it gracefully for now + # but this will become an exception in the future. + # TODO(alaski): Once devstack is setting up cellsv2 by default add + # a warning log message that this will become an exception in the + # future. The warning message will be conditional upon the + # migration having happened, which means a db lookup to check that. instance = objects.Instance.get_by_uuid( context, instance_uuid, expected_attrs=expected_attrs)