org.objectweb.proactive.core.body.ft.servers.faultdetection
Class FaultDetectorImpl

java.lang.Object
  extended byorg.objectweb.proactive.core.body.ft.servers.faultdetection.FaultDetectorImpl
All Implemented Interfaces:
FaultDetector, java.rmi.Remote

public class FaultDetectorImpl
extends java.lang.Object
implements FaultDetector

An implementation of the FaultDetector

Author:
cdelbe

Field Summary
protected static org.apache.log4j.Logger logger
           
 
Fields inherited from interface org.objectweb.proactive.core.body.ft.servers.faultdetection.FaultDetector
IS_DEAD, OK
 
Constructor Summary
FaultDetectorImpl(FTServer server, long faultDetectPeriod)
           
 
Method Summary
 void forceDetection()
          Force a failure detection even if the failure detector thread is waiting.
 void initialize()
          Reinit the state of the fault detector
 boolean isUnreachable(UniversalBody body)
          The fault detector test the reachability of the active object body by sending a heartbeat message to body.
 void startFailureDetector()
          Start the tread that periodically test the reachability of objects that are registred in the location server ls.
 void stopFailureDetector()
          Stop the the failure detector thread.
 void suspendFailureDetector()
          Temporarily suspend the failure detector thread.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

logger

protected static org.apache.log4j.Logger logger
Constructor Detail

FaultDetectorImpl

public FaultDetectorImpl(FTServer server,
                         long faultDetectPeriod)
Method Detail

isUnreachable

public boolean isUnreachable(UniversalBody body)
                      throws java.rmi.RemoteException
Description copied from interface: FaultDetector
The fault detector test the reachability of the active object body by sending a heartbeat message to body.

Specified by:
isUnreachable in interface FaultDetector
Parameters:
body - the tested active object
Returns:
true if body is unreachable, false otherwise
Throws:
java.rmi.RemoteException
See Also:
FaultDetector.isUnreachable(org.objectweb.proactive.core.body.UniversalBody)

startFailureDetector

public void startFailureDetector()
                          throws java.rmi.RemoteException
Description copied from interface: FaultDetector
Start the tread that periodically test the reachability of objects that are registred in the location server ls. If a failure is detected, the recovery process must be noticed.

Specified by:
startFailureDetector in interface FaultDetector
Throws:
java.rmi.RemoteException
See Also:
FaultDetector.startFailureDetector()

suspendFailureDetector

public void suspendFailureDetector()
                            throws java.rmi.RemoteException
Description copied from interface: FaultDetector
Temporarily suspend the failure detector thread.

Specified by:
suspendFailureDetector in interface FaultDetector
Throws:
java.rmi.RemoteException
See Also:
FaultDetector.suspendFailureDetector()

stopFailureDetector

public void stopFailureDetector()
                         throws java.rmi.RemoteException
Description copied from interface: FaultDetector
Stop the the failure detector thread.

Specified by:
stopFailureDetector in interface FaultDetector
Throws:
java.rmi.RemoteException
See Also:
FaultDetector.stopFailureDetector()

forceDetection

public void forceDetection()
                    throws java.rmi.RemoteException
Description copied from interface: FaultDetector
Force a failure detection even if the failure detector thread is waiting.

Specified by:
forceDetection in interface FaultDetector
Throws:
java.rmi.RemoteException
See Also:
FaultDetector.forceDetection()

initialize

public void initialize()
                throws java.rmi.RemoteException
Description copied from interface: FaultDetector
Reinit the state of the fault detector

Specified by:
initialize in interface FaultDetector
Throws:
java.rmi.RemoteException
See Also:
FaultDetector.initialize()


Copyright 2001-2005 INRIA All Rights Reserved.