|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.opennms.netmgt.config.PollerConfigManager
public abstract class PollerConfigManager
| Constructor Summary | |
|---|---|
PollerConfigManager(java.io.Reader reader,
java.lang.String localServer,
boolean verifyServer)
|
|
| Method Summary | |
|---|---|
void |
addMonitor(java.lang.String svcName,
java.lang.String className)
|
void |
addPackage(org.opennms.netmgt.config.poller.Package pkg)
|
java.util.Enumeration |
enumerateMonitor()
|
java.util.Enumeration |
enumeratePackage()
|
java.util.List<java.lang.String> |
getAllPackageMatches(java.lang.String ipaddr)
Returns a list of package names that the ip belongs to, null if none. |
org.opennms.netmgt.config.poller.PollerConfiguration |
getConfiguration()
Return the poller configuration object. |
java.lang.String |
getCriticalService()
This method returns the configured critical service name. |
org.opennms.netmgt.config.poller.Package |
getFirstPackageMatch(java.lang.String ipaddr)
Returns the first package that the ip belongs to, null if none. |
java.util.List<java.lang.String> |
getIpList(org.opennms.netmgt.config.poller.Package pkg)
Determine the list of IPs the filter rule for this package allows |
java.lang.String |
getNextOutageIdSql()
|
org.opennms.netmgt.config.poller.Package |
getPackage(java.lang.String name)
|
java.util.List<java.lang.String> |
getRRAList(org.opennms.netmgt.config.poller.Package pkg)
Retrieves configured list of RoundRobin Archive statements. |
org.opennms.netmgt.config.poller.Service |
getServiceInPackage(java.lang.String svcName,
org.opennms.netmgt.config.poller.Package pkg)
Return the Service object with the given name from the give Package. |
ServiceMonitor |
getServiceMonitor(java.lang.String svcName)
|
java.util.Collection<ServiceMonitorLocator> |
getServiceMonitorLocators(DistributionContext context)
|
java.util.Map |
getServiceMonitors()
|
org.opennms.netmgt.model.ServiceSelector |
getServiceSelectorForPackage(org.opennms.netmgt.config.poller.Package pkg)
|
int |
getStep(org.opennms.netmgt.config.poller.Package pkg)
Retrieves configured RRD step size. |
int |
getThreads()
|
boolean |
getXmlrpc()
This method returns the boolean flag xmlrpc to indicate if notification to external xmlrpc server is needed. |
boolean |
interfaceInPackage(java.lang.String iface,
org.opennms.netmgt.config.poller.Package pkg)
This method is used to determine if the named interface is included in the passed package definition. |
boolean |
isPolled(java.lang.String ipaddr)
Returns true if the ip is part of atleast one package. |
boolean |
isPolled(java.lang.String svcName,
org.opennms.netmgt.config.poller.Package pkg)
Returns true if this package has the service enabled and if there is a monitor for this service. |
boolean |
isPolled(java.lang.String ipaddr,
java.lang.String svcName)
Returns true if the ip is part of atleast one package and if this package has the service enabled and if there is a monitor for this service. |
boolean |
nodeOutageProcessingEnabled()
Returns true if node outage processing is enabled. |
boolean |
pathOutageEnabled()
This method returns the boolean flag pathOutageEnabled to indicate if path outage processing on nodeDown events is enabled |
boolean |
pollAllIfNoCriticalServiceDefined()
This method returns the configured value of the 'pollAllIfNoCriticalServiceDefined' flag. |
void |
rebuildPackageIpListMap()
This method is used to rebuild the package agaist iplist mapping when needed. |
void |
releaseAllServiceMonitors()
|
protected void |
reloadXML(java.io.Reader reader)
|
void |
save()
Saves the current in-memory configuration to disk and reloads |
void |
saveResponseTimeData(java.lang.String locationMonitor,
org.opennms.netmgt.model.OnmsMonitoredService monSvc,
double responseTime,
org.opennms.netmgt.config.poller.Package pkg)
|
protected abstract void |
saveXml(java.lang.String xml)
|
boolean |
serviceInPackageAndEnabled(java.lang.String svcName,
org.opennms.netmgt.config.poller.Package pkg)
Returns true if the service is part of the package and the status of the service is set to "on". |
boolean |
serviceMonitored(java.lang.String svcName)
Returns true if the service has a monitor configured, false otherwise. |
boolean |
serviceUnresponsiveEnabled()
Returns true if serviceUnresponsive behavior is enabled. |
abstract void |
update()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public PollerConfigManager(java.io.Reader reader,
java.lang.String localServer,
boolean verifyServer)
throws org.exolab.castor.xml.MarshalException,
org.exolab.castor.xml.ValidationException,
java.io.IOException
reader - localServer - verifyServer -
org.exolab.castor.xml.MarshalException
org.exolab.castor.xml.ValidationException
java.io.IOException| Method Detail |
|---|
public abstract void update()
throws java.io.IOException,
org.exolab.castor.xml.MarshalException,
org.exolab.castor.xml.ValidationException
update in interface PollerConfigjava.io.IOException
org.exolab.castor.xml.MarshalException
org.exolab.castor.xml.ValidationException
protected abstract void saveXml(java.lang.String xml)
throws java.io.IOException
java.io.IOException
protected void reloadXML(java.io.Reader reader)
throws org.exolab.castor.xml.MarshalException,
org.exolab.castor.xml.ValidationException,
java.io.IOException
org.exolab.castor.xml.MarshalException
org.exolab.castor.xml.ValidationException
java.io.IOException
public void save()
throws org.exolab.castor.xml.MarshalException,
java.io.IOException,
org.exolab.castor.xml.ValidationException
save in interface PollerConfigorg.exolab.castor.xml.MarshalException
java.io.IOException
org.exolab.castor.xml.ValidationExceptionpublic org.opennms.netmgt.config.poller.PollerConfiguration getConfiguration()
getConfiguration in interface PollerConfigpublic org.opennms.netmgt.config.poller.Package getPackage(java.lang.String name)
getPackage in interface PollerConfigpublic org.opennms.netmgt.model.ServiceSelector getServiceSelectorForPackage(org.opennms.netmgt.config.poller.Package pkg)
getServiceSelectorForPackage in interface PollerConfigpublic void addPackage(org.opennms.netmgt.config.poller.Package pkg)
addPackage in interface PollerConfig
public void addMonitor(java.lang.String svcName,
java.lang.String className)
addMonitor in interface PollerConfigpublic boolean getXmlrpc()
getXmlrpc in interface PollerConfigpublic boolean pathOutageEnabled()
pathOutageEnabled in interface PollerConfigpublic java.lang.String getCriticalService()
getCriticalService in interface PollerConfigpublic boolean pollAllIfNoCriticalServiceDefined()
pollAllIfNoCriticalServiceDefined in interface PollerConfigpublic boolean nodeOutageProcessingEnabled()
nodeOutageProcessingEnabled in interface PollerConfigpublic boolean serviceUnresponsiveEnabled()
serviceUnresponsiveEnabled in interface PollerConfigpublic java.util.List<java.lang.String> getIpList(org.opennms.netmgt.config.poller.Package pkg)
PollerConfig
getIpList in interface PollerConfigpublic void rebuildPackageIpListMap()
rebuildPackageIpListMap in interface PollerConfig
public boolean interfaceInPackage(java.lang.String iface,
org.opennms.netmgt.config.poller.Package pkg)
interfaceInPackage in interface PollerConfigiface - The interface to test against the package.pkg - The package to check for the inclusion of the interface.
public boolean serviceInPackageAndEnabled(java.lang.String svcName,
org.opennms.netmgt.config.poller.Package pkg)
serviceInPackageAndEnabled in interface PollerConfigsvcName - The service name to lookup.pkg - The package to lookup up service.
public org.opennms.netmgt.config.poller.Service getServiceInPackage(java.lang.String svcName,
org.opennms.netmgt.config.poller.Package pkg)
getServiceInPackage in interface PollerConfigsvcName - the service name to lookuppkg - the packe to lookup the the service in
public boolean serviceMonitored(java.lang.String svcName)
serviceMonitored in interface PollerConfigsvcName - The service name to lookup.public org.opennms.netmgt.config.poller.Package getFirstPackageMatch(java.lang.String ipaddr)
getFirstPackageMatch in interface PollerConfigipaddr - the interface to check
public java.util.List<java.lang.String> getAllPackageMatches(java.lang.String ipaddr)
getAllPackageMatches in interface PollerConfigipaddr - the interface to check
public boolean isPolled(java.lang.String ipaddr)
isPolled in interface PollerConfigipaddr - the interface to check
public boolean isPolled(java.lang.String svcName,
org.opennms.netmgt.config.poller.Package pkg)
isPolled in interface PollerConfigsvcName - the service to checkpkg - the package to check
public boolean isPolled(java.lang.String ipaddr,
java.lang.String svcName)
isPolled in interface PollerConfigipaddr - the interface to checksvcName - the service to check
public int getStep(org.opennms.netmgt.config.poller.Package pkg)
getStep in interface PollerConfigpkg - Name of the data collection
public java.util.List<java.lang.String> getRRAList(org.opennms.netmgt.config.poller.Package pkg)
getRRAList in interface PollerConfigpkg - Name of the data collection
public java.util.Enumeration enumeratePackage()
enumeratePackage in interface PollerConfigpublic java.util.Enumeration enumerateMonitor()
public int getThreads()
getThreads in interface PollerConfigpublic java.util.Map getServiceMonitors()
getServiceMonitors in interface PollerConfigpublic ServiceMonitor getServiceMonitor(java.lang.String svcName)
getServiceMonitor in interface PollerConfigpublic java.util.Collection<ServiceMonitorLocator> getServiceMonitorLocators(DistributionContext context)
getServiceMonitorLocators in interface PollerConfigpublic java.lang.String getNextOutageIdSql()
getNextOutageIdSql in interface PollerConfigpublic void releaseAllServiceMonitors()
releaseAllServiceMonitors in interface PollerConfig
public void saveResponseTimeData(java.lang.String locationMonitor,
org.opennms.netmgt.model.OnmsMonitoredService monSvc,
double responseTime,
org.opennms.netmgt.config.poller.Package pkg)
saveResponseTimeData in interface PollerConfig
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||