httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Axel-Stéphane SMORGRAV <>
Subject RE: mod_proxy: Is smax=0 allowed ?
Date Wed, 05 Sep 2007 06:58:13 GMT
Seems like you are right about the smax=0.

Luckily for you, according to the documentation you may control the persistency of the backend
connection with the environment variable proxy-nokeepalive just like you can control the persistency
of client connections with the environment variable nokeepalive.


-----Message d'origine-----
De : Phil Endecott [] 
Envoyé : mercredi 5 septembre 2007 00:05
À :
Objet : mod_proxy: Is smax=0 allowed ?

Dear Experts,

According to the mod_proxy docs, parameters to ProxyPass include:

   smax   max   Upto the Soft Maximum number of connections will be 
created on demand.
                Any connections above smax are subject to a time to live or ttl.

So, am I allowed to set smax=0 ?  In my case, I don't want any permanent connections to the
backend server; when the site is being used connections should be created and can persist
for a while and then time out.  So I tried "smax=0 ttl=60".  But I have not seen any connections
being dropped.  So I looked at the source, and in proxy_util.c there is some code that does

if (worker->smax == 0 || worker->smax > worker->hmax) {
   worker->smax = worker->hmax;

So it looks like 0 is a sentinel for "no value specified", and the default of the hard maximum
is applied in that case.  Is this a correct understanding of the code?  If so, is this the
desired behaviour?  Is it possible to keep no permanent connections to the backend server?

Many thanks for any advice.



(I'm subscribed to the digest so I'll see any replies sooner if you Cc: me)

View raw message