Skip to main content

shutdown

Shutdown worker(s).

def shutdown(
state: Any,
msg: string = 'Got shutdown from remote',
**kwargs: dict
) - > null

Shutdown worker(s).

Parameters

NameTypeDescription
stateAnyThe current internal state or context of the worker process
msgstring = 'Got shutdown from remote'The log message explaining the reason for the shutdown, which is recorded at the warning level before termination
**kwargsdictAdditional keyword arguments passed by the control command decorator

Returns

TypeDescription
nullThis function does not return a value as it raises a WorkerShutdown exception to terminate the process.