workflows.services.executors.factoryΒΆ
Factory and base types for workflow step executors.
Module ContentsΒΆ
- class workflows.services.executors.factory.AbstractStepExecutor[source]ΒΆ
Base class for all step executors.
- execute(instance, signal)[source]ΒΆ
Execute this step.
- Parameters:
instance (workflows.models.WorkflowInstance) β The workflow instance being advanced.
signal (str | None) β Optional external signal passed to the step.
- Returns:
The result of executing the step.
- Return type:
- do_execute(instance, signal)[source]ΒΆ
Actual execution hook implemented by concrete executors.
- Parameters:
instance (workflows.models.WorkflowInstance) β The workflow instance being advanced.
signal (str | None) β Optional external signal passed to the step.
- Returns:
The result of executing the step.
- Raises:
NotImplementedError β Always; subclasses must implement.
- Return type:
- class workflows.services.executors.factory.StepExecutorFactory[source]ΒΆ
Registry-backed factory for step executors.
- classmethod register(step_type, executor_cls)[source]ΒΆ
Register an executor class for a step type.
- Parameters:
step_type (str) β Identifier of the step type.
executor_cls (type[AbstractStepExecutor]) β Concrete executor class to instantiate for this type.
- Return type:
None