Skip to content

Commit

Permalink
Allow grpc server for plugins to handle large messages
Browse files Browse the repository at this point in the history
Fixes #4957

I think
  • Loading branch information
jefferai committed Jul 19, 2018
1 parent 4bd42b4 commit 8cba8e0
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions logical/plugin/grpc_backend_client.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ package plugin
import (
"context"
"errors"
"math"
"sync/atomic"

"google.golang.org/grpc"
Expand Down Expand Up @@ -195,6 +196,8 @@ func (b *backendGRPCPluginClient) Setup(ctx context.Context, config *logical.Bac

// Register the server in this closure.
serverFunc := func(opts []grpc.ServerOption) *grpc.Server {
opts = append(opts, grpc.MaxSendMsgSize(math.MaxInt32))
opts = append(opts, grpc.MaxRecvMsgSize(math.MaxInt32))
s := grpc.NewServer(opts...)
pb.RegisterSystemViewServer(s, sysView)
pb.RegisterStorageServer(s, storage)
Expand Down

0 comments on commit 8cba8e0

Please sign in to comment.