Skip to content
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

Feature Request Implement health check probe #427

Open
ryanfaircloth opened this issue Jun 30, 2022 · 8 comments
Open

Feature Request Implement health check probe #427

ryanfaircloth opened this issue Jun 30, 2022 · 8 comments

Comments

@ryanfaircloth
Copy link
Contributor

Implement a health check probe "/healthz" that returns 200 on get using a http endpoint not serving s3 i.e 8080 for a get this should return 200 this will prevent infra mon solutions including k8s from killing containers when misconfigured our back end systems fail

@gaul
Copy link
Owner

gaul commented Jul 21, 2022

Does minio or some other private object store have a mechanism that S3Proxy could mimic?

@ryanfaircloth
Copy link
Contributor Author

Yes, its really as simple as an additional "status" endpoint that returns 200 and a json payload { 'status': "ok" } and optionally an error if not ok with a 500. An example using jetty
https://gist.github.com/jkutner/7b3d154729de6563f7387c26c656233c

The status endpoint will allow k8s to avoid sending requests until the instance is fully started and prevent it from killing the instance if its slow to respond due to backend issues (azure) or just busy

@gaul
Copy link
Owner

gaul commented Jul 30, 2022

I just want to align S3Proxy with a similar implementation instead of creating some proprietary functionality.

@EraYaN
Copy link

EraYaN commented Oct 27, 2022

This is essentially how all ASP.NET stuff does it for example, although the content of the actual health check is moot for kubernetes. The only "standard" that is really out there is the Grpc Healthchecks.

Google seems to be the source of the healthz endpoint. So stuff like prometheus also implements it as does ASP.NET Core in most examples. MinIO does something a bit more complex because they want to expose cluster information: https://min.io/docs/minio/linux/operations/monitoring/healthcheck-probe.html But there is nothing stopping you from mapping both /healthz and /minio/health/live to the same response.

@missingcharacter
Copy link

@gaul minio does offer a healthcheck https://min.io/docs/minio/linux/operations/monitoring/healthcheck-probe.html and metrics https://min.io/docs/minio/linux/operations/monitoring/metrics-and-alerts.html

@ppodevlabs
Copy link

any chance this get implemented? it would be really helpfull running on k8s

@gaul
Copy link
Owner

gaul commented Sep 25, 2024

This should be straightforward to implement at least for node liveness -- PRs welcome! Any interest from @ryanwinter other others?

@Aazme
Copy link

Aazme commented Jan 21, 2025

please check this @gaul

#763

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants