Fabric Message is too large even after setting MaxMessageSize for Assembly

276 views Asked by At

In some cases we require a large-ish amount of data to be passed between two Service Fabric services.

Let's call the first service Monitor and the second Search.

Monitor implements an Actor which calls Search periodically and does something with the results.

Both the Monitor actor interface and the Search remoting service interface have the following attribute:

[assembly: FabricTransportActorRemotingProvider(RemotingListener = RemotingListener.V2Listener, RemotingClient = RemotingClient.V2Client, MaxMessageSize = 1073741824)]

From what I understand based on this question, this API documentation, and this discussion, this should work. It doesn't, however.

The call to Search works but Monitoring throws on the call return with "Fabric Message is too large".

Can anyone help? I'm about to go get a job as a ditch-digger.

1

There are 1 answers

0
Electric_Wizard On BEST ANSWER

Thanks to Hans Passant for suggesting the alternative that Remy suggested in this link.

I initially dismissed this suggestion due to the fact that directly after the first response to the suggestion a person indicated that they were using Actors and so the answer was unusable.

Turns out, just adding

<Section Name="TransportSettings">
    <Parameter Name="MaxMessageSize" Value="1073741824" />
</Section>

to the Settings.xml file of the Monitor Actor project resolved the issue.