96 |
#define MONITOR_YES 1 |
#define MONITOR_YES 1 |
97 |
#define MONITOR_INIT 2 |
#define MONITOR_INIT 2 |
98 |
|
|
99 |
|
#define STATE_PASSED 0 |
100 |
|
#define STATE_FAILED 1 |
101 |
|
#define STATE_INIT 2 |
102 |
|
|
103 |
#define MODE_ACTIVE 0 |
#define MODE_ACTIVE 0 |
104 |
#define MODE_PASSIVE 1 |
#define MODE_PASSIVE 1 |
105 |
#define MODE_MANUAL 2 |
#define MODE_MANUAL 2 |
240 |
typedef struct myaction { |
typedef struct myaction { |
241 |
int id; /**< Action to be done */ |
int id; /**< Action to be done */ |
242 |
Command_T exec; /**< Optional command to be executed */ |
Command_T exec; /**< Optional command to be executed */ |
243 |
|
unsigned count; /**< Event count needed to trigger the action */ |
244 |
|
unsigned cycles; /**< Cycles during which count limit can be reached */ |
245 |
} *Action_T; |
} *Action_T; |
246 |
|
|
247 |
|
|
513 |
int resource_id; /**< Which value is checked */ |
int resource_id; /**< Which value is checked */ |
514 |
long limit; /**< Limit of the resource */ |
long limit; /**< Limit of the resource */ |
515 |
int operator; /**< Comparison operator */ |
int operator; /**< Comparison operator */ |
|
int cycle; /**< Cycle overrun counter */ |
|
|
int max_cycle; /**< Cycle overrun limit */ |
|
516 |
EventAction_T action; /**< Description of the action upon event occurence */ |
EventAction_T action; /**< Description of the action upon event occurence */ |
517 |
|
|
518 |
/** For internal use */ |
/** For internal use */ |
712 |
struct myservice *source; /**< Event source */ |
struct myservice *source; /**< Event source */ |
713 |
short state; /**< TRUE if failed, FALSE if passed */ |
short state; /**< TRUE if failed, FALSE if passed */ |
714 |
short state_changed; /**< TRUE if state changed */ |
short state_changed; /**< TRUE if state changed */ |
715 |
|
long long state_map; /**< Event bitmap for last cycles */ |
716 |
unsigned int count; /**< The event rate */ |
unsigned int count; /**< The event rate */ |
717 |
char *message; /**< Optional message describing the event */ |
char *message; /**< Optional message describing the event */ |
718 |
EventAction_T action; /**< Description of the event action */ |
EventAction_T action; /**< Description of the event action */ |