well-typed / grapesy

Native Haskell gRPC client and server based on `http2`
Other
31 stars 4 forks source link

Make HTTP2 window size configurable #145

Open FinleyMcIlwaine opened 1 month ago

FinleyMcIlwaine commented 1 month ago

http2 uses a default connection window size of 1MB per connection and 256KB per stream, which can cause data to pile up on a receiver's heap if they can't keep up. We've observed this in the stress tests. The standard fix for this is to reduce the window size. http2 makes this configurable, although a brief test where we tried to reduce the window size on the client led to bus errors in the server. We should make this configurable in grapesy as well, and see if we can avoid/fix the bus errors.

edsko commented 1 month ago

I just noticed confBufferSize in the settings, maybe we should be using that instead?