The Assimilation Project  based on Assimilation version 1.1.7.1474836767
cma.monitoring.NagiosMonitoringRule Class Reference
Inheritance diagram for cma.monitoring.NagiosMonitoringRule:
Collaboration diagram for cma.monitoring.NagiosMonitoringRule:

Public Member Functions

def __init__ (self, rsctype, prio, initargs, triplespec, objclass='service')
 
def constructaction (self, context)
 
- Public Member Functions inherited from cma.monitoring.MonitoringRule
def __init__ (self, monitorclass, tuplespec, objclass='service')
 
def tripletuplecheck (self, triplespec)
 
def specmatch (self, context)
 
def constructaction (self, context)
 

Data Fields

 rsctype
 
 argv
 
 initargs
 
 prio
 
- Data Fields inherited from cma.monitoring.MonitoringRule
 monitorclass
 
 objclass
 
 nvpairs
 

Static Public Attributes

dictionary priomap
 
- Static Public Attributes inherited from cma.monitoring.MonitoringRule
int NOMATCH = 0
 
int NEVERMATCH = 1
 
int PARTMATCH = 2
 
int LOWPRIOMATCH = 3
 
int MEDPRIOMATCH = 4
 
int HIGHPRIOMATCH = 5
 
dictionary monitor_objects = {'service': {}, 'host': {}}
 

Additional Inherited Members

- Static Public Member Functions inherited from cma.monitoring.MonitoringRule
def monobjclass (mtype='service')
 
def ConstructFromString (s, objclass='service')
 
def compute_available_agents (context)
 
def findbestmatch (context, preferlowoverpart=True, objclass='service')
 
def findallmatches (context, objclass='service')
 
def ConstructFromFileName (filename)
 
def load_tree (rootdirname, pattern=r".*\.mrule$", followlinks=False)
 

Detailed Description

Class for implementing monitoring rules for Nagios style init script monitoring

Definition at line 804 of file monitoring.py.

Constructor & Destructor Documentation

def cma.monitoring.NagiosMonitoringRule.__init__ (   self,
  rsctype,
  prio,
  initargs,
  triplespec,
  objclass = 'service' 
)
Parameters
----------
rsctype: str
    The OCF resource type for this resource (service)
    This is the same as the script name for the resource

prio: str
    The priority of this Nagios agent: 'low', 'med', or 'high'

initargs: list
    Initial arguments given unconditionally to the Nagios agent

triplespec: list
    Similar to but wider than the MonitoringRule tuplespec
    (name,  expression, regex,  regexflags(optional))

    'name' is the name of an environment RA parameter or flag name, or None or '-'
    'expression' is an expression for computing the value for that name
    'regex' is a regular expression that the value of 'expression' has to match
    'regexflags' is the optional re flages for 'regex'

    If there is no name to go with the tuple, then the name is given as None or '-'
    If there is no regular expression to go with the name, then the expression
and remaining tuple elements are missing.  This can happen if there
is no mechanical way to determine this value from discovery information.
    If there is a name and expression but no regex, the regex is assumed to be '.'

Definition at line 812 of file monitoring.py.

References cma.monitoring.NagiosMonitoringRule.priomap.

Member Function Documentation

Field Documentation

cma.monitoring.NagiosMonitoringRule.argv

Definition at line 845 of file monitoring.py.

Referenced by cma.monitoring.NagiosMonitoringRule.constructaction().

cma.monitoring.NagiosMonitoringRule.initargs

Definition at line 846 of file monitoring.py.

Referenced by cma.monitoring.NagiosMonitoringRule.constructaction().

cma.monitoring.NagiosMonitoringRule.prio

Definition at line 847 of file monitoring.py.

Referenced by cma.monitoring.NagiosMonitoringRule.constructaction().

dictionary cma.monitoring.NagiosMonitoringRule.priomap
static
Initial value:
1 = {
2  'low': MonitoringRule.LOWPRIOMATCH,
3  'med': MonitoringRule.MEDPRIOMATCH,
4  'high': MonitoringRule.HIGHPRIOMATCH,
5  }

Definition at line 807 of file monitoring.py.

Referenced by cma.monitoring.NagiosMonitoringRule.__init__().

cma.monitoring.NagiosMonitoringRule.rsctype

Definition at line 844 of file monitoring.py.

Referenced by cma.monitoring.NagiosMonitoringRule.constructaction().


The documentation for this class was generated from the following file: