public abstract class AbstractHealthCheck extends Object implements HealthCheck
HealthCheck.Result, HealthCheck.State| Modifier and Type | Field and Description |
|---|---|
static String |
CHECK_ENABLED |
static String |
CHECK_GROUP |
static String |
CHECK_ID |
static String |
FAILURE_COUNT |
static String |
INVOCATION_ATTEMPT_TIME |
static String |
INVOCATION_COUNT |
static String |
INVOCATION_TIME |
| Modifier | Constructor and Description |
|---|---|
protected |
AbstractHealthCheck(String id) |
protected |
AbstractHealthCheck(String group,
String id) |
protected |
AbstractHealthCheck(String group,
String id,
Map<String,Object> meta) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addMetaData(String key,
Object value) |
HealthCheck.Result |
call()
Invoke the check.
|
HealthCheck.Result |
call(Map<String,Object> options)
Invoke the check.
|
protected abstract void |
doCall(HealthCheckResultBuilder builder,
Map<String,Object> options)
Invoke the health check.
|
boolean |
equals(Object o) |
HealthCheckConfiguration |
getConfiguration()
Return the configuration associated with this
HealthCheck. |
String |
getGroup()
Returns the group
|
String |
getId()
Returns the id
|
Map<String,Object> |
getMetaData()
Return meta data associated with this
HealthCheck. |
int |
hashCode() |
void |
setConfiguration(HealthCheckConfiguration configuration) |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitgetOrderpublic static final String CHECK_ID
public static final String CHECK_GROUP
public static final String CHECK_ENABLED
public static final String INVOCATION_COUNT
public static final String INVOCATION_TIME
public static final String INVOCATION_ATTEMPT_TIME
public static final String FAILURE_COUNT
protected AbstractHealthCheck(String id)
protected AbstractHealthCheck(String group, String id)
public Map<String,Object> getMetaData()
HealthCheckHealthCheck.getMetaData in interface HealthCheckpublic HealthCheckConfiguration getConfiguration()
HealthCheckHealthCheck.getConfiguration in interface HealthCheckpublic void setConfiguration(HealthCheckConfiguration configuration)
public HealthCheck.Result call()
HealthCheckcall in interface HealthCheck#call(Map)}public HealthCheck.Result call(Map<String,Object> options)
HealthCheckcall in interface HealthCheckprotected final void addMetaData(String key, Object value)
protected abstract void doCall(HealthCheckResultBuilder builder, Map<String,Object> options)
HealthCheck#call(Map)}Apache Camel