[qmtest] resources that spawn processes.
Mark Mitchell
mark at codesourcery.com
Thu Jul 20 18:29:40 UTC 2006
J.T. Conklin wrote:
> But it seems that a mechanism to shut down a process gracefully might
> be something that the Executable class should provide. This is
> complicated somewhat by the fact that QMTest's Executable class
> supports Windows as well, and I'm not exactly sure what or if
> there is an equivalent to SIGTERM to signal a process to shut down.
Yes, I do think Executable should have a Terminate function, in addition
to Kill. Terminate should be defined as attempting to do orderly
shutdown; failing that, fall back to Kill. That means that an
acceptable implementation would be to fall back to Kill for systems that
have no mechanism for orderly shutdown.
For UNIX Terminate would send SIGTERM, wait a few seconds for process
death, and then call Kill if the process has not did. For Windows,
there are similar mechanisms which we could use.
--
Mark Mitchell
CodeSourcery
mark at codesourcery.com
(650) 331-3385 x713
More information about the qmtest
mailing list