org.objectweb.jonas.ha
Class HaServiceImpl

java.lang.Object
  extended by javax.management.NotificationBroadcasterSupport
      extended by org.objectweb.jonas.management.ReconfigDispatcher
          extended by org.objectweb.jonas.service.AbsServiceImpl
              extended by org.objectweb.jonas.ha.HaServiceImpl
All Implemented Interfaces:
javax.management.NotificationBroadcaster, javax.management.NotificationEmitter, HaService, ReconfigDispatcherMBean, Service

public class HaServiceImpl
extends AbsServiceImpl
implements HaService

This class binds the HA service to Jonas and initializes the HA architecture

Author:
Francisco Perez-Sorrosal (fpsorrosal@no-spam@fi.upm.es), Alberto Paz-Jimenez (apaz@no-spam@fi.upm.es), benoit pelletier

Field Summary
 
Fields inherited from class org.objectweb.jonas.management.ReconfigDispatcher
RECONFIG_TYPE, SAVE_RECONFIG_TYPE
 
Constructor Summary
HaServiceImpl()
           
 
Method Summary
 void doInit(javax.naming.Context ctx)
          Abstract initialization method to be implemented by sub-classes
 void doStart()
          Abstract start-up method to be implemented by sub-classes
 void doStop()
          Abstract method for service stopping to be implemented by sub-classes
 java.lang.String getName()
          Returns the service's name
 org.objectweb.carol.cmi.ha.ReplicationManager getReplicationManager()
          Return the replication manager
 boolean isStarted()
          Returns true if the service is started, false otherwise
 void setName(java.lang.String name)
          Set the service's name
 
Methods inherited from class org.objectweb.jonas.service.AbsServiceImpl
getDomainName, getJonasServerName, init, start, stop
 
Methods inherited from class org.objectweb.jonas.management.ReconfigDispatcher
addNotificationListener, getFilter, getHandback, getListener, getNotificationInfo, initLogger, removeNotificationListener, sendReconfigNotification, sendSaveNotification
 
Methods inherited from class javax.management.NotificationBroadcasterSupport
handleNotification, 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.objectweb.jonas.service.Service
init, start, stop
 

Constructor Detail

HaServiceImpl

public HaServiceImpl()
Method Detail

doInit

public void doInit(javax.naming.Context ctx)
            throws ServiceException
Description copied from class: AbsServiceImpl
Abstract initialization method to be implemented by sub-classes

Specified by:
doInit in class AbsServiceImpl
Parameters:
ctx - configuration of the service
Throws:
ServiceException - service initialization failed

doStart

public void doStart()
             throws ServiceException
Description copied from class: AbsServiceImpl
Abstract start-up method to be implemented by sub-classes

Specified by:
doStart in class AbsServiceImpl
Throws:
ServiceException - service start-up failed

doStop

public void doStop()
            throws ServiceException
Description copied from class: AbsServiceImpl
Abstract method for service stopping to be implemented by sub-classes

Specified by:
doStop in class AbsServiceImpl
Throws:
ServiceException - service stopping failed

isStarted

public boolean isStarted()
Description copied from class: AbsServiceImpl
Returns true if the service is started, false otherwise

Specified by:
isStarted in interface Service
Overrides:
isStarted in class AbsServiceImpl
Returns:
true if the service is started

setName

public void setName(java.lang.String name)
Description copied from class: AbsServiceImpl
Set the service's name

Specified by:
setName in interface Service
Overrides:
setName in class AbsServiceImpl
Parameters:
name - the name to set

getName

public java.lang.String getName()
Description copied from class: AbsServiceImpl
Returns the service's name

Specified by:
getName in interface Service
Overrides:
getName in class AbsServiceImpl
Returns:
the service name

getReplicationManager

public org.objectweb.carol.cmi.ha.ReplicationManager getReplicationManager()
Return the replication manager

Specified by:
getReplicationManager in interface HaService
Returns:
Return the replication manager