gRPC message exceeds

Hi All,
when i am trying to fetch large set of nodes using Dgraph Java client , i am seeing below error.

io.grpc.StatusRuntimeException: RESOURCE_EXHAUSTED: gRPC message exceeds maximum size 4194304: 4995127

what’s the way to increase the fetch size in DgraphJava Client.


You need to use maxInboundMessageSize(int bytes) like this:

ManagedChannel channel = ManagedChannelBuilder.forAddress(HOST, PORT)
    DgraphStub stub = DgraphGrpc.newStub(channel);

The above code sample increases the limit to 1GiB, from default 4MiB.

But using pydgraph on the python client, I cannot change the max_length according to the setting

Is there a problem with my statement?

seems right to me, gRPC code here says the same.
Maybe there is some other issue?

Thanks @abhimanyusinghgaur It worked.