Skip to main content

Monitor busy thread count - glassfish 3.0.1

3 replies [Last post]
boldt
Offline
Joined: 2011-06-17

Hi,

I'm trying to monitor the number of busy threads on our glassfish instance.

According to http://docs.oracle.com/cd/E19798-01/821-1751/ablvc/index.html the statistics should be available in server.thread-pool.thread-pool.statistic

Doing the following commands in asadmin gives

> get server.thread-pool.*
server.thread-pools.thread-pool.http-thread-pool.classname=com.sun.grizzly.http.StatsThreadPool
server.thread-pools.thread-pool.http-thread-pool.idle-thread-timeout-seconds=900
..

so i should have a thread pool named "http-thread-pool"

Then doing

> get server.thread-pool.http-thread-pool.*
com.sun.enterprise.admin.cli.CommandException: remote failure: Dotted name path server.thread-pool.http-thread-pool.* not found.


Command get failed.

I can't figure the right name to use. I have also enabled monitoring for thread pool and http service in the admin ui of glassfish. Also it frustrates me that all names mentioned in the docs does not seem to be available at my server.

What am I doing wrong and have I misunderstood something

Best Regards
Niels

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
tmueller
Offline
Joined: 2005-10-31

bin/asadmin get server.thread-pools.thread-pool.http-thread-pool.*

Your command is missing the "threads-pools." part.

Tom

boldt
Offline
Joined: 2011-06-17

Tom,

Thanks, you are correct, it gives

asadmin> get server.thread-pools.thread-pool.http-thread-pool.*
server.thread-pools.thread-pool.http-thread-pool.classname=com.sun.grizzly.http.StatsThreadPool
server.thread-pools.thread-pool.http-thread-pool.idle-thread-timeout-seconds=900
server.thread-pools.thread-pool.http-thread-pool.max-queue-size=4096
server.thread-pools.thread-pool.http-thread-pool.max-thread-pool-size=45
server.thread-pools.thread-pool.http-thread-pool.min-thread-pool-size=2
server.thread-pools.thread-pool.http-thread-pool.name=http-thread-pool

But I can see I got messsed up in the names, what I am looking for is the number of busy threads, according to http://docs.oracle.com/cd/E19798-01/821-1751/ablvc/index.html there should exist variables like server.thread-pool.orb.threadpool.http-thread-pool.*, but

asadmin> get server.thread-pool.orb.threadpool.thread-pool-1.*
com.sun.enterprise.admin.cli.CommandException: remote failure: Dotted name path server.thread-pool.orb.threadpool.thread-pool-1.* not found.

the orb object does not seem to exist. This should contain statistics. I can't figure out what I'm missing here

Thanks
Niels

tmueller
Offline
Joined: 2005-10-31

Try using the "-m" option to get. This gets the monitoring values.

Tom