Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable specifying Grpc options like " MaxReceiveMessageSize" in WorkflowServiceCollectionExtensions #1163

Closed
hsinghdeol-wpay opened this issue Oct 11, 2023 · 3 comments · Fixed by #1244
Labels

Comments

@hsinghdeol-wpay
Copy link

hsinghdeol-wpay commented Oct 11, 2023

Currently dapr workflows fail with following error
2023-10-11T06:26:20.075785954Z Grpc.Core.RpcException: Status(StatusCode="ResourceExhausted", Detail="Received message exceeds the maximum configured message size.") 2023-10-11T06:26:20.075793354Z at Grpc.Net.Client.StreamExtensions.ReadMessageAsync[TResponse](Stream responseStream, GrpcCall call, Func2 deserializer, String grpcEncoding, Boolean singleMessage, CancellationToken cancellationToken)
2023-10-11T06:26:20.075801654Z at Grpc.Net.Client.Internal.HttpContentClientStreamReader2.MoveNextCore(CancellationToken cancellationToken) 2023-10-11T06:26:20.075833955Z at Microsoft.DurableTask.GrpcExtensions.ReadAllAsync[T](IAsyncStreamReader1 reader, CancellationToken cancellationToken)+MoveNext()
2023-10-11T06:26:20.075841955Z at Microsoft.DurableTask.GrpcExtensions.ReadAllAsync[T](IAsyncStreamReader1 reader, CancellationToken cancellationToken)+System.Threading.Tasks.Sources.IValueTaskSource<System.Boolean>.GetResult() 2023-10-11T06:26:20.075852855Z at Microsoft.DurableTask.Worker.Grpc.GrpcDurableTaskWorker.Processor.ProcessWorkItemsAsync(AsyncServerStreamingCall1 stream, CancellationToken cancellation)
2023-10-11T06:26:20.075860455Z at Microsoft.DurableTask.Worker.Grpc.GrpcDurableTaskWorker.Processor.ProcessWorkItemsAsync(AsyncServerStreamingCall1 stream, CancellationToken cancellation) 2023-10-11T06:26:20.075866755Z at Microsoft.DurableTask.Worker.Grpc.GrpcDurableTaskWorker.Processor.ExecuteAsync(String target, CancellationToken cancellation)
I found out that there is no way to override default limit of 4mb in the following file.

GrpcChannelOptions options = new() { HttpClient = client};

There should be way to override default GRPC options

@zminot
Copy link

zminot commented Jan 18, 2024

I've run into this as well. I know this was referenced in #978 (comment), but also bringing this up in this issue.

It seems like DurableTasks has a hard limit of 4MB as noted in microsoft/durabletask-dotnet#150 (comment), and the Dotnet SDK for Dapr Workflow uses that underneath. Do we think it'd be a good idea to update the Dapr documentation for this if this is now a known (and presumedly unsolvable by Dapr) issue?

Not sure if microsoft/durabletask-dotnet#154 is something that will alleviate this, however.

@cgillum
Copy link
Contributor

cgillum commented Sep 12, 2024

I don't think this should require any work on the Durable Task SDK side since the Dapr Workflow client already controls its gRPC channel configuration as referenced in the OP. I can imagine that we may need to expose this in the sidecar as well, but it's possible this may already be supported if it's a server setting (durabletask-go is part of the same server as the rest of the Dapr APIs).

Agreed that this is important to fix given that it can cause workflows to fail mid-execution.

@WhitWaldo
Copy link
Contributor

Should be resolved by #1244

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: Done
4 participants