If your site CPU utilization is close to 100%, you can use a Java profiler tool like JProfiler or JProbe Profiler to help determine slow points of your code.

In some instances, profilers cannot handle large sites running under load. If so, another way to identify deadlocks and bottlenecks is to get your JVM to dump out stack traces while your system is under load. If you examine 5 or 10 of these stack traces, you can start to see a pattern and find places in your site that are consuming CPU resources or causing deadlocks.

An alternative to stack dumps is the HPROF utility provided with the JDK. See Sun’s Java documentation for information on this utility.

loading table of contents...