diff options
author | Eric Wong <normalperson@yhbt.net> | 2009-04-11 01:16:35 -0700 |
---|---|---|
committer | Eric Wong <normalperson@yhbt.net> | 2009-04-11 01:26:41 -0700 |
commit | 62ebc930c6e3b46cd200212748800c1ca448eb1f (patch) | |
tree | fd5c888c33ac58544121c1cfb3e59b584d01e51a /lib/unicorn.rb | |
parent | 3e9fe197d4daac14fa98addfcf9be3208c7b96b8 (diff) | |
download | unicorn-62ebc930c6e3b46cd200212748800c1ca448eb1f.tar.gz |
Unicorn is strictly for fast LAN and localhost clients. Unicorn is not for slow, high-latency or trickling clients and cannot do keepalive or pipelining. None of the removed options actually make sense in the environment Unicorn was designed for. * DEFER_ACCEPT/ACCEPT_FILTER - these are useful for mitigating connect() floods or trickling clients. We shouldn't have to deal with those on a trusted LAN. * TCP_CORK/TCP_NODELAY - we only send output in the response and then immediately close the socket. Assuming the typical response containing a small header and large strings in the body: the Nagle algorithm would've corked the headers regardless and any pending output would be immediately flushed when the socket is closed immediately after sending. These options would still be useful from the client-side on the LAN, or if Unicorn supported keepalive. Of course, I highly recommend enabling all of these options you can possibly enable on nginx or another fully-buffering reverse proxy when dealing with slow clients.
Diffstat (limited to 'lib/unicorn.rb')
-rw-r--r-- | lib/unicorn.rb | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/lib/unicorn.rb b/lib/unicorn.rb index fd66529..4e82ec6 100644 --- a/lib/unicorn.rb +++ b/lib/unicorn.rb @@ -404,7 +404,6 @@ module Unicorn # in 3 easy steps: read request, call app, write app response def process_client(client) client.nonblock = false - set_client_sockopt(client) if TCPSocket === client env = @request.read(client) app_response = @app.call(env) HttpResponse.write(client, app_response) |