[Web-SIG] question about connection pool, task queue in WSGI

Simon Sapin simon.sapin at exyr.org
Sun Jul 15 17:14:35 CEST 2012

Le 14/07/2012 06:07, Graham Dumpleton a écrit :
>>> >>2. Is the socket FD the same mechanism like nginx? If you upgrade nginx
>>> >>binary, restart nginx, the existing http connection won't break.
> I would be very surprised if you could upgrade nginx, perform a
> restart and preserve the HTTP listener socket. If you are talking
> about some other socket I don't know what you are talking about.
> As you can with Apache, you can likely enact a configuration file
> change and perform a restart or trigger rereading of the configuration
> and it would maintain the HTTP listener socket across the
> configuration restart, but an upgrade implies changing the binary and
> I know no way that you could easily persist a HTTP listener socket
> across to an invocation of a new web server instance using a new
> executable. In Apache you certainly cannot do it, and unless nginx has
> some magic where the existing nginx execs the new nginx version and
> somehow communicates through open socket connections to the new
> process, I very much doubt it would as it would be rather messy to do
> so.

I think that est refers to this:

Apparently yes, there is specific code in nginx to start the new binary 
and give it the existing socket.

And I think that yes, Tarek’s new Circus is similar to the nginx magic 
upgrade in that an open socket is passed around processes. Maybe nginx 
even does this in normal operation with multiple worker processes, but I 
don’t know.

Simon Sapin

More information about the Web-SIG mailing list