HealthCheckResultBuilder¶
-
public final class
HealthCheckResultBuilder
¶ Helper class enabling client modules to build instances of health check results to satisfy the HealthCheck contract.
Methods¶
healthy¶
-
public static HealthCheck.Result
healthy
()¶ Return a healthy check result.
Returns: a healthy check result
healthy¶
-
public static HealthCheck.Result
healthy
(String message)¶ Return a healthy check result, with status message.
Parameters: - message – the status message
Returns: the healthy check result
healthy¶
-
public static HealthCheck.Result
healthy
(String message, Object... args)¶ Return a healthy check result, with status message built from a template.
Parameters: - message – a template string
- args – values to interpolate into the template string
Returns: the healthy check result
unhealthy¶
-
public static HealthCheck.Result
unhealthy
(String message)¶ Return an unhealthy check result, with status message.
Parameters: - message – the status message
Returns: the unhealthy check result
unhealthy¶
-
public static HealthCheck.Result
unhealthy
(String message, Object... args)¶ Return an unhealthy check result, with status message built from a template.
Parameters: - message – a template string
- args – values to interpolate into the template string
Returns: the unhealthy check result
unhealthy¶
-
public static HealthCheck.Result
unhealthy
(Throwable error)¶ Return an unhealthy check result with the exception that caused the check to fail.
Parameters: - error – the exception that caused the check to fail
Returns: the unhealthy check result