HTTP Detector
Use this detector to find and assign services based on HTTP.
Configuration and use
Parameter | Description | Default |
---|---|---|
checkRetCode |
If set to |
false |
maxRetCode |
Highest HTTP response code that passes.
Evaluated only if |
399 |
port |
Port to query. |
80 |
url |
URL to query. |
/ |
timeout |
Timeout in milliseconds to wait for a response. |
2000 |
The HTTP detector makes only one HTTP request and does not follow redirects. |
Example configuration
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<foreign-source date-stamp="2010-06-29T13:15:30.494+02:00" name="test" xmlns="http://xmlns.opennms.org/xsd/config/foreign-source">
<scan-interval>1d</scan-interval>
<detectors>
<detector class="org.opennms.netmgt.provision.detector.simple.HttpDetector" name="http8080">
<parameter key="port" value="8080"/>
<parameter key="url" value="index2.html" />
<parameter key="maxRetCode" value="200"/>
<parameter key="checkRetCode" value="true"/>
</detector>
</detectors>
<policies/>
</foreign-source>