Package com.github.jpmsilva.jsystemd
Class SystemdNotifyActuatorHealthProvider
java.lang.Object
com.github.jpmsilva.jsystemd.SystemdNotifyActuatorHealthProvider
- All Implemented Interfaces:
- HealthProvider,- SystemdNotifyStatusProvider
public class SystemdNotifyActuatorHealthProvider extends Object implements SystemdNotifyStatusProvider, HealthProvider
Implementation of 
HealthProvider that provides application health based on Spring Boot Actuator Health Indicators.- Author:
- Christian Lorenz
- 
Nested Class SummaryNested classes/interfaces inherited from interface com.github.jpmsilva.jsystemd.HealthProviderHealthProvider.Health
- 
Constructor SummaryConstructors Constructor Description SystemdNotifyActuatorHealthProvider(@NotNull List<org.springframework.boot.actuate.health.HealthIndicator> healthIndicators, @NotNull Set<org.springframework.boot.actuate.health.Status> unhealthyStatusCodes)Creates a new instance using the providedHealthIndicatorandStatus.
- 
Method SummaryModifier and Type Method Description HealthProvider.Healthhealth()Determines if an application is healthy.@NotNull Stringstatus()Exposes status information to send to systemd.
- 
Constructor Details- 
SystemdNotifyActuatorHealthProviderpublic SystemdNotifyActuatorHealthProvider(@NotNull @NotNull List<org.springframework.boot.actuate.health.HealthIndicator> healthIndicators, @NotNull @NotNull Set<org.springframework.boot.actuate.health.Status> unhealthyStatusCodes)Creates a new instance using the providedHealthIndicatorandStatus.HealthIndicatorare used to determine the health of the application, whereasStatusindicate which status should be considered as unhealthy.- Parameters:
- healthIndicators- Spring Boot Actuator Health Indicators
- unhealthyStatusCodes- list of status codes considered as unhealthy
 
 
- 
- 
Method Details- 
healthDescription copied from interface:HealthProviderDetermines if an application is healthy.- Specified by:
- healthin interface- HealthProvider
- Returns:
- true if application is healthy, otherwise false
 
- 
statusDescription copied from interface:SystemdNotifyStatusProviderExposes status information to send to systemd.- Specified by:
- statusin interface- SystemdNotifyStatusProvider
- Returns:
- the string message to add to the service status
 
 
-