httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ruediger Pluem <rpl...@apache.org>
Subject Re: Speeding up mod_proxy_balancer on Windows
Date Thu, 09 Oct 2008 22:28:43 GMT


On 10/09/2008 11:50 PM, Jess Holle wrote:
> P.S. Yes, I know this approach only has any hope of working when Apache
> and the proxy backends are on the same host.
> 
> Jess Holle wrote:
>> I had previously discovered that mod_proxy_balancer takes over 1
>> second on Windows to determine that nothing is listening on the target
>> port.  This becomes problematic if you are balancing over a sparsely
>> populated set of proxy ports.
>>
>> A Windows guru here found the Windows GetTcpTable which would appear
>> to offer a quicker way to determine a port's status -- whereas doing
>> the obvious thing and attempting to connect takes over a second to fail.
>>
>> I'd like to experiment with using this API to address this issue upon
>> attempted formation of the first connection for a given worker one is
>> balancing over.  Can anyone suggest where I should look to do add such
>> a call?  Eventually this should presumably be an APR-level thing, but
>> in the short term I'm just looking for where I can experiment with
>> inserting it in an #ifdef in the proxy code -- and getting a little
>> lost here, unfortunately.

Did you check whether the currently running thread "proxy_ajp connect timeout fix."
(http://mail-archives.apache.org/mod_mbox/httpd-dev/200810.mbox/%3c580412.14555.qm@web58304.mail.re3.yahoo.com%3e
and
http://mail-archives.apache.org/mod_mbox/httpd-dev/200810.mbox/%3c48EE6D0A.3040702@apache.org%3e)
does fix your issue on Windows?
If httpd and the backends are running on the same machine this shouldn't take
a second. The connect call should return immediately with an error code indicating
that the connection was refused (if the port is down). If not is it possible that there
is a local firewall that causes this trouble?

Regards

RĂ¼diger

Mime
View raw message