-
Notifications
You must be signed in to change notification settings - Fork 428
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
Add a healthcheck script #174
Conversation
To allow docker know if our container is really alive
Note that this is a very basic check. @tianon @yosifkit this sounds like a useful improvement, any reason why this PR hasn't received any feedback so far? |
I still feel the same as I did last year (linked below). I have not seen a need for general health checks in the official-images; either the container is up or it is not and anything more granular is up to the user to define for their environment. See also docker-library/cassandra#76 (comment). |
@yosifkit docker swarm zero downtime deployments are going to require health checks to operate correctly. As it stands these official images are showing a status of running and not a status of healthy. In addition I would like to address your each of your previous points:
In closing please check out Kelsey Hightowers talk here: https://vimeo.com/173610242 |
See https://github.com/docker-library/faq#healthcheck for a slightly more expanded answer on our stance on |
@ilude you would be surprised to learn how often we (RabbitMQ core team) see unreasonably aggressive monitoring to cause issues that are hard to predict and are counterproductive. High connection churn that environments are not configured to handle, opinionated health checks that query every single channel and queue in the system (potentially many thousands) every few seconds, health checks Running this basic check or every 30 seconds is sufficient for most environments. Possibly the most popular Kubernetes deployment example for RabbitMQ runs liveness probes every 60 seconds and we haven't seen any false positives or other complaints ever since. I agree that this image should include an example that demonstrates how to set up health checks and where to learn more (this is RabbitMQ's own Monitoring guide job to cover that well). It's important to not, however, build unreasonable monitoring policies that will produce false positives and waste resources into this image. |
@gerhard FYI. |
@tianon if you have made your mind on it I suggest closing this PR and perhaps revisiting the docs (to explain how to do health checks and where to learn more). Anything else would result in more and more iterations of the same discussion. |
I am picking this one up. A |
FTR, I discussed #300 with @gerhard and we will be taking small steps for now. Once rabbitmq/rabbitmq-cli#292 provides a few more "tiered" health check commands and the docs are improved, Docker Swarm users can adopt more extensive/intrusive monitoring easily if they choose to. What the default should be for this image, we believe only time will tell. Those unknown unknowns, dammit. |
Based on the comments in #300, I think this PR should be closed. |
Worth mentioning here: Kubernetes seems to be moving past the One True Health Check™ idea and towards a list of both generic and system-specific checks. |
Updated to reflect general recommendations from the rabbitmq docker repository (and via docker-library/rabbitmq#174 (comment)), and to generally support non-alpine versions of the image as the ubuntu image does not include wget (or curl) whereas `rabbitmqctl status` is included in both images, additionally the check looks more into the service status rather than the management plugins status. Signed-off-by: Jake Hill <[email protected]>
To allow docker know if our container is really alive