Class SystemdProperties.ActuatorHealth

java.lang.Object
com.github.jpmsilva.jsystemd.spring.autoconfigure.SystemdProperties.Toggle
com.github.jpmsilva.jsystemd.spring.autoconfigure.SystemdProperties.ActuatorHealth
Enclosing class:
SystemdProperties

public static class SystemdProperties.ActuatorHealth extends SystemdProperties.Toggle
The ActuatorHealthStatusProvider, which provides the application health when using Spring Boot Actuator.
  • Method Details

    • isHealth

      public boolean isHealth()
      Check if the watchdog heartbeat is suppressed while the application is unhealthy.
      Returns:
      true if the application health is signalled to the watchdog
    • setHealth

      public void setHealth(boolean health)
      Enable or disable suppressing the watchdog heartbeat while the application is unhealthy.
      Parameters:
      health - true to signal the application health to the watchdog
    • getUnhealthyStatusCodes

      public List<String> getUnhealthyStatusCodes()
      Check the status codes from Status to consider as unhealthy.
      Returns:
      the status codes from Status to consider as unhealthy
      See Also:
    • setUnhealthyStatusCodes

      public void setUnhealthyStatusCodes(List<String> unhealthyStatusCodes)
      Set the status codes from Status to consider as unhealthy. If omitted Status.DOWN is used.
      Parameters:
      unhealthyStatusCodes - the status codes from Status to consider as unhealthy
    • getGroup

      public @Nullable String getGroup()
      Check the name of the Spring Boot Actuator health group whose members are taken into account.
      Returns:
      the name of the health group, or null to take all the health contributors into account
      See Also:
    • setGroup

      public void setGroup(@Nullable String group)
      Set the name of the Spring Boot Actuator health group whose members are shown in the systemd status and taken into account for the health signal.
      Parameters:
      group - the name of the health group, or null to take all the health contributors into account
    • getUnhealthyDelay

      public @Nullable Duration getUnhealthyDelay()
      Check the delay before suppressing the watchdog heartbeat while the application is unhealthy.
      Returns:
      the delay, or null if there is no delay
      See Also:
    • setUnhealthyDelay

      public void setUnhealthyDelay(@Nullable Duration unhealthyDelay)
      Set the delay before suppressing the watchdog heartbeat while the application is unhealthy.
      Parameters:
      unhealthyDelay - the delay, or null to disable the delay