summaryrefslogtreecommitdiff
path: root/nova
diff options
context:
space:
mode:
authorSylvain Bauza <sbauza@redhat.com>2023-02-14 17:21:30 +0000
committerSylvain Bauza <sbauza@redhat.com>2023-02-14 17:21:30 +0000
commitcbed39822a6dc62efc2a25e5b408d30ff7572542 (patch)
tree1efa04278db7186dd5fc1ffe7512ebafb5b7275f /nova
parent1778a9c589cf24e17b44f556680b17af9577df11 (diff)
downloadnova-cbed39822a6dc62efc2a25e5b408d30ff7572542.tar.gz
Revert "Add logging to find test cases leaking libvirt threads"
This reverts commit 1778a9c589cf24e17b44f556680b17af9577df11. Reason for revert: We said we wouldn't have it in RC1. Change-Id: Idf0c9a8adeac231f099b312fc24b9cf9726687e0
Diffstat (limited to 'nova')
-rw-r--r--nova/tests/fixtures/nova.py26
-rw-r--r--nova/virt/libvirt/driver.py18
2 files changed, 0 insertions, 44 deletions
diff --git a/nova/tests/fixtures/nova.py b/nova/tests/fixtures/nova.py
index 9a652c02cb..5fd893e7dc 100644
--- a/nova/tests/fixtures/nova.py
+++ b/nova/tests/fixtures/nova.py
@@ -1822,24 +1822,6 @@ class ImportModulePoisonFixture(fixtures.Fixture):
def find_spec(self, fullname, path, target=None):
if fullname in self.modules:
- current = eventlet.getcurrent()
- # NOTE(gibi) not all eventlet spawn is under our control, so
- # there can be senders without test_case_id set, find the first
- # ancestor that was spawned from nova.utils.spawn[_n] and
- # therefore has the id set.
- while (
- current is not None and
- not getattr(current, 'test_case_id', None)
- ):
- current = current.parent
-
- if current is not None:
- self.test.tc_id = current.test_case_id
- LOG.warning(
- "!!!---!!! TestCase ID %s hit the import poison while "
- "importing %s. If you see this in a failed functional "
- "test then please let #openstack-nova on IRC know "
- "about it. !!!---!!!", current.test_case_id, fullname)
self.test.fail_message = (
f"This test imports the '{fullname}' module, which it "
f'should not in the test environment. Please add '
@@ -1850,7 +1832,6 @@ class ImportModulePoisonFixture(fixtures.Fixture):
def __init__(self, module_names):
self.module_names = module_names
self.fail_message = ''
- self.tc_id = None
if isinstance(module_names, str):
self.module_names = {module_names}
self.meta_path_finder = self.ForbiddenModules(self, self.module_names)
@@ -1868,13 +1849,6 @@ class ImportModulePoisonFixture(fixtures.Fixture):
# there (which is also what self.assert* and self.fail() do underneath)
# will not work to cause a failure in the test.
if self.fail_message:
- if self.tc_id is not None:
- LOG.warning(
- "!!!---!!! TestCase ID %s hit the import poison. If you "
- "see this in a failed functional test then please let "
- "#openstack-nova on IRC know about it. !!!---!!!",
- self.tc_id
- )
raise ImportError(self.fail_message)
diff --git a/nova/virt/libvirt/driver.py b/nova/virt/libvirt/driver.py
index 5b0fa799c3..542383cbad 100644
--- a/nova/virt/libvirt/driver.py
+++ b/nova/virt/libvirt/driver.py
@@ -10061,24 +10061,6 @@ class LibvirtDriver(driver.ComputeDriver):
:param instance: instance object that is in migration
"""
- current = eventlet.getcurrent()
- # NOTE(gibi) not all eventlet spawn is under our control, so
- # there can be senders without test_case_id set, find the first
- # ancestor that was spawned from nova.utils.spawn[_n] and
- # therefore has the id set.
- while (
- current is not None and
- not getattr(current, 'test_case_id', None)
- ):
- current = current.parent
-
- if current is not None:
- LOG.warning(
- "!!!---!!! live_migration_abort thread was spawned by "
- "TestCase ID: %s. If you see this in a failed functional test "
- "then please let #openstack-nova on IRC know about it. "
- "!!!---!!!", current.test_case_id
- )
guest = self._host.get_guest(instance)
dom = guest._domain