1
votes

I have a spring boot app that uses local elastic search and Spring Boot Actuator 2.1.2 only for metrics purposes. Now i need to implement a default health check, so i turned it on in my configuration application.properties class like this:

management.endpoints.web.exposure.include=...,health
management.endpoint.health.show-details=never

It works fine and i can achieve a health status using default implementation calling http://localhost/actuator/health.

But there is a moment that i don't like. I've found that each time when i get a non-detailed answer like {"status":"UP"} actuator makes a needless elasticsearch call at

ElasticsearchHealthIndicator.doHealthCheck(Health.Builder builder)

I'm planning to get rid of useless calls.

Can i somehow disable only this call?

1

1 Answers

3
votes

try with the below properties in application.properties file

management.health.elasticsearch.enabled=false