Skip to content
  • Toralf Wittner's avatar
    Add command-line flag to enable yamux flow control. (#4892) · f5f7852a
    Toralf Wittner authored
    * Add command-line flag to enable yamux flow control.
    
    We never enabled proper flow-control for yamux streams which may cause
    stream buffers to exceed their configured limit when the stream
    producer outpaces the stream consumer. By switching the window update
    mode to on-read, producers will only receive more sending credit when
    all data has been consumed from the stream buffer. Using this option
    creates backpressure on producers. However depending on the protocol
    there is a risk of deadlock, if both endpoints concurrently attempt to
    send more data than they have credit for and neither side reads before
    finishing their writes. To facilitate proper testing, this PR adds a
    command-line flag `use-yamux-flow-control`.
    
    * Replace comment with generic message.
    f5f7852a