org.ow2.jonas.ejb2.internal.mbean
Class SessionBean

java.lang.Object
  extended by org.ow2.jonas.lib.management.javaee.ManagedObject
      extended by org.ow2.jonas.lib.management.javaee.J2EEManagedObject
          extended by org.ow2.jonas.ejb2.internal.mbean.EJB
              extended by org.ow2.jonas.ejb2.internal.mbean.SessionBean
Direct Known Subclasses:
StatefulSessionBean, StatelessSessionBean

public class SessionBean
extends EJB

This class implements the SessionBean type specified in JSR77

Author:
Adriana Danes

Field Summary
 
Fields inherited from class org.ow2.jonas.ejb2.internal.mbean.EJB
desc, ejbToManage, fileName
 
Fields inherited from class org.ow2.jonas.lib.management.javaee.J2EEManagedObject
J2EE_TYPE_APPLICATION, J2EE_TYPE_SERVER, NAME
 
Fields inherited from class org.ow2.jonas.lib.management.javaee.ManagedObject
logger
 
Constructor Summary
SessionBean(String objectName, JSessionFactory factoryToManage, JmxService jmx)
           
 
Method Summary
 long getAverageBusinessProcessingTime()
           
 long getAverageProcessingTime()
           
 boolean getMonitoringEnabled()
           
 boolean getMonitoringSettingsDefinedInDD()
           
 long getNumberOfCalls()
           
 int getSessionTimeOut()
          get the session time out for this session ejb
 long getTotalBusinessProcessingTime()
           
 long getTotalProcessingTime()
           
 int getWarningThreshold()
           
 void setMonitoringEnabled(boolean monitoringEnabled)
           
 void setSessionTimeOut(int timeOut)
          set the session time out for this session bean
 void setWarningThreshold(int warningThreshold)
           
 
Methods inherited from class org.ow2.jonas.ejb2.internal.mbean.EJB
getAllDataSourceName, getAllJdbcResourceAdapterName, getAllJMSConnectionFactoryName, getAllJMSDestinationName, getAllMailFactoryMName, getAllMailFactorySName, getAllURLs, getCacheSize, getDisplayName, getEjbClass, getFileName, getHomeClass, getJndiName, getLocalClass, getLocalHomeClass, getMaxCacheSize, getMinPoolSize, getName, getPoolSize, getRemoteClass, reduceCacheSize
 
Methods inherited from class org.ow2.jonas.lib.management.javaee.J2EEManagedObject
getObjectName, isEventProvider, isStateManageable, isStatisticsProvider, setEventProvider, setObjectName, setStateManageable, setStatisticsProvider
 
Methods inherited from class org.ow2.jonas.lib.management.javaee.ManagedObject
sendNotification, sendReconfigNotification, sendSaveNotification, setModelMBean
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SessionBean

public SessionBean(String objectName,
                   JSessionFactory factoryToManage,
                   JmxService jmx)
Parameters:
objectName - JMX object name
factoryToManage - JSessionFactory factory to manage
Method Detail

getSessionTimeOut

public int getSessionTimeOut()
get the session time out for this session ejb

Returns:
integer session time out

setSessionTimeOut

public void setSessionTimeOut(int timeOut)
set the session time out for this session bean

Parameters:
timeOut - new session time out

getMonitoringSettingsDefinedInDD

public boolean getMonitoringSettingsDefinedInDD()
Returns:
true if EJB monitoring settings have been defined in the deployment descriptor

getMonitoringEnabled

public boolean getMonitoringEnabled()
Returns:
true if ejb monitoring active

setMonitoringEnabled

public void setMonitoringEnabled(boolean monitoringEnabled)
Parameters:
monitoringEnabled - whether ejb monitoring will be active

getWarningThreshold

public int getWarningThreshold()
Returns:
the method time threshold (in ms)

setWarningThreshold

public void setWarningThreshold(int warningThreshold)
Parameters:
warningThreshold - new method time threshold (in ms)

getNumberOfCalls

public long getNumberOfCalls()
Returns:
the total number of calls on this ejb

getTotalBusinessProcessingTime

public long getTotalBusinessProcessingTime()
Returns:
the total time spent in business execution

getTotalProcessingTime

public long getTotalProcessingTime()
Returns:
the total time spent in container + business execution

getAverageBusinessProcessingTime

public long getAverageBusinessProcessingTime()
Returns:
the average time per request spent in business execution

getAverageProcessingTime

public long getAverageProcessingTime()
Returns:
the average total time per request spent in container + business execution


Copyright © 2010 OW2 Consortium. All Rights Reserved.