|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.espertech.esper.metrics.codahale_metrics.metrics.core.HealthCheck
public abstract class HealthCheck
A health check for a component of your application.
Nested Class Summary | |
---|---|
static class |
HealthCheck.Result
The result of a HealthCheck being run. |
Constructor Summary | |
---|---|
protected |
HealthCheck(java.lang.String name)
Create a new HealthCheck instance with the given name. |
Method Summary | |
---|---|
protected abstract HealthCheck.Result |
check()
Perform a check of the application component. |
HealthCheck.Result |
execute()
Executes the health check, catching and handling any exceptions raised by check() . |
java.lang.String |
getName()
Returns the health check's name. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
protected HealthCheck(java.lang.String name)
HealthCheck
instance with the given name.
name
- the name of the health check (and, ideally, the name of the underlying
component the health check tests)Method Detail |
---|
public java.lang.String getName()
protected abstract HealthCheck.Result check() throws java.lang.Exception
HealthCheck.Result
; otherwise, an unhealthy
HealthCheck.Result
with a descriptive error message or exception
java.lang.Exception
- if there is an unhandled error during the health check; this will result in
a failed health checkpublic HealthCheck.Result execute()
check()
.
HealthCheck.Result
; otherwise, an unhealthy
HealthCheck.Result
with a descriptive error message or exception
|
© 2006-2016 EsperTech Inc. All rights reserved. Visit us at espertech.com |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |