org.ourgrid.common.fd
Interface Monitorable

All Superinterfaces:
java.rmi.Remote
All Known Implementing Classes:
AbstractFailureDetector, CorePeerFailureDetector, FakeFailureDetector, FakeMonitorable, MyGridFailureDetector, PeerFailureDetector, SimpleTestFailureDetector, UserAgentFailureDetector

public interface Monitorable
extends java.rmi.Remote

Title: Failure Spotter - Research Line 2 Copyright: Copyright (c) 2004 Company: UFCG-DSC/HP The Monitorable interface allows a monitor to probe a monitorable entity.

To recover session information about the Monitorable session we are using the encarnation number. This number must be generated at Monitorable construction, and is used to identify when a Monitorable changes quickly it state, from from up to down and then do up again (between two pings), so the FailureDetector could not realize.

Note: By default, a monitorable should have two states:

  1. DOWN : To represent that the Monitorable is down.
  2. UP : To represent that the Monitorable is ok.
In application level one may use as many states as desired.

See Also:
GumStatus

Method Summary
 GenericState getCurrentState()
          Retrieves the monitorable current status.
 double getEncarnationNumber()
          Return an unique identifier of the Monitorable session.
 

Method Detail

getCurrentState

GenericState getCurrentState()
                             throws java.rmi.RemoteException
Retrieves the monitorable current status.

Returns:
the Monitorable state.
Throws:
java.rmi.RemoteException - if anything wrong occurs in communication.

getEncarnationNumber

double getEncarnationNumber()
                            throws java.rmi.RemoteException
Return an unique identifier of the Monitorable session.

Returns:
a unique identifier of the Monitorable session.
Throws:
java.rmi.RemoteException - if anything wrong occurs in communication.