Skip to content

Conversation

@raggi
Copy link
Contributor

@raggi raggi commented Jun 5, 2013

  • Many servers have a max_requests tunable on keepalive connections that is
    tuned to less than infinite. Some of these servers incorrectly close the
    connection out-of-band (rather than replying with Connection:close). In these
    cases, it is advantageous to avoid the resulting ECONNRESET, and preemptively
    reset those connections.
  • Additional potential work that could be done later: Make a closing request on
    the last request. Add a detect_max_requests helper at the top level.
  • Exmaple configuration link:
    http://wiki.nginx.org/HttpCoreModule#keepalive_requests

 * Many servers have a max_requests tunable on keepalive connections that is
   tuned to less than infinite. Some of these servers incorrectly close the
   connection out-of-band (rather than replying with Connection:close). In these
   cases, it is advantageous to avoid the resulting ECONNRESET, and preemptively
   reset those connections.
 * Additional potential work that could be done later: Make a closing request on
   the last request. Add a detect_max_requests helper at the top level.
 * Exmaple configuration link:
   http://wiki.nginx.org/HttpCoreModule#keepalive_requests
@raggi
Copy link
Contributor Author

raggi commented Jun 5, 2013

Travis failure for 1.9.2 is a false negative - the build is missing OpenSSL.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It should be requests >= @max_requests, I believe

drbrain added a commit that referenced this pull request Jul 23, 2013
Add Persistent#max_requests to prevent ECONNRESET
@drbrain drbrain merged commit c94cdee into drbrain:master Jul 23, 2013
drbrain added a commit that referenced this pull request Jul 23, 2013
drbrain added a commit that referenced this pull request Jul 23, 2013
Noted by Roman Shterenzon
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants