ekr / minq

A simple Go implementation of QUIC
MIT License
98 stars 16 forks source link

Flow control #61

Closed martinthomson closed 6 years ago

martinthomson commented 6 years ago

This implements connection-level flow control. I found a few structural issues with other parts of the code (my previous changes primarily).

This includes back pressure on write. Write returns ErrorWouldBlock if there is no available flow control credit.

This adds sending of [STREAM_]BLOCKED frames when various things run out. It stops sending them as appropriate.

ekr commented 6 years ago

Can you please put this up on Phab?

On Sun, Mar 18, 2018 at 6:11 PM, Martin Thomson notifications@github.com wrote:

This implements connection-level flow control. I found a few structural issues with other parts of the code (my previous changes primarily).

This includes back pressure on write. Write returns ErrorWouldBlock if there is no available flow control credit.

This adds sending of [STREAM_]BLOCKED frames when various things run out. It stops sending them as appropriate.

You can view, comment on, or merge this pull request online at:

https://github.com/ekr/minq/pull/61 Commit Summary

  • Use new flow control object
  • Add connection-level flow control
  • Implement better flow control
  • Issue MAX[STREAM]DATA frames when you get [STREAM_]BLOCKED frames
  • Fix loss of flow control in case of RST_STREAM
  • Reset handling
  • Send the BLOCKED frames as well

File Changes

Patch Links:

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/ekr/minq/pull/61, or mute the thread https://github.com/notifications/unsubscribe-auth/ABD1oRA60tD7F8pv-G0x-hsO9iXLhFf6ks5tfqNngaJpZM4SvTkX .

martinthomson commented 6 years ago

https://phabricator.services.mozilla.com/D1100 - I might need to poke at phabricator so that it knows about the repo though.