public final class HttpPostMonitor extends ParameterSubstitutingMonitor
Modifier and Type | Field and Description |
---|---|
static String |
DEFAULT_CHARSET |
static String |
DEFAULT_MIMETYPE |
static String |
DEFAULT_SCHEME |
static boolean |
DEFAULT_SSLFILTER |
static String |
DEFAULT_URI |
static String |
PARAMETER_BANNER |
static String |
PARAMETER_CHARSET |
static String |
PARAMETER_MIMETYPE |
static String |
PARAMETER_PASSWORD |
static String |
PARAMETER_PAYLOAD |
static String |
PARAMETER_PORT |
static String |
PARAMETER_SCHEME |
static String |
PARAMETER_SSLFILTER |
static String |
PARAMETER_URI |
static String |
PARAMETER_USERNAME |
Constructor and Description |
---|
HttpPostMonitor() |
Modifier and Type | Method and Description |
---|---|
PollStatus |
poll(MonitoredService svc,
Map<String,Object> parameters)
This method is the heart of the plug-in monitor.
|
getRuntimeAttributes, getSubstitutedParameters, parseString, resolveKeyedString
getEffectiveLocation, getKeyedBoolean, getKeyedInstance, getKeyedInteger, getKeyedLong, getKeyedObject, getKeyedString, getServiceProperties
public static final String DEFAULT_MIMETYPE
public static final String DEFAULT_CHARSET
public static final String DEFAULT_URI
public static final String DEFAULT_SCHEME
public static final boolean DEFAULT_SSLFILTER
public static final String PARAMETER_SCHEME
public static final String PARAMETER_PORT
public static final String PARAMETER_URI
public static final String PARAMETER_PAYLOAD
public static final String PARAMETER_MIMETYPE
public static final String PARAMETER_CHARSET
public static final String PARAMETER_BANNER
public static final String PARAMETER_SSLFILTER
public static final String PARAMETER_USERNAME
public static final String PARAMETER_PASSWORD
public PollStatus poll(MonitoredService svc, Map<String,Object> parameters)
This method is the heart of the plug-in monitor. Each time an interface requires a check to be performed as defined by the scheduler the poll method is invoked. The poll is passed the service to check.
By default when the status transition from up to down or vice versa the framework will generate an event. Additionally, if the polling interval changes due to an extended unavailability, the framework will generate an additional down event. The plug-in can suppress the generation of the default events by setting the suppress event bit in the returned integer.
NOTE: This method may be invoked on a Minion, in which
case certain bean and facilities will not be available. If any state related
information is required such as agent related configuration, it should retrieved
by the ServiceMonitor.getRuntimeAttributes(MonitoredService, Map)
.
svc
- Includes details about to the service being monitored.parameters
- Includes the service parameters defined in poller-configuration.xml and those
returned by ServiceMonitor.getRuntimeAttributes(MonitoredService, Map)
.PollStatus.SERVICE_AVAILABLE
,
PollStatus.SERVICE_UNAVAILABLE
,
PollStatus.SERVICE_AVAILABLE
,
PollStatus.SERVICE_UNAVAILABLE
Copyright © 2021. All rights reserved.