11 messages in ru.sysoev.nginxRe: [ANNOUNCE] ngx_http_upstream_keep...
FromSent OnAttachments
Maxim DouninOct 24, 2008 8:21 am 
Maxim DouninOct 24, 2008 8:41 am 
Grzegorz NosekOct 24, 2008 8:57 am 
Maxim DouninOct 24, 2008 9:21 am 
Grzegorz NosekOct 24, 2008 9:33 am 
Maxim DouninOct 24, 2008 9:56 am 
Kon WilmsOct 24, 2008 10:22 am 
Grzegorz NosekOct 24, 2008 10:27 am 
Maxim DouninOct 24, 2008 11:12 am 
Chavelle VincentJan 26, 2009 10:33 am 
Maxim DouninJan 26, 2009 11:40 am 
Actions with this message:
Paste this link in email or IM:
Paste this link in email or IM:
Atom feed for this thread
Paste this URL into your reader:
Subject:Re: [ANNOUNCE] ngx_http_upstream_keepaliveActions...
From:Maxim Dounin (mdou@mdounin.ru)
Date:Oct 24, 2008 9:56:05 am
List:ru.sysoev.nginx

Hello!

On Fri, Oct 24, 2008 at 06:34:00PM +0200, Grzegorz Nosek wrote:

On Fri, Oct 24, 2008 at 08:21:29PM +0400, Maxim Dounin wrote:

On Fri, Oct 24, 2008 at 05:57:40PM +0200, Grzegorz Nosek wrote:

On Fri, Oct 24, 2008 at 07:42:12PM +0400, Maxim Dounin wrote:

In short: it's keepalive upstream balancer module, it may be used to keep connections to memcached alive.

Cool! :)

Feel free to report bugs / success stories. :)

I don't actually use Memcached with Nginx but I _am_ interested in keepalive HTTP/FastCGI connections. It's a great start.

Is there any fundamental problem with supporting e.g. HTTP? Apart from not breaking the HTTP spec and sending Connection: keepalive (or whatever it looks like for HTTP/1.0)?

Not really fundamental. But this will at least require nginx patching.

Couldn't the header get injected in a filter? Or are other changes required?

Request to upstream is created in ngx_http_proxy_module, so no filters there.

You may try to use proxy_set_header though, and then use proxy_hide_header to filter out Keep-Alive header from the response. It may even work - if backend handle HTTP/1.0 keepalive connections and won't try to sent chunked encoding to nginx.

But in fact nginx should be modified to support HTTP/1.1 to backends.

For FastCGI it should be as simple as not setting appropriate close bit in request created by ngx_http_fastcgi_module (and using my patches for connection closing), but I've not checked it yet.