We put lately more attention to monitoring and tuning our systems – mainly db.  I tried to refresh in mind how to check active sessions on jvm for specified app. I’ve experimented with VisualVM, but it didn’t satisfied me. I simply does not work out-of-the-box. After registering jmx remote host, I could not expand apps list…

I need something more standard and working then that. I’ve run “jconsole”  (attached to each jdk copy).

Then I’ve connected to:  myFavouriteAppsserver.com:8686

and under the path: com.sun.appserv/Manager/myAwesomeAppName/server/Attributes

I’ve found to variables: activeSessions and sessionCount. Take a look