Package io.kestra.core.tasks.flows
Class Pause
java.lang.Object
io.kestra.core.models.tasks.Task
io.kestra.core.tasks.flows.Sequential
io.kestra.core.tasks.flows.Pause
- All Implemented Interfaces:
FlowableTask<VoidOutput>
@Plugin(examples=@Example(full=true,code="id: human_in_the_loop\nnamespace: dev\n\ntasks:\n - id: before_approval\n type: io.kestra.core.tasks.debugs.Return\n format: Output data that needs to be validated by a human\n\n - id: pause\n type: io.kestra.core.tasks.flows.Pause\n tasks:\n - id: run_post_approval\n type: io.kestra.plugin.scripts.shell.Commands\n runner: PROCESS\n commands:\n - echo \"Manual approval received! Continuing the execution...\"\n\n - id: post_resume\n type: io.kestra.core.tasks.debugs.Return\n format: \"{{ task.id }} started on {{ taskrun.startDate }} after the Pause\"\n"))
public class Pause
extends Sequential
implements FlowableTask<VoidOutput>
-
Field Summary
Fields inherited from class io.kestra.core.tasks.flows.Sequential
errors -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionresolveNexts(RunContext runContext, Execution execution, TaskRun parentTaskRun) Resolve next tasks to run for an execution.resolveState(RunContext runContext, Execution execution, TaskRun parentTaskRun) Resolve the state of a flowable task.Methods inherited from class io.kestra.core.tasks.flows.Sequential
allChildTasks, childTasks, tasksTreeMethods inherited from class io.kestra.core.models.tasks.Task
findById, findById, isFlowable, isSendToWorkerTaskMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.kestra.core.models.tasks.FlowableTask
allChildTasks, childTasks, getErrors, outputs, tasksTree
-
Constructor Details
-
Pause
public Pause()
-
-
Method Details
-
resolveNexts
public List<NextTaskRun> resolveNexts(RunContext runContext, Execution execution, TaskRun parentTaskRun) throws IllegalVariableEvaluationException Description copied from interface:FlowableTaskResolve next tasks to run for an execution.For a normal flowable, it should be the subsequent task, for a parallel flowable (such as Parallel, ForEachItem, ...), it should be a list of the next subsequent tasks of the size of the concurrency of the task.
- Specified by:
resolveNextsin interfaceFlowableTask<VoidOutput>- Overrides:
resolveNextsin classSequential- Throws:
IllegalVariableEvaluationException
-
resolveState
public Optional<State.Type> resolveState(RunContext runContext, Execution execution, TaskRun parentTaskRun) throws IllegalVariableEvaluationException Description copied from interface:FlowableTaskResolve the state of a flowable task.- Specified by:
resolveStatein interfaceFlowableTask<VoidOutput>- Throws:
IllegalVariableEvaluationException
-