users@glassfish.java.net

GlassFish v2.1.1 hangs periodically under moderate load

From: Allan Lykke Christensen <allan_at_i2m.dk>
Date: Tue, 22 Mar 2011 13:42:22 +0100

List,

I've got a Java EE 5 application running on GlassFish v2.1.1 that
hangs periodically (at least 2 -3 times a day).To get it running again
I have to kill the Glassfish process and start the domain again. The
application usually gets slower and slower at responding until it
finally hangs. Once it has hung I can't get a thread stack. I've been
able to get a thread stack as it gets slower and slower but I can't
seem to locate the problem or the threads that have hung.

I use an XML-RPC client and Solr4J in my EJBs and I'm wondering if
these APIs some how are causing the problems.

With little load on the system it never hangs, it is when there is a
moderate load (40 - 100 user sessions) that it starts hanging.

I've attached a thread dump from yesterday and my domain
configuration. You'll see that there are some MySQL queries going on.
I believe these are genuine threads completing running queries.

Spec:
Quad core CPU XEON 4Ghz 64 bit
Ubuntu Server 10.04 - 64 bit
java version "1.6.0_22"
Java(TM) SE Runtime Environment (build 1.6.0_22-b04)
Java HotSpot(TM) 64-Bit Server VM (build 17.1-b03, mixed mode)