public interface HealthService<T>
ServiceHealthAggregator| Modifier and Type | Method and Description |
|---|---|
void |
addInlineMonitor(Monitor<T> monitor)
Add a monitor which will be run in the same thread.
|
void |
addIsolatedMonitor(IsolatedHealthMonitor<T> monitor)
Register a monitor to the service, to setup a continuous monitoring on the monitor
this method can be used to add a
IsolatedHealthMonitor which will later be
scheduled at regular intervals and monitored to generate and maintain an aggregated health of the service
the scheduling will happen in an isolated thread |
T |
getServiceHealth()
aggregate all registered (enabled) monitors, collect individual monitor healths, and aggregate them accordingly
|
void |
start()
Start monitoring all registered monitors.
|
void |
stop()
Stop the health service, and stop tracking all monitors
|
void addIsolatedMonitor(IsolatedHealthMonitor<T> monitor)
IsolatedHealthMonitor which will later be
scheduled at regular intervals and monitored to generate and maintain an aggregated health of the service
the scheduling will happen in an isolated threadmonitor - an implementation of the IsolatedHealthMonitorvoid addInlineMonitor(Monitor<T> monitor)
Monitor
this monitor will not be scheduled in a separate isolated thread,
but instead its execution will happen inline, in a single thread, along with other inline monitorsmonitor - an implementation of line Monitorvoid start()
void stop()
T getServiceHealth()
Copyright © 2015–2022. All rights reserved.