1
0
Fork 0
mirror of https://github.com/puma/puma.git synced 2022-11-09 13:48:40 -05:00
Commit graph

5 commits

Author SHA1 Message Date
Evan Phoenix
bfcd20054e Ignore sockets that are already closed 2012-07-24 17:24:44 -07:00
Evan Phoenix
a3aefc1c51 Don't accidentally replay requests over and over
Client#reset uses the presence of @buffer to detect if there is a
partial next request available. Thusly we have to be sure to nil it out
after we use @buffer otherwise we'll accidentally replay the request
over and over again.
2012-07-24 10:59:09 -07:00
Evan Phoenix
44c8c1ab50 Some minor cleanup 2012-07-23 17:00:53 -07:00
Evan Phoenix
5f2b673ec9 Speed up good, eager clients 2012-07-23 14:29:33 -07:00
Evan Phoenix
6777c771d8 Add separate IO reactor to defeat slow clients
Previously, the app thread would be in charge of reading the request
directly from the client. This resulted in a set of slow clients being
able to completely starve the app thread pool and prevent any further
connections from being handled.

This new organization uses a seperate reactor thread that is in charge
of responding when a client has more data, buffering the data and
attempting to parse the data. When the data represents a fully realized
request, only then is it handed to the app thread pool. This means we
trust apps to not starve the pool, but don't trust clients.
2012-07-23 10:26:52 -07:00