Interface TaskExecutionResult

All Known Implementing Classes:
TaskExecutionResult.AwaitSignal, TaskExecutionResult.Completed, TaskExecutionResult.Failed, TaskExecutionResult.SuspendFor

What the host should do with a task after TaskExecutorExtension.execute(com.xebialabs.xlrelease.osgi.api.tasks.TaskExecutionContext) returns.

A closed set of four outcomes, created through the static factory methods. Suspension is always a returned outcome, never a blocked or parked thread - the host persists the task's state and re-enters execute later, which is what makes a wait survive a server restart.

The two suspending outcomes mirror the two mechanisms Jython tasks already have: suspendFor(Duration) corresponds to CustomScriptTask.schedule(path, interval), and awaitSignal() to waitForSignal(). In both cases the task stays in progress and execute is entered again from the top - there is no separate "resume" method to implement. Distinguish the entries with TaskExecutionContext.isResume() and carry state across the gap in output properties.