Document HealthIndicator naming convention

Closes gh-4602
This commit is contained in:
Stephane Nicoll 2015-11-27 17:21:15 +01:00
parent 9d29ab73a4
commit 754642e0cf
1 changed files with 5 additions and 1 deletions

View File

@ -323,7 +323,7 @@ additional details to be displayed.
import org.springframework.stereotype.Component;
@Component
public class MyHealth implements HealthIndicator {
public class MyHealthIndicator implements HealthIndicator {
@Override
public Health health() {
@ -337,6 +337,10 @@ additional details to be displayed.
}
----
NOTE: The identifier for a given `HealthIndicator` is the name of the bean without the
`HealthIndicator` suffix if it exists. In the example above, the health information will
be available in an entry named `my`.
In addition to Spring Boot's predefined {sc-spring-boot-actuator}/health/Status.{sc-ext}[`Status`]
types, it is also possible for `Health` to return a custom `Status` that represents a
new system state. In such cases a custom implementation of the