tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David kerber <dcker...@verizon.net>
Subject Re: Performance with many small requests
Date Tue, 12 May 2009 11:54:58 GMT
Peter Crowther wrote:
>> From: David Kerber [mailto:dckerber@verizon.net]
>> I definitely should hook a profiler to the app so I can be sure of
>> what's taking the time, though.
>>     
>
> Yes.  If you don't measure it, you don't know whether you're fixing the right problem!
>   
It was apparent early on that the synchronization was the most limiting 
bottleneck, and that has been mostly corrected thanks to you guys.  Now 
I'm looking at various possibilities for the secondary bottlenecks.

> Also consider connector, then if necessary process and OS limits on the number of concurrent
connections.  Do you usually have connector threads sat idle, or are they all reading and
processing requests most/all of the time?  A thread dump will tell you - the last one you
posted had at least one thread in the pool waiting for a 
Yes, I usually have several waiting on the socket, either at my 
InputStream.read() line, or in some tomcat code that Chuck said was 
waiting for http headers.  However, I still have more completely idle 
(sleeping) threads than I do busy or locked ones at any given time, so 
the servlet seems to be keeping up pretty well overall.  See below, 
though...

> connection, and you can simply spot which others look similar.  The other way to check
would be to monitor the depth of your connector's socket's accept queue, but I'm not aware
of any way to do this in Windows.
>
> At this point, I'm guessing on any remaining bottlenecks.  I recall your network is gigabit
from the router (I think I've recalled correctly), but also check:
>
> - Is the firewall or router overloaded?  Highly unlikely if they're properly specced,
but I have been in one data centre where the bottleneck turned out to be the routers.*
>   
In my original post, I posted a bunch of numbers about network and other 
possible bottlenecks, and what it boiled down to was that neither my 
firewall load, nor total internet connection bandwidth were close to 
their limits.  I do have questions about the number of connections that 
the OS networking stack can handle, but have not figured out how to 
check on that.  I also need to investigate some possible latency (as 
opposed to throughput) issues in my network, given the small request size.

> - What's your external connectivity like?  Gigabit from the router is irrelevant if you're
trying to fit 20 Mbit/s of data down a 10 Mbit/s pipe :-).
The outside world connection is a full T-1, running about 40% - 50% 
capacity on average.

D



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message