I noticed that this page(http://micrometer.io/docs/guide/healthAsGauge) uses a non-existent construct method, and I don't know if it's right.

Comment From: chenqimiao

https://github.com/spring-projects/spring-boot/blob/1f280e394bc4403ab5c8ac3bc7d5f55c0da386e4/spring-boot-project/spring-boot-actuator/src/main/java/org/springframework/boot/actuate/health/DefaultHealthIndicatorRegistry.java#L33 This class have been deprecated. @polarbear567

Comment From: snicoll

@polarbear567 thanks for the PR but I think the micrometer documentation has to change. Exposing this bean is not going to help as it's indeed deprecated.

Comment From: polarbear567

@snicoll , sure, I think it will be right to update the doc of micrometer and spring-boot(Make it clear that the relevant classes should not be used). And the purpose of this PR is to derive from this issue, so I think that if someone else can use it, if you don't add this bean, it will report an error, although this class has been discarded. Thanks.

Comment From: polarbear567

@chenqimiao yes, I know the class has been discarded :), but someone may also use it, you can see this issue: https://github.com/spring-projects/spring-boot/issues/18194

Comment From: snicoll

@polarbear567 that's not really why I closed the PR. I am not convinced that a user needs the registry to upgrade their code, there is something else that needs to fundamentally change to let users get the same use case as before (and we're tracking that in #18194). Regardless of all of that, exposing an empty registry is not going to help as it should contain known health indicators.

Comment From: polarbear567

@snicoll yes, you're right, this pr is just able to make no mistakes, I think people should know that they shouldn't use it anymore:) I don't know if it's right what I said.

Comment From: snicoll

I don't think so I am afraid. Having a bean with an empty registry is more confusing than the error IMO.

Comment From: polarbear567

@snicoll I think you're right, it's my fault:)