Zbatery/Rainbows keepalive problem?
normalperson at yhbt.net
Sun Nov 28 05:07:05 EST 2010
Jake Douglas <jakecdouglas at gmail.com> wrote:
> After some more experimentation, it looks like the browser(s) fail to
> close the connection after receiving the responses. Zbatery then waits
> until the keepalive_timeout has expired, closes it, and accepts the
> next connection. I gave the same application a try using Thin with
> keep-alive and everything works fine. I spent a lot of time trying to
> identify differences between the two, but the only useful thing I
> managed to find is that the browser side never sends a FIN-ACK when
> talking to Zbatery. For some reason, the browser doesn't think it's
> finished. Any suggestions appreciated.
A shot in the dark, but I wonder if web browsers do anything special
with the Server: header with regard to keepalive. Off the top of my
head, I know Thin includes the "Server:" header in all responses while
Rainbows! does not.
Can you try loading the Rainbows::ServerToken middleware to add
the Server header?
use Rainbows::ServerToken, "foo/bar"
Any other differences in the headers the two servers send?
 - from what I can tell, rfc2616 does not require the Server: token,
and recommends it to be configurable.
More information about the rainbows-talk