pypushflow.concurrent.ndprocess.NdProcessPool¶
- class pypushflow.concurrent.ndprocess.NdProcessPool(context=None, **kw)[source]¶
Bases:
ProcessPool
Pool of non-daemonic processes (they can have sub-processes).
- Parameters:
context (
Optional
[str
]) –
- apply_async(fn, callback=None, error_callback=None, args=(), kwargs=None)¶
- Parameters:
fn (
Callable
) –callback (
Optional
[Callable
]) –error_callback (
Optional
[Callable
]) –
- Return type:
Future
- close()¶
Prevents any more tasks from being submitted to the pool.
- interrupt()¶
Stop all running tasks
- Return type:
None
- join(timeout=None)¶
Wait for the workers to exit.
- Parameters:
timeout (
Optional
[Number
]) –- Return type:
bool
- shutdown(block=False, timeout=None, interrupt=False)¶
Cleanup all resources. Waits for tasks to finish unless interrupt=True.
- Parameters:
block (
bool
) –timeout (
Optional
[Number
]) –interrupt (
bool
) –
- Return type:
None