This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes BEA/Weblogic and the fly likes Total Active Sessions Count - URGENT Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Products » BEA/Weblogic
Bookmark "Total Active Sessions Count - URGENT" Watch "Total Active Sessions Count - URGENT" New topic
Author

Total Active Sessions Count - URGENT

Nehal Dave
Greenhorn

Joined: Dec 22, 2000
Posts: 28
I need to know how many sessions are active at a perticular time in weblogic 5.1/6.x servers. I coudnt find any reference in 5.1 doc. In 6.x docs i could found out the following things..
public interface WebAppComponentRuntimeMBean which
extends weblogic.management.runtime.RuntimeMBean has a method called getOpenSessionsCurrentCount()
which returns ant int... It returns the current total number of open sessions in this component. The prob is as its an interface how do i call the method.....
Steve Chernyak
Ranch Hand

Joined: Oct 19, 2000
Posts: 113
Seems like that information should be available from the console.
However, if you need to do it programmatically, then I would look at the WebLogic JMX documentation. Since the name of the interface you mention ends in "MBean", you can get attribute values from objects that implement it by communicating with the WebLogic JMX Server.
SteveC
Chana Campos
Greenhorn

Joined: Jun 09, 2002
Posts: 19
Not only is it available from the console, but there's more too...

In 6.1 go to the web application tab and select the application you want to see. Select "Monitoring" - select "Enable Session Monitoring". Then click on the link below for Monitoring Sessions. You can also monitor SFSB, SLSB, EJBs, JMS messages, the same way. You may have to restart your server to see them though...
Best wishes,
Chana
Nehal Dave
Greenhorn

Joined: Dec 22, 2000
Posts: 28
SteveC U r rite.. i need to find out the class which implements the interface weblogic.management.runtime.RuntimeMBean But i wassnt able to find it.. Here is what i am looking for... I want to track the active sessions .. & the count of it. I know its simple to have a counter in DB But i want to know if weblogic provides an API for it.. As it lets us moniter sessions in console.. I tried to find it out every where but no luck ....
U guys have any idea ???
Steve Chernyak
Ranch Hand

Joined: Oct 19, 2000
Posts: 113
What version of Weblogic are you using?
If its 6.0 I think this would be a good starting point:
http://e-docs.bea.com/wls/docs60/isv/program.html
Looks like you will have to use the MBeanHome and then get a list of the MBeans available, then figure out which one has the info you are looking for.
I am almost positive that there is a better way to find out which bean you need, I just don't know it.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Total Active Sessions Count - URGENT
 
Similar Threads
Getting information from WebLogic
some ejb problems
session questions
How many Session Objects ??
How to count the amount of open sessions on Webshere?