Skip to content

Commit

Permalink
feat(server): increase max receive message size to 100MB
Browse files Browse the repository at this point in the history
  • Loading branch information
samcm committed Sep 21, 2023
1 parent 2da39d4 commit 6914694
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -222,9 +222,12 @@ func (x *Xatu) startGrpcServer(ctx context.Context) error {
return fmt.Errorf("failed to listen: %v", err)
}

mb50 := 1024 * 1024 * 100

opts := []grpc.ServerOption{
grpc.StreamInterceptor(grpc_prometheus.StreamServerInterceptor),
grpc.UnaryInterceptor(grpc_prometheus.UnaryServerInterceptor),
grpc.MaxRecvMsgSize(mb50),
grpc.KeepaliveParams(keepalive.ServerParameters{
MaxConnectionIdle: 5 * time.Minute,
MaxConnectionAge: 10 * time.Minute,
Expand Down

0 comments on commit 6914694

Please sign in to comment.