Expand description
Abstraction for spawning and managing a re-startable async Task that runs
a user-supplied async closure, exposing termination and completion channels
for cooperative cancellation and result delivery.
Macros§
- set_
task - Assigns a task closure to an existing task source by expanding to a
set_task_fncall on the given target with the supplied closure. - task
- Constructs a
workflow_task::Taskfrom a closure or expression, wrapping the closure body so it is boxed and pinned as the task’s async future.
Structs§
- Task
Task{self::Task} struct allows you to spawn an async fn that can run in a loop as a task (similar to a thread), checking for a termination signal (so that execution can be aborted), upon completion returning a value to the creator.