Public Member Functions | Protected Member Functions | Protected Attributes

alma.ACS.MasterComponentImpl.MasterComponentImplBase.DefaultResourceErrorHandler< T > Class Reference

Inheritance diagram for alma.ACS.MasterComponentImpl.MasterComponentImplBase.DefaultResourceErrorHandler< T >:
alma.ACS.MasterComponentImpl.SubsysResourceMonitor.ResourceErrorHandler< T >

List of all members.

Public Member Functions

boolean resourceUnreachable (T resource)
void badState (T resource, String stateName)
void resourceRecovered (T resource)

Protected Member Functions

 DefaultResourceErrorHandler (String resourceName, boolean isComponent)

Protected Attributes

final String resourceName
final boolean isComponent

Constructor & Destructor Documentation

alma.ACS.MasterComponentImpl.MasterComponentImplBase.DefaultResourceErrorHandler< T >.DefaultResourceErrorHandler ( String  resourceName,
boolean  isComponent 
) [protected]

Member Function Documentation

void alma.ACS.MasterComponentImpl.MasterComponentImplBase.DefaultResourceErrorHandler< T >.badState ( T  resource,
String  stateName 
) [virtual]

Called when SubsysResourceMonitor was found in a bad state, but still replied in time.

Parameters:
resource The resource object is passed to allow using one handler for many resources.
stateName Name of the bad state the resource was found in. If the resource does not support named states, it may return any String that indicates the problem. For example, PingableResourceChecker} returns "ping() failed." which is then used as the stateName.
See also:
ResourceChecker.checkState()

Implements alma.ACS.MasterComponentImpl.SubsysResourceMonitor.ResourceErrorHandler< T >.

References alma.ACS.MasterComponentImpl.MasterComponentImplBase.doTransition(), and alma.acs.component.ComponentImplBase.m_logger.

void alma.ACS.MasterComponentImpl.MasterComponentImplBase.DefaultResourceErrorHandler< T >.resourceRecovered ( T  resource  )  [virtual]

Subclasses might want to send a reinit event to the state machine.

Implements alma.ACS.MasterComponentImpl.SubsysResourceMonitor.ResourceErrorHandler< T >.

boolean alma.ACS.MasterComponentImpl.MasterComponentImplBase.DefaultResourceErrorHandler< T >.resourceUnreachable ( T  resource  )  [virtual]

Called when the resource could not be reached at all because of a timeout or network/middleware communication errors. The resource object is passed to allow using one handler for many resources.

The return value controls whether monitoring of this resource will be stopped:

  1. true means that the error handler decided that this resource is unreachable beyond repair, and that no further monitoring calls should be made. This can avoid potential problems with an increasing number of hanging calls and eventually stopping the respective threads.
  2. false means that monitoring calls should continue.

Implements alma.ACS.MasterComponentImpl.SubsysResourceMonitor.ResourceErrorHandler< T >.

References alma.ACS.MasterComponentImpl.MasterComponentImplBase.doTransition(), and alma.acs.component.ComponentImplBase.m_logger.


Member Data Documentation

final boolean alma.ACS.MasterComponentImpl.MasterComponentImplBase.DefaultResourceErrorHandler< T >.isComponent [protected]
final String alma.ACS.MasterComponentImpl.MasterComponentImplBase.DefaultResourceErrorHandler< T >.resourceName [protected]

The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Enumerations Properties