Change in vdsm[master]: vm: renaming device unplug related function
Marcin Mirecki has abandoned this change. Change subject: vm: renaming device unplug related function .. Abandoned Squashed into https://gerrit.ovirt.org/#/c/48473 -- To view, visit https://gerrit.ovirt.org/49038 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: abandon Gerrit-Change-Id: I3ab2b22e2a79507cde77addf28f29b80bde9e24d Gerrit-PatchSet: 5 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Marcin Mirecki Gerrit-Reviewer: Francesco Romani Gerrit-Reviewer: Ido Barkan Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: vm: renaming device unplug related function
gerrit-hooks has posted comments on this change. Change subject: vm: renaming device unplug related function .. Patch Set 5: * Update tracker: IGNORE, no Bug-Url found -- To view, visit https://gerrit.ovirt.org/49038 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I3ab2b22e2a79507cde77addf28f29b80bde9e24d Gerrit-PatchSet: 5 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Marcin Mirecki Gerrit-Reviewer: Francesco Romani Gerrit-Reviewer: Ido Barkan Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: vm: renaming device unplug related function
Nir Soffer has posted comments on this change. Change subject: vm: renaming device unplug related function .. Patch Set 5: This was squashed into another patch, you can abandon it now. -- To view, visit https://gerrit.ovirt.org/49038 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I3ab2b22e2a79507cde77addf28f29b80bde9e24d Gerrit-PatchSet: 5 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Marcin Mirecki Gerrit-Reviewer: Francesco Romani Gerrit-Reviewer: Ido Barkan Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: vm: renaming device unplug related function
Nir Soffer has posted comments on this change. Change subject: vm: renaming device unplug related function .. Patch Set 5: Code-Review-1 This rename belongs to https://gerrit.ovirt.org/48473 -- To view, visit https://gerrit.ovirt.org/49038 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I3ab2b22e2a79507cde77addf28f29b80bde9e24d Gerrit-PatchSet: 5 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Marcin Mirecki Gerrit-Reviewer: Francesco Romani Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: vm: renaming device unplug related function
gerrit-hooks has posted comments on this change. Change subject: vm: renaming device unplug related function .. Patch Set 5: * Update tracker: IGNORE, no Bug-Url found * Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' and is a valid url. * Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.6', 'ovirt-3.5', 'ovirt-3.4', 'ovirt-3.3']) -- To view, visit https://gerrit.ovirt.org/49038 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I3ab2b22e2a79507cde77addf28f29b80bde9e24d Gerrit-PatchSet: 5 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Marcin Mirecki Gerrit-Reviewer: Francesco Romani Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: vm: renaming device unplug related function
Francesco Romani has posted comments on this change. Change subject: vm: renaming device unplug related function .. Patch Set 4: Code-Review+2 I'm fine with the rename -- To view, visit https://gerrit.ovirt.org/49038 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I3ab2b22e2a79507cde77addf28f29b80bde9e24d Gerrit-PatchSet: 4 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Marcin Mirecki Gerrit-Reviewer: Francesco Romani Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: vm: renaming device unplug related function
gerrit-hooks has posted comments on this change. Change subject: vm: renaming device unplug related function .. Patch Set 4: * Update tracker: IGNORE, no Bug-Url found * Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' and is a valid url. * Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.6', 'ovirt-3.5', 'ovirt-3.4', 'ovirt-3.3']) -- To view, visit https://gerrit.ovirt.org/49038 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I3ab2b22e2a79507cde77addf28f29b80bde9e24d Gerrit-PatchSet: 4 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Marcin Mirecki Gerrit-Reviewer: Francesco Romani Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: vm: renaming device unplug related function
gerrit-hooks has posted comments on this change. Change subject: vm: renaming device unplug related function .. Patch Set 3: * Update tracker: IGNORE, no Bug-Url found * Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' and is a valid url. * Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.6', 'ovirt-3.5', 'ovirt-3.4', 'ovirt-3.3']) -- To view, visit https://gerrit.ovirt.org/49038 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I3ab2b22e2a79507cde77addf28f29b80bde9e24d Gerrit-PatchSet: 3 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Marcin Mirecki Gerrit-Reviewer: Francesco Romani Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: vm: renaming device unplug related function
gerrit-hooks has posted comments on this change. Change subject: vm: renaming device unplug related function .. Patch Set 2: * Update tracker: IGNORE, no Bug-Url found * Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' and is a valid url. * Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.6', 'ovirt-3.5', 'ovirt-3.4', 'ovirt-3.3']) -- To view, visit https://gerrit.ovirt.org/49038 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I3ab2b22e2a79507cde77addf28f29b80bde9e24d Gerrit-PatchSet: 2 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Marcin Mirecki Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: vm: renaming device unplug related function
gerrit-hooks has posted comments on this change. Change subject: vm: renaming device unplug related function .. Patch Set 1: * Update tracker: IGNORE, no Bug-Url found * Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' and is a valid url. * Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.6', 'ovirt-3.5', 'ovirt-3.4', 'ovirt-3.3']) -- To view, visit https://gerrit.ovirt.org/49038 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I3ab2b22e2a79507cde77addf28f29b80bde9e24d Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Marcin Mirecki Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: vm: renaming device unplug related function
Marcin Mirecki has uploaded a new change for review. Change subject: vm: renaming device unplug related function .. vm: renaming device unplug related function Renaming function related to unplugging a device to contain 'device' instead of 'drive' Change-Id: I3ab2b22e2a79507cde77addf28f29b80bde9e24d Signed-off-by: Marcin Mirecki --- M tests/vmTests.py M vdsm/virt/vm.py 2 files changed, 8 insertions(+), 8 deletions(-) git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/38/49038/1 diff --git a/tests/vmTests.py b/tests/vmTests.py index 74b3241..8b137a2 100644 --- a/tests/vmTests.py +++ b/tests/vmTests.py @@ -1264,7 +1264,7 @@ testvm = TestingVm(fake.Domain()) testvm._dom = FakeVmDom(self.DRIVE_XML, times_to_return_matching=99) -self.assertRaises(HotunplugTimeout, testvm._waitForDriveRemoval, +self.assertRaises(HotunplugTimeout, testvm._waitForDeviceRemoval, drive) @MonkeyPatch(config, 'getint', lambda x, y: 0) @@ -1273,7 +1273,7 @@ testvm = TestingVm(fake.Domain()) testvm._dom = FakeVmDom(self.DRIVE_XML) -testvm._waitForDriveRemoval(drive) +testvm._waitForDeviceRemoval(drive) @MonkeyPatch(config, 'getint', lambda x, y: 0) def test_wait_for_drive_removal_removed_on_x_check(self): @@ -1281,7 +1281,7 @@ testvm = TestingVm(fake.Domain()) testvm._dom = FakeVmDom(self.DRIVE_XML, times_to_return_matching=2) -testvm._waitForDriveRemoval(drive) +testvm._waitForDeviceRemoval(drive) self.assertEqual(testvm._dom._result_count, 2) diff --git a/vdsm/virt/vm.py b/vdsm/virt/vm.py index f882734..8da0f3c 100644 --- a/vdsm/virt/vm.py +++ b/vdsm/virt/vm.py @@ -2237,7 +2237,7 @@ try: self._dom.detachDevice(nicXml) -self._waitForDriveRemoval(nic) +self._waitForDeviceRemoval(nic) except HotunplugTimeout as e: self.log.error("%s", e) return response.error('hotunplugNic', "%s" % e) @@ -2640,7 +2640,7 @@ params=drive.custom) try: self._dom.detachDevice(driveXml) -self._waitForDriveRemoval(drive) +self._waitForDeviceRemoval(drive) except HotunplugTimeout as e: self.log.error("%s", e) return response.error('hotunplugDisk', "%s" % e) @@ -2666,7 +2666,7 @@ return {'status': doneCode, 'vmList': self.status()} -def _waitForDriveRemoval(self, device): +def _waitForDeviceRemoval(self, device): """ As stated in libvirt documentary, after detaching a device using virDomainDetachDeviceFlags, we need to verify that this device @@ -2688,13 +2688,13 @@ deadline = (utils.monotonic_time() + config.getint('vars', 'hotunplug_timeout')) sleep_time = config.getint('vars', 'hotunplug_sleep_time') -while self._isDriveAttached(device): +while self._isDeviceAttached(device): time.sleep(sleep_time) if utils.monotonic_time() > deadline: raise HotunplugTimeout("Timeout detaching device %s" % device.name) -def _isDriveAttached(self, device): +def _isDeviceAttached(self, device): root = ET.fromstring(self._dom.XMLDesc(0)) return bool(root.findall(device.xpath)) -- To view, visit https://gerrit.ovirt.org/49038 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I3ab2b22e2a79507cde77addf28f29b80bde9e24d Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Marcin Mirecki ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches