@Singleton @Configurable @Named public class CpuHealthCheck extends CpuHealthCheckImpl
Generates WARNING if any CPU exceeds the warning threshold (default 95%)
Generates CRITICAL if any CPU exceeds the failure threshold (default disabled)
Constructor and Description |
---|
CpuHealthCheck() |
Modifier and Type | Method and Description |
---|---|
protected AbstractHealthCheck |
findDelegate(HealthService healthService)
Finds and returns any delegate health check.
|
protected CpuHealthCheck |
getDelegate() |
void |
setCpuMeters(java.util.ArrayList<AbstractMeter> cpuMeters) |
void |
setCriticalThreshold(int criticalThreshold)
Set CPU usage critical threshold (0-100, default 200 (disabled))
|
void |
setWarningThreshold(int warningThreshold)
Set CPU usage warning threshold (0-100, default 95)
|
checkHealth, getCriticalThreshold, getWarningThreshold
getLastResult, getLogPeriod, getName, hasDelegate, init, isEnabled, logResult, setEnabled, setLogPeriod, setName, silenceFor, start, stop, toString
public void setCpuMeters(java.util.ArrayList<AbstractMeter> cpuMeters)
setCpuMeters
in class CpuHealthCheckImpl
@Configurable public void setWarningThreshold(int warningThreshold)
setWarningThreshold
in class CpuHealthCheckImpl
@Configurable public void setCriticalThreshold(int criticalThreshold)
setCriticalThreshold
in class CpuHealthCheckImpl
protected AbstractHealthCheck findDelegate(HealthService healthService)
AbstractHealthCheck
findDelegate
in class AbstractHealthCheck
protected CpuHealthCheck getDelegate()
getDelegate
in class AbstractHealthCheck