org.glassfish.admin.amx.impl.j2ee
Class DASJ2EEServerImpl

java.lang.Object
  extended by org.glassfish.admin.amx.impl.mbean.MBeanImplBase
      extended by org.glassfish.admin.amx.impl.mbean.AMXImplBase
          extended by org.glassfish.admin.amx.impl.j2ee.J2EEManagedObjectImplBase
              extended by org.glassfish.admin.amx.impl.j2ee.J2EELogicalServerImplBase
                  extended by org.glassfish.admin.amx.impl.j2ee.J2EEServerImpl
                      extended by org.glassfish.admin.amx.impl.j2ee.DASJ2EEServerImpl
All Implemented Interfaces:
EventListener, DynamicMBean, MBeanRegistration, NotificationBroadcaster, NotificationEmitter, NotificationListener, AMX_SPI, NotificationSender

public class DASJ2EEServerImpl
extends J2EEServerImpl
implements NotificationListener

JSR 77 extension representing an Appserver standalone server (non-clustered) Server MBean which will reside on DAS for enabling state management including start() and stop()


Field Summary
 
Fields inherited from class org.glassfish.admin.amx.impl.j2ee.J2EEServerImpl
INTF, J2EE_RESOURCE_TYPES
 
Fields inherited from class org.glassfish.admin.amx.impl.j2ee.J2EEManagedObjectImplBase
mStartTime
 
Fields inherited from class org.glassfish.admin.amx.impl.mbean.AMXImplBase
EMPTY_OBJECT_NAMES, GET, GET_PREFIX, mMBeanInfo, OBJECT_NAME_SUFFIX, SET
 
Fields inherited from class org.glassfish.admin.amx.impl.mbean.MBeanImplBase
EMPTY_STRING_ARRAY, mSelfObjectName, mServer
 
Constructor Summary
DASJ2EEServerImpl(ObjectName parentObjectName, Metadata meta)
           
 
Method Summary
protected  String getServerName()
           
 int getstate()
          Convert an internal status code to JSR 77 StateManageable state.
 void handleNotification(Notification notif, Object ignore)
           
 boolean isstateManageable()
           
protected  void registerChildren()
           
 void start()
           
 void startRecursive()
           
 void stop()
           
 
Methods inherited from class org.glassfish.admin.amx.impl.j2ee.J2EEServerImpl
getjavaVMs, getjvm, getresources, getserverVendor, getserverVersion, unregisterChildren
 
Methods inherited from class org.glassfish.admin.amx.impl.j2ee.J2EELogicalServerImplBase
startApp, stopApp
 
Methods inherited from class org.glassfish.admin.amx.impl.j2ee.J2EEManagedObjectImplBase
defaultChildMetadata, getChildrenAsStrings, getChildrenAsStrings, getCorrespondingConfig, getdeployedObjects, getDomain, getExtraObjectNameProps, getJ2EEServer, getMEJB, getobjectName, getServerObjectName, getstartTime, iseventProvider, isstatisticsProvider, j2eeType, metadata, preRegisterModifyName
 
Methods inherited from class org.glassfish.admin.amx.impl.mbean.AMXImplBase
attributeNameToType, attributeTypeMatches, cdebug, child, child, child, findGetter, findMethod, findSetter, getAncestorByType, getAttribute, getAttributeByMethod, getAttributeInfo, getAttributeInfos, getAttributeInternal, getAttributeManually, getAttributeNames, getAttributeNoThrow, getAttributes, getAttributeType, getChildren, getChildren, getChildren, getChildren, getChildrenMap, getDomainRoot, getDomainRootProxy, getLogger, getMBeanInfo, getMBeanTracker, getName, getNotificationInfo, getObjectNameAttribute, getObjectNames, getObjectNamesForAttribute, getParent, getParentProxy, getProxy, getProxyFactory, getSelf, getSelf, getterNameMatches, handleException, handleGetAttributeException, handleInvokeThrowable, impossible, invoke, invokeManually, isReadOnlyAttribute, isUtilityMBean, java, operationNameMatches, postRegisterHook, postRegisterModifyMBeanInfo, preDeregisterHook, preRegister, preRegisterDone, preRegisterHook, registerChild, sendAttributeChangeNotification, setAttribute, setAttributeByMethod, setAttributeInternal, setAttributeManually, setAttributes, shouldEmitNotifications, stringify, supportsChildren, toString, unimplementedAttribute, unimplementedOperation
 
Methods inherited from class org.glassfish.admin.amx.impl.mbean.MBeanImplBase
_getMBeanLogLevel, addNotificationListener, addNotificationListener, createNotificationBuilder, debug, debug, debugMethod, debugMethod, enableAMXDebug, getAMXDebug, getDebugID, getDebugOutput, getJMXDomain, getListenerCount, getMBeanLogger, getMBeanLoggerName, getMBeanLogLevel, getMBeanLogLevelInt, getMBeanServer, getNotificationBuilder, getNotificationEmitter, getNotificationTypeListenerCount, getObjectName, logFine, logFiner, logFinest, logInfo, logSevere, logWarning, postDeregister, postDeregisterHook, postRegister, preDeregister, quote, removeNotificationListener, removeNotificationListener, sendNotification, sendNotification, sendNotification, sendNotification, setAMXDebug, setMBeanLogLevel, shouldOmitObjectNameForDebug, sleepMillis, toString, trace
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface javax.management.MBeanRegistration
postDeregister, postRegister, preDeregister
 
Methods inherited from interface javax.management.NotificationEmitter
removeNotificationListener
 
Methods inherited from interface javax.management.NotificationBroadcaster
addNotificationListener, removeNotificationListener
 

Constructor Detail

DASJ2EEServerImpl

public DASJ2EEServerImpl(ObjectName parentObjectName,
                         Metadata meta)
Method Detail

registerChildren

protected void registerChildren()
Overrides:
registerChildren in class J2EEServerImpl

handleNotification

public void handleNotification(Notification notif,
                               Object ignore)
Specified by:
handleNotification in interface NotificationListener

getServerName

protected String getServerName()
Overrides:
getServerName in class J2EEManagedObjectImplBase

isstateManageable

public boolean isstateManageable()
Overrides:
isstateManageable in class J2EEManagedObjectImplBase

getstate

public int getstate()
Convert an internal status code to JSR 77 StateManageable state. private static int serverStatusCodeToStateManageableState( final int statusCode ) { int state = STATE_FAILED; switch( statusCode ) { default: throw new IllegalArgumentException( "Uknown status code: " + statusCode ); case Status.kInstanceStartingCode: state = STATE_STARTING; break; case Status.kInstanceRunningCode: state = STATE_RUNNING; break; case Status.kInstanceStoppingCode: state = STATE_STOPPING; break; case Status.kInstanceNotRunningCode: state = STATE_STOPPED; break; } return state; }

Overrides:
getstate in class J2EELogicalServerImplBase

start

public void start()
Overrides:
start in class J2EELogicalServerImplBase

startRecursive

public void startRecursive()
Overrides:
startRecursive in class J2EELogicalServerImplBase

stop

public void stop()
Overrides:
stop in class J2EELogicalServerImplBase


Copyright © 2012. All Rights Reserved.