Yaniv Bronhaim has posted comments on this change.
Change subject: utils: Wait for terminated process ......................................................................
Patch Set 5:
(1 comment)
https://gerrit.ovirt.org/#/c/65324/5/lib/vdsm/utils.py File lib/vdsm/utils.py:
Line 737: try: Line 738: if proc.poll() is None: Line 739: logging.debug('Terminating process pid=%d' % proc.pid) Line 740: proc.kill() Line 741: proc.wait() Dan said that he doesn't understand my comment - we invented this context to cover proc object in such way that won't leave zombies if the context exists in the middle - for safety to avoid depending on the old death signal that we had.
Now, instead of just trying to kill the process and "reap" it, the context won't continue until the process exits... at least for me it is not the expected behavior. however, we still don't use it so we can change it if that way you see more usages for this context Line 742: except Exception: Line 743: logging.exception('Failed to kill process %d' % proc.pid) Line 744: Line 745: