resources that spawn processes.

J.T. Conklin jtc at acorntoolworks.com
Thu Jul 20 18:02:14 UTC 2006


Hi Folks,

In our test suite, we have several QMTest resources that are wrappers
around daemon processes (TAO's Naming Service, Notification Service,
our own servants/servers, etc).  Until now we've been using QMTest's
Executable class to spawn and manage these subprocesses, but have run
into a minor problem now that I'm adding code coverage and profiling
instrumentation to our tests.

Presently we use Spawn() to spawn processes, and Kill() to terminate
them.  That sends SIGKILL, which defeats the SIGINT/SIGTERM handlers
that implement graceful shutdown.  What's worse, the data that has
been collected data lost.

It seems the easiest thing to do is just use os.spawn* and manage the
processes directly.  In the interests of time, I'm probably going to
have to do this.  

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.

    --jtc

-- 
J.T. Conklin



More information about the qmtest mailing list