Date | Commit message (Collapse) |
|
We now close the client socket after closing the response body.
This does not affect most applications that run under Unicorn,
in fact, it may not affect any.
There is also a new v1.1.6 release for users who do not use
kgio.
|
|
Response bodies may capture the block passed to each
and save it for body.close, so don't close the socket
before we have a chance to call body.close
|
|
Certain applications that already serve hundreds/thousands of requests a
second should experience performance improvements due to
Time.now.httpdate usage being removed and reimplemented in C.
There are also minor internal changes and cleanups for Rainbows!
|
|
But allows small optimizations to be made to avoid
constant/instance variable lookups later :)
|
|
No need to preserve the response tuplet if we're just
going to unpack it eventually.
|
|
|
|
This will allow Rainbows! to set :tcp_nodelay=>true
and possibly other things in the future.
|
|
This can return a static string and be significantly
faster as it reduces object allocations and Ruby method
calls for the fastest websites that serve thousands of
requests a second.
It assumes the Ruby runtime is single-threaded, but that
is the case of Ruby 1.8 and 1.9 and also what Unicorn
is all about. This change is safe for Rainbows! under 1.8
and 1.9.
|
|
It's a minor garbage reduction, but nobody uses "$,", and
if they did, they'd break things in the Ruby standard library
as well as Rack, so let anybody who uses "$," shoot themselves
in the foot.
|
|
We use this in Rainbows! to disable keepalive in certain
configurations.
|
|
We do not link against any external libraries
|
|
Oops!
|
|
There are numerous improvements in the HTTP parser for
Rainbows!, none of which affect Unicorn-only users.
The kgio dependency is incremented to 2.1: this should avoid
ENOSYS errors for folks building binaries on newer Linux
kernels and then deploying to older ones.
There are also minor documentation improvements, the website
is now JavaScript-free!
(Ignore the 3.2.0 release, I fat-fingered some packaging things)
|
|
Oops
|
|
There are numerous improvements in the HTTP parser for
Rainbows!, none of which affect Unicorn-only users.
The kgio dependency is incremented to 2.1: this should avoid
ENOSYS errors for folks building binaries on newer Linux
kernels and then deploying to older ones.
There are also minor documentation improvements, the website
is now JavaScript-free!
|
|
We can just use a begin block at startup, this also makes life
easier on RDoc.
|
|
An unconfigured Rainbows! (e.g. Rainbows! { use :Base }) already
does keepalive and supports only a single client per-process.
|
|
We need to preserve our internal flags and only clear them on
HttpParser#parse. This allows the async concurrency models in
Rainbows! to work properly.
|
|
The kgio 2.x series will maintain API compatibility
until 3.x, so it's safe to use any 2.x release.
|
|
Oops
|
|
wrongdoc factors out a bunch of common code from this
project into its own and removes JavaScript from RDoc
to boot.
|
|
Disabling TeeInput is possible now, so the filesystem
is no longer a bottleneck :>
|
|
It's more useful this way
|
|
Hopefully this gets more people reading our source.
|
|
This is the most important part of Unicorn documentation
for end users.
|
|
More config bloat, sadly this is necessary for Rainbows! :<
|
|
Evil clients may be exposed to the Unicorn parser via
Rainbows!, so we'll allow people to turn off blindly
trusting certain X-Forwarded* headers for "rack.url_scheme"
and rely on middleware to handle it.
|
|
rack.url_scheme handling and SERVER_{NAME,PORT} handling
each deserve their own functions.
|
|
The first value of X-Forwarded-Proto in rack.url_scheme should
be used as it can be chained. This header can be set multiple
times via different proxies in the chain, but consider the first
one to be valid.
Additionally, respect X-Forwarded-SSL as it may be passed with
the "on" flag instead of X-Forwarded-Proto.
ref: rack commit 85ca454e6143a3081d90e4546ccad602a4c3ad2e
and 35bb5ba6746b5d346de9202c004cc926039650c7
|
|
This limits the number of keepalive requests of a single
connection to prevent a single client from monopolizing server
resources. On multi-process servers (e.g. Rainbows!) with many
keepalive clients per worker process, this can force a client to
reconnect and increase its chances of being accepted on a
less-busy worker process.
This directive is named after the nginx directive which
is identical in function.
|
|
This allows apps/middlewares on Rainbows! that rely on env in
the response_body#close to hold onto the env.
|
|
This release enables tuning the client_buffer_body_size to raise
or lower the threshold for buffering request bodies to disk.
This only applies to users who have not disabled rewindable
input. There is also a TeeInput bugfix for uncommon usage
patterns and Configurator examples in the FAQ should be fixed
|
|
Since modern machines have more memory these days and
clients are sending more data, avoiding potentially slow
filesystem operations for larger uploads can be useful
for some applications.
|
|
This has been broken since 2.0.x
Internal cleanups sometimes have unintended consequences :<
|
|
In case a request sends the header and buffer as one packet,
TeeInput relying on accounting info from StreamInput is harmful
as StreamInput will buffer in memory outside of TeeInput's
control.
This bug is triggered by calling env["rack.input"].size or
env["rack.input"].rewind before to read.
|
|
...and only Rainbows! This release fixes HTTP pipelining for
requests with bodies for users of synchronous Rainbows!
concurrency models.
Since Unicorn itself does not support keepalive nor pipelining,
Unicorn-only users need not upgrade.
|
|
It screws up keepalive for Rainbows! requests with a body.
|
|
Rewindable "rack.input" may be disabled via the
"rewindable_input false" directive in the configuration file.
This will violate Rack::Lint for Rack 1.x applications, but can
reduce I/O for applications that do not need a rewindable
input.
This release updates us to the Kgio 2.x series which should play
more nicely with other libraries and applications. There are
also internal cleanups and improvements for future versions of
Rainbows!
The Unicorn 3.x series supercedes the 2.x series
while the 1.x series will remain supported indefinitely.
|
|
Some apps may do them, so make sure we do them correctly.
|
|
There's no difference because of the \A anchor, but sub!
is doesn't loop so it's simpler.
|
|
No need to accept any number of args, that could hide bugs in
applications that could give three or more arguments. We also
raise ArgumentError when given a negative length argument to
read.
|
|
Same thing, but might as well make it more obvious.
|
|
This release updates us to the Kgio 2.x series which should play
more nicely with other applications. There are also bugfixes
from the 2.0.1 release and a small bugfix to the new StreamInput
class.
The Unicorn 3.x series will supercede the 2.x series
while the 1.x series will remain supported indefinitely.
|
|
The Kgio 2.x API is less brain-damaged than the 1.3.x series
was, and should solve API-compatibility problems with
dalli 0.11.1.
|
|
* 2.0.x-stable:
unicorn 2.0.1 - fix errors in error handling
tests: add parser error test from Rainbows!
http_server: fix HttpParserError constant resolution
t0012: fix race condition in reload
|
|
This release fixes errors in our own error handling,
causing certain errors to not be logged nor responded
to correctly.
Eric Wong (3):
t0012: fix race condition in reload
http_server: fix HttpParserError constant resolution
tests: add parser error test from Rainbows!
|
|
This will help ensure we trap our own errors properly
in the future.
(cherry picked from commit eda408603edc51f10f17217c767b31a45eb6c627)
|
|
This will help ensure we trap our own errors properly
in the future.
|
|
Any calls to read with an explicit zero length now returns an
empty string. While not explicitly specified by Rack::Lint,
this is for compatibility with StringIO and IO methods which
are common in other web servers.
|
|
"Unicorn" is no longer in the default constant resolution
namespace.
(cherry picked from commit 390e351dd1283d4c80a12b744b1327fff091a141)
|