TaskDefinition<TInput,TOutput>.DeleteAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before itβs released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Ends a multi-turn chain: cancels any in-flight turn, resolves queued callers as cancelled, and removes the record. Idempotent β a no-op when the chain is absent.
public virtual System.Threading.Tasks.Task DeleteAsync(string taskId, System.Threading.CancellationToken cancellationToken = default);
abstract member DeleteAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task
override this.DeleteAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Overridable Function DeleteAsync (taskId As String, Optional cancellationToken As CancellationToken = Nothing) As Task
Parameters
- taskId
- String
The chain id.
- cancellationToken
- CancellationToken
A cancellation token.
Returns
A task that completes when the chain has been removed.
Remarks
Cancellation is requested before storage deletion. A storage failure does not undo cancellation and does not authorize stream closure. Task-bound streams close after deletion is confirmed and their producer has unwound. This method does not wait for an in-flight handler to finish; that handler's completion may remain pending.