You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@trafficserver.apache.org by "Alan M. Carroll (JIRA)" <ji...@apache.org> on 2014/09/19 15:20:35 UTC

[jira] [Created] (TS-3087) Flow control can stall at low water mark values

Alan M. Carroll created TS-3087:
-----------------------------------

             Summary: Flow control can stall at low water mark values
                 Key: TS-3087
                 URL: https://issues.apache.org/jira/browse/TS-3087
             Project: Traffic Server
          Issue Type: Bug
          Components: Core
            Reporter: Alan M. Carroll


If the flow control high water mark is set to be smaller than the TCP socket buffer size, flow control can stall out. The root cause is that the UnixNetVConnection will generate the WRITE_READY event before writing to the socket. If the amount of data in the buffers is larger than the water mark (throttling the connection) and small enough to all be written at once to the socket then the buffer will empty but no event will be generated to unthrottle the connection.

To fix this, I added the ability to force an event on the write buffer becoming empty for a NetVConnection. The flow control logic sets this in the cases where this can happen and therefore gets an event in which it can detect the buffer is empty and unthrottle.

To see this, simply set the flow control water marks to a small value such as 25000 and fetch a medium sized (~200K) object. Most of the time the request will stall. It will stall more often if cache is disabled (because the CacheVC generates a lot of events).



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)