Class TaskStateMetadataPlugin
WorkPlugin to populate TaskState.metadata
Declaration
source linkDocumentation
Methods
▶ def setup(self, worker) overrideinherited doc Run when the plugin is attached to a worker. This happens when the plugin is registered and attached to existing workers, or when a worker is created after the plugin has been registered.
▶ def transition(self, key, start, finish, **kwargs) overrideinherited doc Throughout the lifecycle of a task (see :doc:`Worker <worker>`), Workers are
This method overrides distributed.diagnostics.plugin.WorkerPlugin.transition.
instructed by the scheduler to compute certain tasks, resulting in transitions
in the state of each task. The Worker owning the task is then notified of this
state transition.
Whenever a task changes its state, this method will be called.
Parameters
- key : string
- start : string
Start state of the transition.
One of waiting, ready, executing, long-running, memory, error.
- finish : string
Final state of the transition.
- kwargs : More options passed when transitioning