com.esf.core.system.monitor.service
Interface ISystemMonitorService


public interface ISystemMonitorService

The System Monitoring Service provides tools for the management of system level services. This interface will provide a Critical Service Check-in. I uses the @IWatchdogService in case this bundle itself locks up. Critical Services can be registered with this bundle and must check in periodically to denote that they are still running. If they are not the System Monitor service will force a reboot. Copyright © 2009 Eurotech Inc. All rights reserved.


Field Summary
static java.lang.String SERVICE_NAME
          Reports the class name representing this interface.
 
Method Summary
 void forceReboot()
          This method stops the updates to the hardware watchdog, forcing a reboot.
 boolean isRegistered(java.lang.String serviceName)
          Returns true if the specified service has been registered, false otherwise.
 void registerCriticalService(java.lang.String serviceName, int timeout)
          This method is used to register a critical service with the Critical Service Check-in.
 void unregisterCriticalService(java.lang.String serviceName)
          This method is used to unregister a critical service with the Critical Service Check-in.
 void updateCriticalService(java.lang.String serviceName)
          This method is used to notify the Critical Service Check-in that a critical service has issued an update.
 

Field Detail

SERVICE_NAME

static final java.lang.String SERVICE_NAME
Reports the class name representing this interface.

Method Detail

registerCriticalService

void registerCriticalService(java.lang.String serviceName,
                             int timeout)
This method is used to register a critical service with the Critical Service Check-in. Once registered, the critical service must call the updateCriticalService() method (at a frequency higher than 1/timeout) to prevent a system reboot.

Parameters:
serviceName - A @String representing the name of the critical service.
timeout - A timeout value that the critical service cannot exceed between updates without generating a system reboot. The time is expressed in seconds.

unregisterCriticalService

void unregisterCriticalService(java.lang.String serviceName)
This method is used to unregister a critical service with the Critical Service Check-in. Once unregistered, the critical service will no longer call the updateCriticalService() method.

Parameters:
serviceName - A @String representing the name of the critical service.

updateCriticalService

void updateCriticalService(java.lang.String serviceName)
This method is used to notify the Critical Service Check-in that a critical service has issued an update.

Parameters:
serviceName - A @String representing the name of the critical service.

forceReboot

void forceReboot()
This method stops the updates to the hardware watchdog, forcing a reboot.


isRegistered

boolean isRegistered(java.lang.String serviceName)
Returns true if the specified service has been registered, false otherwise.