Raritan / Server Technology Xerus™ PDU JSON-RPC API
HardwareHealth.idl
1 /* SPDX-License-Identifier: BSD-3-Clause */
2 /*
3  * Copyright 2018 Raritan Inc. All rights reserved.
4  */
5 
6 #include <Event.idl>
7 
8 module fitness {
9 
10  interface HardwareHealth {
11 
12  /** hardware failure types */
13  constant int FAILURE_TYPE_NETWORK_DEVICE_NOT_DETECTED = 1;
14  constant int FAILURE_TYPE_I2C_BUS_STUCK = 2;
15  constant int FAILURE_TYPE_SUB_CTRL_NOT_REACHABLE = 3;
16  constant int FAILURE_TYPE_SUB_CTRL_MALFUNCTION = 4;
17  constant int FAILURE_TYPE_OUTLET_POWER_STATE_INCONSISTENT = 5;
18 
19  /** Hardware Failure */
20  structure Failure {
21  int creationOrderId; ///< failures created later have a larger id; range 1..failure-count
22  string componentId; ///< the ID of the affected hardware component
23  int type; ///< one of the hardware failure type constants
24  string description; ///< human readable string describing HW component and failure
25  boolean isAsserted; ///< \c true when the failure is currently asserted
26  time lastAssertTimeStamp; ///< UNIX timestamp (UTC) when the failure was last asserted
27  time lastDeassertTimeStamp; ///< UNIX timestamp (UTC) when the failure was last deasserted (0 if asserted)
28  int assertCount; ///< count of assertions
29  };
30 
31  /** Event that is send when the hardware failure status changes */
32  valueobject FailureStatusChangedEvent extends idl.Event {
33  string componentId; ///< the ID of the affected hardware component
34  int failureType; ///< one of the hardware failure type constants
35  boolean isAsserted; ///< \c true when the failure is currently asserted
36  };
37 
38  /**
39  * Return a vector with past and present hardware failures.
40  *
41  * @return hardware failure vector
42  */
43  vector<Failure> getFailures();
44 
45  };
46 
47 }
Definition: HardwareHealth.idl:10
boolean isAsserted
true when the failure is currently asserted
Definition: HardwareHealth.idl:35
vector< Failure > getFailures()
Return a vector with past and present hardware failures.
int failureType
one of the hardware failure type constants
Definition: HardwareHealth.idl:34
Fitness Daemon
Definition: Fitness.idl:7
Basic IDL definitions.
Definition: Event.idl:10
Hardware Failure.
Definition: HardwareHealth.idl:20
int assertCount
count of assertions
Definition: HardwareHealth.idl:28
int type
one of the hardware failure type constants
Definition: HardwareHealth.idl:23
int creationOrderId
failures created later have a larger id; range 1..failure-count
Definition: HardwareHealth.idl:21
string description
human readable string describing HW component and failure
Definition: HardwareHealth.idl:24
boolean isAsserted
true when the failure is currently asserted
Definition: HardwareHealth.idl:25
time lastAssertTimeStamp
UNIX timestamp (UTC) when the failure was last asserted.
Definition: HardwareHealth.idl:26
string componentId
the ID of the affected hardware component
Definition: HardwareHealth.idl:22
time lastDeassertTimeStamp
UNIX timestamp (UTC) when the failure was last deasserted (0 if asserted)
Definition: HardwareHealth.idl:27