-
Notifications
You must be signed in to change notification settings - Fork 62
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
HealthCheck not supported async mode [enhancement] #211
Comments
Can you elaborate on the benefits of supporting asynchronous return types given the health check call doesn't actually happen until someone requests it? |
Many libraries already support the asynchronous api, such as: nosql drivers (mongodb-driver-reactivestreams, Cassandra), Redis client (Lettuce ), etc.
Yes, but this is not a one-time request, but a regular load, especially in the context of microservices. |
I agree with the need to introduce async/rx API. People will poll other services to determine readiness and or liveness, even if you tell them not to. In the absence of asynchronous API this may consume threads unnecessarily. (Compare to JAX-RS |
We took a stance to not introduce new features into the specification which may be still unstable. So we introduced async health checks in the SmallRye Health implementation -> https://github.com/smallrye/smallrye-health/blob/master/implementation/src/main/java/io/smallrye/health/SmallRyeHealthReporter.java#L208 that utilize Mutiny as a reactive framework. We also would like to encourage different implementations to also introduce some form of their async API so we can catch most of the errors before we move the API to the spec which would result in a smaller need for breaking changes in the future. If you can, please give a try and report any problems/enhancements that you find. |
Already using jboss-servlet-api_4. 0 which supports AsyncContext (since 3.0).
I want to be able to implement asynchronous HealthCheck, for example:
or RxJava
The text was updated successfully, but these errors were encountered: