Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.jboss.management.j2ee.cluster
Class HAManagementService

    java.lang.Object
      org.jboss.mx.util.JBossNotificationBroadcasterSupport
          org.jboss.system.ServiceMBeanSupport
              org.jboss.management.j2ee.cluster.HAManagementService

All Implemented Interfaces:
  HAManagementServiceMBean, javax.management.MBeanRegistration, javax.management.NotificationBroadcaster, javax.management.NotificationEmitter, org.jboss.system.Service, org.jboss.system.ServiceMBean

public class HAManagementService
extends org.jboss.system.ServiceMBeanSupport
implements HAManagementServiceMBean

This class enables a client to get a management view (JSR-77) on a JBoss Cluster. It contains the entire logic to map all the {@link org.jboss.management.j2ee.J2EEManagedObject Managed Object (MO) of all the nodes in the cluster to one MO. The same applies to State Management and Performance Statistics.

Version:
  $Revision: 1.7 $

Author:
  Andreas Schaefer

Field Summary

Fields inherited from class org.jboss.system.ServiceMBeanSupport
`log, server, SERVICE_CONTROLLER_SIG, serviceName`

Fields inherited from interface org.jboss.system.ServiceMBean
`CREATE_EVENT, CREATED, DESTROY_EVENT, DESTROYED, FAILED, REGISTERED, START_EVENT, STARTED, STARTING, states, STOP_EVENT, STOPPED, STOPPING, UNREGISTERED`

Constructor Summary
`HAManagementService()` Creates a undefined clustering management service.

Method Summary
`Object` | `_createMBean(String pClass, javax.management.ObjectName pName, Object[] pParameters, String[] pSignature)`
`Object` | `_getAttribute(javax.management.ObjectName pName, String pAttribute)`
`javax.management.AttributeList` | `_getAttributes(javax.management.ObjectName pName, String[] pAttributes)`
`Object` | `_invoke(javax.management.ObjectName pName, String pOperationName, Object[] pParams, String[] pSignature)`
`Object` | `_setAttribute(javax.management.ObjectName pName, javax.management.Attribute pAttribute)`
`Object` | `_setAttributes(javax.management.ObjectName pName, javax.management.AttributeList pAttributes)`
`Object` | `_unregisterMBean(javax.management.ObjectName pName)`
`void` | `addNotificationListener(javax.management.ObjectName pBroadcaster, javax.management.ObjectName pListener, javax.management.NotificationFilter pFilter, Object pHandback)`
`javax.management.ObjectInstance` | `createMBean(String pClass, javax.management.ObjectName pName, Object[] pParameters, String[] pSignature)`
`protected void` | `createService()` Looks up the Server Config instance to figure out the temp-directory and the farm-deploy-directory
`Object` | `getAttribute(javax.management.ObjectName pName, String pAttribute)`
`javax.management.AttributeList` | `getAttributes(javax.management.ObjectName pName, String[] pAttributes)`
`String` | `getDefaultDomain()`
`javax.management.j2ee.ListenerRegistration` | `getListenerRegistry()`
`Integer` | `getMBeanCount()`
`javax.management.MBeanInfo` | `getMBeanInfo(javax.management.ObjectName pName)`
`String` | `getName()`
`Object` | `invoke(javax.management.ObjectName pName, String pOperationName, Object[] pParams, String[] pSignature)`
`boolean` | `isRegistered(javax.management.ObjectName pName)`
`void` | `preDeregister()` Removes the Notification Listener
`javax.management.ObjectName` | `preRegister(javax.management.MBeanServer pServer, javax.management.ObjectName pName)` Saves the MBeanServer reference
`Set` | `queryNames(javax.management.ObjectName pName, javax.management.QueryExp pQuery)`
`void` | `removeNotificationListener(javax.management.ObjectName pBroadcaster, javax.management.ObjectName pListener)`
`void` | `setAttribute(javax.management.ObjectName pName, javax.management.Attribute pAttribute)`
`javax.management.AttributeList` | `setAttributes(javax.management.ObjectName pName, javax.management.AttributeList pAttributes)`
`protected void` | `startService()` Register itself as RPC-Handler to the HA-Partition and add the farm deployment directory to the scanner
`protected void` | `stopService()` Remove the farm deployment directory from the scanner
`void` | `unregisterMBean(javax.management.ObjectName pName)`

Methods inherited from class org.jboss.system.ServiceMBeanSupport
`create, destroy, destroyService, getLog, getNextNotificationSequenceNumber, getObjectName, getServer, getServiceName, getState, getStateString, jbossInternalCreate, jbossInternalDescription, jbossInternalDestroy, jbossInternalLifecycle, jbossInternalStart, jbossInternalStop, postDeregister, postRegister, start, stop`

Methods inherited from class org.jboss.mx.util.JBossNotificationBroadcasterSupport
`addNotificationListener, getNotificationInfo, handleNotification, removeNotificationListener, removeNotificationListener, sendNotification`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface org.jboss.system.ServiceMBean
`getState, getStateString, jbossInternalLifecycle`

Methods inherited from interface org.jboss.system.Service
`create, destroy, start, stop`

Constructor Detail

### HAManagementService

    public HAManagementService()

  Creates a undefined clustering management service. Before this MBean can be started the HAPartition must be up and running.

  ATTENTION: The current implemenation is a brute force one because it is retrieving the data on every hit. Later on this has to be resolved with a caching to avoid unecessary round-trips.

Method Detail

### _getAttribute

    public Object _getAttribute(javax.management.ObjectName pName,
                                String pAttribute)

### getAttribute

    public Object getAttribute(javax.management.ObjectName pName,
                               String pAttribute)
                        throws javax.management.MBeanException,
                               javax.management.AttributeNotFoundException,
                               javax.management.InstanceNotFoundException,
                               javax.management.ReflectionException,
                               RemoteException

  Specified by:
    `getAttribute` in interface `HAManagementServiceMBean`
  Throws:
    `javax.management.MBeanException`
    `javax.management.AttributeNotFoundException`
    `javax.management.InstanceNotFoundException`
    `javax.management.ReflectionException`
    `RemoteException`

### _getAttributes

    public javax.management.AttributeList _getAttributes(javax.management.ObjectName pName,
                                                         String[] pAttributes)

### getAttributes

    public javax.management.AttributeList getAttributes(javax.management.ObjectName pName,
                                                        String[] pAttributes)
                                                 throws javax.management.InstanceNotFoundException,
                                                        javax.management.ReflectionException,
                                                        RemoteException

  Specified by:
    `getAttributes` in interface `HAManagementServiceMBean`
  Throws:
    `javax.management.InstanceNotFoundException`
    `javax.management.ReflectionException`
    `RemoteException`

### getDefaultDomain

    public String getDefaultDomain()
                            throws RemoteException

  Specified by:
    `getDefaultDomain` in interface `HAManagementServiceMBean`
  Throws:
    `RemoteException`

### getMBeanCount

    public Integer getMBeanCount()
                          throws RemoteException

  Specified by:
    `getMBeanCount` in interface `HAManagementServiceMBean`
  Throws:
    `RemoteException`

### getMBeanInfo

    public javax.management.MBeanInfo getMBeanInfo(javax.management.ObjectName pName)
                                            throws javax.management.IntrospectionException,
                                                   javax.management.InstanceNotFoundException,
                                                   javax.management.ReflectionException,
                                                   RemoteException

  Specified by:
    `getMBeanInfo` in interface `HAManagementServiceMBean`
  Throws:
    `javax.management.IntrospectionException`
    `javax.management.InstanceNotFoundException`
    `javax.management.ReflectionException`
    `RemoteException`

### getListenerRegistry

    public javax.management.j2ee.ListenerRegistration getListenerRegistry()
                                                                   throws RemoteException

  Specified by:
    `getListenerRegistry` in interface `HAManagementServiceMBean`
  Throws:
    `RemoteException`

### _invoke

    public Object _invoke(javax.management.ObjectName pName,
                          String pOperationName,
                          Object[] pParams,
                          String[] pSignature)

### invoke

    public Object invoke(javax.management.ObjectName pName,
                         String pOperationName,
                         Object[] pParams,
                         String[] pSignature)
                  throws javax.management.InstanceNotFoundException,
                         javax.management.MBeanException,
                         javax.management.ReflectionException,
                         RemoteException

  Specified by:
    `invoke` in interface `HAManagementServiceMBean`
  Throws:
    `javax.management.InstanceNotFoundException`
    `javax.management.MBeanException`
    `javax.management.ReflectionException`
    `RemoteException`

### isRegistered

    public boolean isRegistered(javax.management.ObjectName pName)
                         throws RemoteException

  Specified by:
    `isRegistered` in interface `HAManagementServiceMBean`
  Throws:
    `RemoteException`

### queryNames

    public Set queryNames(javax.management.ObjectName pName,
                          javax.management.QueryExp pQuery)
                   throws RemoteException

  Specified by:
    `queryNames` in interface `HAManagementServiceMBean`
  Throws:
    `RemoteException`

### _setAttribute

    public Object _setAttribute(javax.management.ObjectName pName,
                                javax.management.Attribute pAttribute)

### setAttribute

    public void setAttribute(javax.management.ObjectName pName,
                             javax.management.Attribute pAttribute)
                      throws javax.management.AttributeNotFoundException,
                             javax.management.InstanceNotFoundException,
                             javax.management.InvalidAttributeValueException,
                             javax.management.MBeanException,
                             javax.management.ReflectionException,
                             RemoteException

  Specified by:
    `setAttribute` in interface `HAManagementServiceMBean`
  Throws:
    `javax.management.AttributeNotFoundException`
    `javax.management.InstanceNotFoundException`
    `javax.management.InvalidAttributeValueException`
    `javax.management.MBeanException`
    `javax.management.ReflectionException`
    `RemoteException`

### _setAttributes

    public Object _setAttributes(javax.management.ObjectName pName,
                                 javax.management.AttributeList pAttributes)

### setAttributes

    public javax.management.AttributeList setAttributes(javax.management.ObjectName pName,
                                                        javax.management.AttributeList pAttributes)
                                                 throws javax.management.InstanceNotFoundException,
                                                        javax.management.ReflectionException,
                                                        RemoteException

  Specified by:
    `setAttributes` in interface `HAManagementServiceMBean`
  Throws:
    `javax.management.InstanceNotFoundException`
    `javax.management.ReflectionException`
    `RemoteException`

### _createMBean

    public Object _createMBean(String pClass,
                               javax.management.ObjectName pName,
                               Object[] pParameters,
                               String[] pSignature)

### createMBean

    public javax.management.ObjectInstance createMBean(String pClass,
                                                       javax.management.ObjectName pName,
                                                       Object[] pParameters,
                                                       String[] pSignature)
                                                throws javax.management.InstanceAlreadyExistsException,
                                                       javax.management.MBeanException,
                                                       javax.management.MBeanRegistrationException,
                                                       javax.management.NotCompliantMBeanException,
                                                       javax.management.ReflectionException,
                                                       RemoteException

  Specified by:
    `createMBean` in interface `HAManagementServiceMBean`
  Throws:
    `javax.management.InstanceAlreadyExistsException`
    `javax.management.MBeanException`
    `javax.management.MBeanRegistrationException`
    `javax.management.NotCompliantMBeanException`
    `javax.management.ReflectionException`
    `RemoteException`

### _unregisterMBean

    public Object _unregisterMBean(javax.management.ObjectName pName)

### unregisterMBean

    public void unregisterMBean(javax.management.ObjectName pName)
                         throws javax.management.InstanceNotFoundException,
                                javax.management.MBeanRegistrationException,
                                RemoteException

  Specified by:
    `unregisterMBean` in interface `HAManagementServiceMBean`
  Throws:
    `javax.management.InstanceNotFoundException`
    `javax.management.MBeanRegistrationException`
    `RemoteException`

### addNotificationListener

    public void addNotificationListener(javax.management.ObjectName pBroadcaster,
                                        javax.management.ObjectName pListener,
                                        javax.management.NotificationFilter pFilter,
                                        Object pHandback)
                                 throws javax.management.InstanceNotFoundException,
                                        RemoteException

  Specified by:
    `addNotificationListener` in interface `HAManagementServiceMBean`
  Throws:
    `javax.management.InstanceNotFoundException`
    `RemoteException`

### removeNotificationListener

    public void removeNotificationListener(javax.management.ObjectName pBroadcaster,
                                           javax.management.ObjectName pListener)
                                    throws javax.management.InstanceNotFoundException,
                                           javax.management.ListenerNotFoundException,
                                           RemoteException

  Specified by:
    `removeNotificationListener` in interface `HAManagementServiceMBean`
  Throws:
    `javax.management.InstanceNotFoundException`
    `javax.management.ListenerNotFoundException`
    `RemoteException`

### preRegister

    public javax.management.ObjectName preRegister(javax.management.MBeanServer pServer,
                                                   javax.management.ObjectName pName)
                                            throws Exception

  Saves the MBeanServer reference

  Specified by:
    `preRegister` in interface `javax.management.MBeanRegistration`
  Throws:
    `Exception`

### preDeregister

    public void preDeregister()
                       throws Exception

  Removes the Notification Listener

  Specified by:
    `preDeregister` in interface `javax.management.MBeanRegistration`
  Throws:
    `Exception`

### getName

    public String getName()

  Specified by:
    `getName` in interface `org.jboss.system.ServiceMBean`

### createService

    protected void createService()
                          throws Exception

  Looks up the Server Config instance to figure out the temp-directory and the farm-deploy-directory

  Throws:
    `Exception`

### startService

    protected void startService()
                         throws Exception

  Register itself as RPC-Handler to the HA-Partition and add the farm deployment directory to the scanner

  Throws:
    `Exception`

### stopService

    protected void stopService()

  Remove the farm deployment directory from the scanner

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2002 JBoss Group, LLC. All Rights Reserved.