INTRODUCTION Overview Download and Install Documentation Publications REPOSITORY Libraries DEVELOPER Dev Guide Dashboard PEOPLE Contributors Users Project Download Mailing lists
|
gbxutilacfr::Status Class ReferenceLocal interface to component status. More...
Inherited by gbxutilacfr::TrivialStatus.
Detailed DescriptionLocal interface to component status.
Each subsystem should first call addSubsystem(), to make the Status engine aware that it exists. If any other function is called before the subsystem is added, a gbxutilacfr::Exception is thrown.
The default initial status of a subsystem is After registering a subsystem, a subsystem can report its state and health. Each of the calls is sufficient to let the Status engine know that the subsystem is alive. The special call heartbeat() lets Status know that the subsystem is alive without modifying its status.
The 'maxHeartbeatIntervalSec' parameter tells the Status engine how often it should expect to hear from the subsystem. If no message is received from a subsystem for longer than
Idle --> Initialising --> Working --> Finalising --> Shutdown |___________________________^ The following represents the Subsystem state machine in the format of State Machine Compiler (see smc.sf.net) : Idle Entry { init(); } { init Initialising {} } Initialising Entry { initialise(); } { [ !isStopping ] finished Working {} [ isStopping ] finished Finalising {} } Working Entry { work(); } { finished Finalising {} } Finalising Entry { finalise(); } { finished Shutdown {} } Shutdown { } Fault { } Default { fault Fault {} }
Member Function Documentation
Adds a new subsystem to the system status descriptor. This command must be called before actually modifying the subsystem status, i.e. all other status commands will raise an exception if a subsystem with that name does not already exists. An Exception is also raised when trying to add a subsystem with an existing name. It is possible to specify the maximum expected interval between heartbeats. See setMaxHeartbeatInterval() for details. It is also possible to describe the expected behavior of the subsystem by specifying SubsystemType. See setSubsystemType() for details. The initial status of the new subsystem is the same as produced by the empty constructor of SubsystemStatus. Implemented in gbxutilacfr::TrivialStatus.
Returns state of the component infrastructure. Returns component status. Component status cannot be set directly, it is the aggregate of the states and healths of its subsystems and the infrastructure. Implemented in gbxutilacfr::TrivialStatus.
Sets subsystem health to Critical. Diagnostic message is required. Throws Exception if the subsystem does not exist. Implemented in gbxutilacfr::TrivialStatus.
Sets state of the subsystem to Fault. Diagnostic message is required. Subsystem health is automatically changed to Critical. Throws Exception if the subsystem does not exist. Implemented in gbxutilacfr::TrivialStatus.
Sets state of the subsystem to Finalising. Health and message are not affected. Throws Exception if the subsystem does not exist. Implemented in gbxutilacfr::TrivialStatus.
Record heartbeat from a subsystem: let Status know the subsystem is alive without modifying its status. Throws Exception if the subsystem does not exist. Implemented in gbxutilacfr::TrivialStatus.
Sets state of the subsystem to Initialising. Health and message are not affected. Throws Exception if the subsystem does not exist. Implemented in gbxutilacfr::TrivialStatus.
Change the human-readable message for a subsystem but keep the previous state and health information. Throws Exception if the subsystem does not exist. Implemented in gbxutilacfr::TrivialStatus.
Sets subsystem health to Ok. The old message is cleared if a new one is not supplied. Throws Exception if the subsystem does not exist. Implemented in gbxutilacfr::TrivialStatus.
This function must be called periodically in order for status publishing to happen and stalled susbsystems identified. Implemented in gbxutilacfr::TrivialStatus.
Removes a subsystem from the status descriptor. Throws Exception if the subsystem does not exist. Implemented in gbxutilacfr::TrivialStatus. Referenced by gbxutilacfr::SubStatus::~SubStatus().
Sets the maximum expected interval between heartbeats (in seconds). When time since the last heartbeat exceeds the specified value, the subsystem is considered stalled. Negative interval means infinite interval. Throws Exception if the subsystem does not exist. Implemented in gbxutilacfr::TrivialStatus.
Sets the status of a subsystem (both state and health) in an atomic operation. Use this method when both state and health have changed. Throws Exception if the subsystem does not exist. Implemented in gbxutilacfr::TrivialStatus.
Returns status of the subsystem with the given name. Throws Exception when the specified subsystem does not exist. Implemented in gbxutilacfr::TrivialStatus.
Sets subsystem health to Warning. Diagnostic message is required. Throws Exception if the subsystem does not exist. Implemented in gbxutilacfr::TrivialStatus.
Sets state of the subsystem to Working. Health and message are not affected. Throws Exception if the subsystem does not exist. Implemented in gbxutilacfr::TrivialStatus.
The documentation for this class was generated from the following file: |