okhttp: fix incorrect connection-level flow control handling at beginning of connection #6742
Thanks for sending this out. I didn't send it out earlier because it clearly deserved some tests. I was on vacation for a bit over a week, thus the delay.
Thank you testing this and confirming the OutboundFlowController argument was garbage.
You'd need to sign the CLA for us to accept the PR. We can work on some tests and make a PR, if that is easiest.
Hm, I signed the CLA (both on EasyCLA and the CNCF one linked in the contributing docs last week but it doesn't seem to be picking that up.
I took a stab at testing the changes:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
…ning of connection (v1.28.x backport) Specifically, this addresses bugs that occur when the `OkHttpChannelBuilder.flowControlWindow(int)` setting is increased from its default value. Two changes: 1. On starting a connection, ensure the value of `OkHttpChannelBuilder.flowControlWindow(int)` is sent via Settings.INITIAL_WINDOW_SIZE. Also send a WINDOW_UPDATE after Settings to update the connection-level window. 2. Always initialize the `OutboundFlowController` with an initialWindowSize of 65335 bytes per the [http2 spec](https://http2.github.io/http2-spec/#InitialWindowSize) instead of using the inbound window size. Fixes #6685 Backport of #6742