process module - implements process concepts. yessirre.
Process monitor
StartProcess() -> None Called by app when process or service starts
StopProcess() -> None Called when process or service stops
Wait(timeout) -> bool Wait on all tasklets in the process. If the function returns ‘True’, all tasklets have exited. If the function returns ‘False, one or more tasklets are still busy. ‘timeout’ is timeout in milliseconds. Use WAIT_INFINITE for no timeout. If ‘timeout’ is WAIT_CHECK, the function returns immediately.
If the calling tasklet is part of the process, the function will return when all other tasklets have exited (i.e. it will not deadlock itself or raise an error).
Tasklet wrapper. Adds top-level exception handler and keeps reference to its owner
Restore the tasklet attributes to those that were before SetupState()
Run a function, along with the proper top level error handling and process bookkeeping. SetupState() must have been called previously.
Set up the tasklet with initial attributes pertaining to the process, returning any such previous attributes (oldstate)
A class that recycles tasklets. This is useful not as a performance improvement, but to limit the number of actual tasklet IDs in use, when implementing C level code that uses the tasklet ID as an index to some sort of TLS structure.
Remove the oldest Tasklet from the queue, telling it to stop.
Clear the queue of idle tasklets
Get the next piece of work to perform on the behalf of a user, or None
Emulate the constructor of the Tasklet object. Tries to get the most recently used idle tasklet. If none are available, a new is created. Returns a callable that can be used to bind arguments to the call.
The main worker function for each tasklet managed by the TaskletPool Takes as arguments the initial process, function and arguments to execute.