tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kevin <ke...@infofinity.com>
Subject Errant slow request
Date Sun, 05 Sep 2010 02:19:29 GMT
  Hi, I'm using Apache Bench (ab) to send 1,000 requests with a 
concurrency of 500 to a simple servlet on Tomcat trunk (revision 992708, 
2010-09-03) which uses request.startAsync() and 
Executors.newFixedThreadPool(10) to do the work and return a few bytes 
of response and asyncContext.complete().

What I'm noticing is that every once in a while there is an errant 
request that takes up to 10 seconds, while the average is around half a 
second. I've reproduced this on both Oracle and IBM JVMs. I've looked at 
verbosegc and see no anomalies in pause times or heap usage. I've taken 
javadumps and I don't see any thread that is obviously "stuck" anywhere. 
Most importantly, if I compare this to a servlet that writes the same 
bytes but synchronously (i.e. a "classic" servlet service() method), 
then I don't see this aberration.

I can see these long requests in my access log by changing 
org.apache.catalina.valves.AccessLogValve to "%h %l %u %t &quot;%r&quot; 
%s %b %D", e.g.:

127.0.0.1 - - [04/Sep/2010:18:46:20 -0700] "GET /myapp/ HTTP/1.0" 500 
207 10986
127.0.0.1 - - [04/Sep/2010:18:46:22 -0700] "GET /myapp/ HTTP/1.0" 500 
207 10428
127.0.0.1 - - [04/Sep/2010:18:46:22 -0700] "GET /myapp/ HTTP/1.0" 500 
207 10347

My question is: how do I debug these 500 errors?
Thanks.

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


Mime
View raw message