Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions src/Dapr.Workflow/Logging.cs
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,9 @@ internal static partial class Logging
[LoggerMessage(LogLevel.Information, "Starting gRPC bidirectional stream with Dapr sidecar")]
public static partial void LogGrpcProtocolHandlerStartStream(this ILogger logger);

[LoggerMessage(LogLevel.Information, "Established gRPC bidirectional stream with Dapr sidecar")]
public static partial void LogGrpcProtocolHandlerStreamEstablished(this ILogger logger);

[LoggerMessage(LogLevel.Information, "gRPC stream canceled")]
public static partial void LogGrpcProtocolHandlerStreamCanceled(this ILogger logger);

Expand Down
4 changes: 3 additions & 1 deletion src/Dapr.Workflow/Worker/Grpc/GrpcProtocolHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,12 @@ public async Task StartAsync(
// Establish the server streaming call
_streamingCall = _grpcClient.GetWorkItems(request, cancellationToken: token);

_logger.LogGrpcProtocolHandlerStreamEstablished();

// Process work items from the stream
await ReceiveLoopAsync(_streamingCall.ResponseStream, workflowHandler, activityHandler, token);

// Stream ended gracefully => tradfe as an interrupted and reconnect unless shutting down
// Stream ended gracefully => treat as an interrupted and reconnect unless shutting down
if (!token.IsCancellationRequested)
{
await DelayOrStopAsync(ReconnectDelay, token);
Expand Down
Loading