We were facing a issue with Elasticsearch and WebFlux stack SB 3.1.2 (probably it is not only WebFlux stack related) in case of the app throws java.lang.OutOfMemoryError: Java heap space and reactor thread throws I/O reactor terminated abnormally. In this situation the Http client of Elasticsearch (RestClient) is stopped and each attempt under probe ends with:
java.util.concurrent.CancellationException: Request execution cancelled
at org.apache.http.impl.nio.client.CloseableHttpAsyncClientBase.execute(CloseableHttpAsyncClientBase.java:114)
It seems to be issue in Http client got 'CancellationException: Request execution cancelled' always when throwing an exception in httpasyncclient callback. Fixed in 5.X version but we are using 4.1.5 in the Spring Boot.
Our solution was to added elasticsearchClient health check just to verify the status of the client itself and it solved our problem.
So - make sense to improve current health check implementation to check also status of the client? In our case the elasticsearch health check is part of readiness and the problem is that the app is running but also in irreparable state.
Comment From: philwebb
So - make sense to improve current health check implementation to check also status of the client?
Can you describe in more detail what you mean by this? I'm afraid I'm not really getting what you're asking.
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: spring-projects-issues
Closing due to lack of requested feedback. If you would like us to look at this issue, please provide the requested information and we will re-open the issue.