Change in vdsm[master]: Add ut to supervdsmServer zombie reaper
danken at redhat.com
danken at redhat.com
Sun Jan 13 11:14:34 UTC 2013
Dan Kenigsberg has posted comments on this change.
Change subject: Add ut to supervdsmServer zombie reaper
......................................................................
Patch Set 2: I would prefer that you didn't submit this
(2 inline comments)
....................................................
File tests/superVdsmTests.py
Line 78: self.assertRaises(IOError, self._proxy.isRunning)
Line 79:
Line 80: @MonkeyPatch(supervdsm.SuperVdsmProxy, '_start', monkeyStart)
Line 81: def testZombieReaper(self):
Line 82: REPO_PATH = '/rhev/data-center'
this should be taken from configure.ac - we realllly want to drop the /rhev string, and it is hard as it is.
Line 83: self._proxy.ping()
Line 84: self.assertTrue(self._proxy.isRunning())
Line 85: self._proxy.validateAccess(
Line 86: QEMU_PROCESS_USER,
Line 89:
Line 90: with os.fdopen(self.pidfd, "r") as f:
Line 91: svdsmPid = f.read().strip()
Line 92:
Line 93: reapPid = utils.execCmd(
We (or should I say "Saggi") try to make constants.py cleaner, as well as cleaning how we execute external applications.
Instead of adding /usr/bin/ps dependency, would you use storage.misc.pidStat() ? Moving it out of "storage" would make sense, too.
Line 94: [EXT_PS, '--ppid', svdsmPid, '-o', 'pid='])[1]
Line 95: if reapPid:
Line 96: sleep(6) # supervdsmServer checks SIGCHLD every 5 secs
--
To view, visit http://gerrit.ovirt.org/9354
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I7fb8f3dcd575266febe11967e3f8df7d3588acb8
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Royce Lv <lvroyce at linux.vnet.ibm.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Royce Lv <lvroyce at linux.vnet.ibm.com>
Gerrit-Reviewer: Yaniv Bronhaim <ybronhei at redhat.com>
Gerrit-Reviewer: Zhou Zheng Sheng <zhshzhou at linux.vnet.ibm.com>
Gerrit-Reviewer: oVirt Jenkins CI Server
More information about the vdsm-patches
mailing list