conditional keep alive
Hello,
does anyone know how to configure apache for a conditional keepAlive
pconn
something like
<if header contains XYZ>
KeepAlive On
MaxKeepAliveRequests 100
KeepAliveTimeout 15
</end header contains ZYX>
Re: conditional keep alive
mazzawi [at] gmail.com wrote:
> does anyone know how to configure apache for a conditional keepAlive
> pconn
>
> something like
>
> <if header contains XYZ>
> KeepAlive On
> MaxKeepAliveRequests 100
> KeepAliveTimeout 15
> </end header contains ZYX>
the special-purpose environment variable 'nokeepalive' can be conditionally set
to disable keepalive connections.
http://httpd.apache.org/docs/2.2/env.html#special
this example uses browsermatch to turn off keepalive for buggy browsers, you
could apply this special-purpose environment variable to other tests:
<IfModule mod_setenvif.c>
BrowserMatch "Mozilla/2" nokeepalive
BrowserMatch "MSIE 4\.0b2;" nokeepalive downgrade-1.0 force-response-1.0
</IfModule>
hth
-sean
--
sean dreilinger - http://durak.org/sean/
Re: conditional keep alive
thanks sean
so what i need is to turn off keep alive if a special http header is
missing say AK=1
browserMatch only works on HTTP_USER_AGENT i need something to match a
custom header
KeepAlive On
MaxKeepAliveRequests 100
KeepAliveTimeout 15
if special header is missing: nokeepalive