Expand description
A task spawned in an executor.
Required Methods
sourcefn sync_stop(self: Arc<Self>)
fn sync_stop(self: Arc<Self>)
Synchronously stops the task.
It ensures that the task won’t run again and releases resources needed to run the task (e.g., the closure is dropped). If the task is inflight, it waits for the task to block or complete before cleaning up and returning.
Callers must not call this from within the task itself as it will likely lead to a deadlock.