
Don't worry, I'm planning for SPDY and WebSockets as well :)
On Wed, Sep 18, 2013 at 12:40 PM, Bardur Arantsson
On 2013-09-18 17:45, Jeremy Shaw wrote:
The problem is that the client is allowed to send an unlimited number of Requests before it bothers to read any Responses.
If your server uses the model of read a single Request and send the Response entirely before moving onto the next Request, then you could potentially deadlock because the client is still in the sending phase and you are blocked on a write().
So, we are basically forced to read all the Requests before sending a Response? But, then the client could perform a DoS by sending millions of requests..
Any thoughts on how best to handle this?
Implement SPDY instead or wait for HTTP 2.0 :).
This is of course somewhat tongue-in-cheek, but really HTTP pipelining is notoriously complicated to get right and not sufficient for actually achieving what one wants. Multiplexing as in SPDY is much saner and based on actual use cases, admittedly from the "browser" portion of the HTTP client ecosystem, but actual use cases nonetheless.
(Not saying that SDPY is all roses, btw, but that's irrelevant to this discussion.)
If it were me, I'd simply not support HTTP pipelining.
_______________________________________________ web-devel mailing list web-devel@haskell.org http://www.haskell.org/mailman/listinfo/web-devel