Skip to content
This repository has been archived by the owner on Oct 9, 2023. It is now read-only.

[do not use] Raise gRPC limit to 16 MB #100

Merged
merged 2 commits into from
May 29, 2020

Conversation

wild-endeavor
Copy link
Contributor

@wild-endeavor wild-endeavor commented May 29, 2020

Temporarily raising the gRPC limit to 16MBs. This PR should be reverted after the error truncation fix goes in.

@@ -205,7 +205,7 @@ func serveGatewayInsecure(ctx context.Context, cfg *config.ServerConfig) error {
}()

logger.Infof(ctx, "Starting HTTP/1 Gateway server on %s", cfg.GetHostAddress())
httpServer, err := newHTTPServer(ctx, cfg, authContext, cfg.GetGrpcHostAddress(), grpc.WithInsecure())
httpServer, err := newHTTPServer(ctx, cfg, authContext, cfg.GetGrpcHostAddress(), grpc.WithInsecure(), grpc.WithDefaultCallOptions(grpc.MaxCallRecvMsgSize(16777216)))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Const variable please :)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes yes, but should we do this?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the default?
Does this number mean anything in particular :-D ?
Are you trying to limit it or make it more permissible?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what happens when a response exceeds the size? does this get logged? does an error get returned?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Go to the link I'm about to send you on Slack.

Copy link
Contributor Author

@wild-endeavor wild-endeavor May 29, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The default size limit for grpc is 4MB, which is where the 4194304 number comes from in the error message (4*2^20). This is just four times that so 16MB (so making it more permissible). wondering if the truncation change is equally quick, in which case we should do that instead? or another workaround that people would rather see?

@codecov-commenter
Copy link

codecov-commenter commented May 29, 2020

Codecov Report

Merging #100 into Lyft-Flyte will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@             Coverage Diff             @@
##           Lyft-Flyte     #100   +/-   ##
===========================================
  Coverage       63.09%   63.09%           
===========================================
  Files             100      100           
  Lines            7061     7061           
===========================================
  Hits             4455     4455           
  Misses           2093     2093           
  Partials          513      513           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6a72a7a...d45c54d. Read the comment docs.

@wild-endeavor wild-endeavor changed the title adding max message size [do not use] Raise gRPC limit to 16 MB May 29, 2020
@anandswaminathan
Copy link
Contributor

anandswaminathan commented May 29, 2020

Congrats. PR: 100

@wild-endeavor wild-endeavor merged commit d65d53b into Lyft-Flyte May 29, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants