Dela via


IDurableOrchestrationClient.RaiseEventAsync Method

Definition

Overloads

RaiseEventAsync(String, String, String, Object, String)

Sends an event notification message to a waiting orchestration instance.

RaiseEventAsync(String, String, Object)

Sends an event notification message to a waiting orchestration instance.

RaiseEventAsync(String, String, String, Object, String)

Source:
IDurableOrchestrationClient.cs

Sends an event notification message to a waiting orchestration instance.

public System.Threading.Tasks.Task RaiseEventAsync (string taskHubName, string instanceId, string eventName, object eventData, string connectionName = default);
abstract member RaiseEventAsync : string * string * string * obj * string -> System.Threading.Tasks.Task
Public Function RaiseEventAsync (taskHubName As String, instanceId As String, eventName As String, eventData As Object, Optional connectionName As String = Nothing) As Task

Parameters

taskHubName
String

The TaskHubName of the orchestration that will handle the event.

instanceId
String

The ID of the orchestration instance that will handle the event.

eventName
String

The name of the event.

eventData
Object

The JSON-serializeable data associated with the event.

connectionName
String

The name of the connection string associated with taskHubName.

Returns

A task that completes when the event notification message has been enqueued.

Exceptions

The instance id does not corespond to a valid orchestration instance.

The orchestration instance with the provided instance id is not running.

Remarks

In order to handle the event, the target orchestration instance must be waiting for an event named eventName using the WaitForExternalEvent<T>(String) API.

If the specified instance is not found or not running, this operation will throw an exception.

Applies to

RaiseEventAsync(String, String, Object)

Source:
IDurableOrchestrationClient.cs

Sends an event notification message to a waiting orchestration instance.

public System.Threading.Tasks.Task RaiseEventAsync (string instanceId, string eventName, object eventData = default);
abstract member RaiseEventAsync : string * string * obj -> System.Threading.Tasks.Task
Public Function RaiseEventAsync (instanceId As String, eventName As String, Optional eventData As Object = Nothing) As Task

Parameters

instanceId
String

The ID of the orchestration instance that will handle the event.

eventName
String

The name of the event.

eventData
Object

The JSON-serializeable data associated with the event.

Returns

A task that completes when the event notification message has been enqueued.

Exceptions

The instance id does not corespond to a valid orchestration instance.

The orchestration instance with the provided instance id is not running.

Remarks

In order to handle the event, the target orchestration instance must be waiting for an event named eventName using the WaitForExternalEvent<T>(String) API.

Applies to