Share via


StreamingRun Class

Definition

A Workflow run instance supporting a streaming form of receiving workflow events, and providing a mechanism to send responses back to the workflow.

public sealed class StreamingRun : Microsoft.Agents.AI.Workflows.CheckpointableRunBase, IAsyncDisposable
type StreamingRun = class
    inherit CheckpointableRunBase
    interface IAsyncDisposable
Public NotInheritable Class StreamingRun
Inherits CheckpointableRunBase
Implements IAsyncDisposable
Inheritance
Implements

Properties

Name Description
Checkpoints (Inherited from CheckpointableRunBase)
IsCheckpointingEnabled (Inherited from CheckpointableRunBase)
LastCheckpoint

Gets the most recent checkpoint information.

(Inherited from CheckpointableRunBase)
SessionId

A unique identifier for the session. Can be provided at the start of the session, or auto-generated.

Methods

Name Description
CancelRunAsync()

Attempt to cancel the streaming run.

DisposeAsync()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources asynchronously.

GetStatusAsync(CancellationToken)

Gets the current execution status of the workflow run.

RestoreCheckpointAsync(CheckpointInfo, CancellationToken) (Inherited from CheckpointableRunBase)
SendResponseAsync(ExternalResponse)

Asynchronously sends the specified response to the external system and signals completion of the current response wait operation.

TrySendMessageAsync<TMessage>(TMessage)

Attempts to send the specified message asynchronously and returns a value indicating whether the operation was successful.

WatchStreamAsync(CancellationToken)

Asynchronously streams workflow events as they occur during workflow execution.

Extension Methods

Name Description
RunToCompletionAsync(StreamingRun, Func<WorkflowEvent,ExternalResponse>, CancellationToken)

Processes all events from the workflow execution stream until completion.

Applies to