org.jboss.ha.singleton
Interface HASingletonMBean

All Superinterfaces:
HAServiceMBean (src) , NotificationBroadcaster (src) , Service (src) , ServiceMBean (src)
All Known Subinterfaces:
HASingletonControllerMBean (src)
All Known Implementing Classes:
HASingletonController (src) , HASingletonSupport (src)

public interface HASingletonMBean
extends HAServiceMBean (src)

HA-Singleton interface. Only one mbean is active at any point of time cluster-wide.

The abstract service provides a simple way for a concrete mbeans to detect whether or not it is the active one in the cluster.

Concrete mbeans would usually do activities like regular clean up of database tables or saving statistics about cluster usage.


Field Summary
 
Fields inherited from interface org.jboss.system.ServiceMBean (src)
CREATE_EVENT, CREATED, DESTROY_EVENT, DESTROYED, FAILED, REGISTERED, START_EVENT, STARTED, STARTING, states, STOP_EVENT, STOPPED, STOPPING, UNREGISTERED
 
Method Summary
 boolean isMasterNode()
           
 
Methods inherited from interface org.jboss.ha.jmx.HAServiceMBean (src)
callMethodOnPartition, getDistributedState, getPartitionName, sendNotification, setDistributedState, setPartitionName
 
Methods inherited from interface org.jboss.system.ServiceMBean (src)
getName, getState, getStateString, jbossInternalLifecycle
 
Methods inherited from interface org.jboss.system.Service (src)
create, destroy, start, stop
 
Methods inherited from interface javax.management.NotificationBroadcaster (src)
addNotificationListener, getNotificationInfo, removeNotificationListener
 

Method Detail

isMasterNode

public boolean isMasterNode()
Returns:
true if this cluster node has the active mbean singleton. false otherwise