Stores parameters across all children, sets out log directory, initializes our data arrays, records start times, and pops numJobs functions into a Queue. Abstracts and makes it easier to manage scores of child processes. Also has a think() process to continuously manage them.
Parameters: |
|
---|---|
Returns: | Pool (self) |
Returns a True/False if the pool is done processing jobs. Called continuously by our main loop. When False, the program terminates.
Returns: | Boolean for if there are children still running work. |
---|
Removes the last created child, called by GUI.
Parameters: | i (None) – The index of the child process to kill. If not specified, it chooses the last child in the pool.children array that is alive. |
---|---|
Returns: | None |
Logs a message to our log file in a consistent format. Depends on pool.lh already being initialized and ready for writing. Does not flush the handle.
Parameters: |
|
---|---|
Returns: | None |
Parameters: | type (STOPPED) – Type of stopping this is, either pausing or stopping. |
---|---|
Returns: | None |
Reports the number of jobs successfully completed so far.
Returns: | Integer for number of jobs successfully completed. |
---|
Runs through a single think loop; called by sw.wrapper.mainLoop() until there is no more work remaining. Check children are alive/restart if there are more jobs. Checks queues and parses any data.
Returns: | None |
---|