When only a configuration for a ReactiveElasticsearchClient is present (we have created a subclass of AbstractReactiveElasticsearchConfiguration to configure it), the health indicator fails because it uses a default RestClient configured with localhost:9200.

Adding a non-reactive configuration (extending AbstractElasticsearchConfiguration) makes the health check succeed.

My expectation would be that the ElasticsearchRestHealthIndicator uses any rest client configured, also the reactive one.

This happens with Spring Boot 2.3.0 and spring-data-elastisearch 4.0.0.

Comment From: bclozel

This looks similar to #21042 - is it @ractive ?

Comment From: spring-projects-issues

If you would like us to look at this issue, please provide the requested information. If the information is not provided within the next 7 days this issue will be closed.

Comment From: ractive

Yes. That's the same issue it seems. You can close this if you want! 👍

Comment From: bclozel

Thanks @ractive !