I am using tomcat to convert pdf to png. I was using Jmeter to load/throughput test the app using a Intel(R) Xeon(R) CPU X5550 @ 2.67GHz server which has 16 hyper-threaded cores. Tomcat6 had 2gigs of heap memory allocated, and the connector was setup to handle 1000 concurrent connections. During my load testing I discovered that as I increased users the response time degraded which is normal. The load average, however, was very low (around 1 for a 16 core machine), and cpu usage was around 60%. I was monitoring the tomcat instance with jconsole through JMX, and found that memory usage was not an issue. In order to keep the response time low, I created around 8 instances of tomcat on 8 different ports, and have a load balancer balance the load between all 8 ports during my load testing. This time I found that the server was able to handle many more concurrent connections without degraded response time. The load average was also high at 7. So, it seems like tomcat is not using the CPU efficiently when setup with only one instance (I even tried creating multiple connectors on different ports).
It seems like we need to run multiple tomcat instances on a single machine to extract the most performance. Doing this setup is not optimal since creating multiple instances on a pool of servers, and maintaining it will be a pain.
My question is that is it possible to configure tomcat such a way so that a single instance will use as much cpu as possible with a high load average?
Please comment if you have any question about the setup.
I'd appreciate any help/pointer.