Share via


DurableTaskClient.SuspendInstanceAsync Method

Definition

Overloads

SuspendInstanceAsync(String, CancellationToken)

Suspends an orchestration instance, halting processing of it until ResumeInstanceAsync(String, String, CancellationToken) is used to resume the orchestration.

SuspendInstanceAsync(String, String, CancellationToken)

Suspends an orchestration instance, halting processing of it until ResumeInstanceAsync(String, String, CancellationToken) is used to resume the orchestration.

SuspendInstanceAsync(String, CancellationToken)

Suspends an orchestration instance, halting processing of it until ResumeInstanceAsync(String, String, CancellationToken) is used to resume the orchestration.

public virtual System.Threading.Tasks.Task SuspendInstanceAsync (string instanceId, System.Threading.CancellationToken cancellation);
abstract member SuspendInstanceAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task
override this.SuspendInstanceAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Overridable Function SuspendInstanceAsync (instanceId As String, cancellation As CancellationToken) As Task

Parameters

instanceId
String

The instance ID of the orchestration to suspend.

cancellation
CancellationToken

A CancellationToken that can be used to cancel the suspend operation. Note, cancelling this token does not resume the orchestration if suspend was successful.

Returns

A task that completes when the suspend has been committed to the backend.

Applies to

SuspendInstanceAsync(String, String, CancellationToken)

Suspends an orchestration instance, halting processing of it until ResumeInstanceAsync(String, String, CancellationToken) is used to resume the orchestration.

public abstract System.Threading.Tasks.Task SuspendInstanceAsync (string instanceId, string? reason = default, System.Threading.CancellationToken cancellation = default);
abstract member SuspendInstanceAsync : string * string * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public MustOverride Function SuspendInstanceAsync (instanceId As String, Optional reason As String = Nothing, Optional cancellation As CancellationToken = Nothing) As Task

Parameters

instanceId
String

The instance ID of the orchestration to suspend.

reason
String

The optional suspension reason.

cancellation
CancellationToken

A CancellationToken that can be used to cancel the suspend operation. Note, cancelling this token does not resume the orchestration if suspend was successful.

Returns

A task that completes when the suspend has been committed to the backend.

Applies to