JConsole: Thread
When using JConsole to monitor the Java application, I noticed that there is total of 8000 started threads, 66 peak threads and 34 live threads.
The 8000 started threads is what I concern now... does this telling me something wrong with the application? How can I find out which are the threads that created the most? and what are the current Peak and Live threads?
Hi,
To see what the live threads are, you can click on them in JConsole Threading
tab. You will be able to see their stack trace, and it can give you an idea of
where they come from.
I am not sure whether seeing 8000 started thread indicates that something
is wrong wtith the application. It depends on what kind of application it is, and
over which period of time the 8000 thread were created.
It could indicate however that the application code may be optimized,
by e.g. using java.util.concurrent.ExecutorService instead of simply calling
new Thread().
Hope this helps,
-- daniel
JMX, SNMP, Java, etc..
http://blogs.sun.com/jmxetc