flood icon indicating copy to clipboard operation
flood copied to clipboard

Add health check endpoint

Open Elegant996 opened this issue 3 months ago • 3 comments

At present, the only real form of health checking is the acceptance of incoming connections on port 3000. Flood should have an endpoint which can be used to determine whether the app is healthy.

This can be achieve by leveraging fastify-healthcheck. Implementation should be easy but we may also want to consider what would make flood unhealthy (i.e. too many queries).

Elegant996 avatar Sep 03 '25 04:09 Elegant996

This sounds a good idea, should we check the downloader connection info is correct when using --auth=none in health check?

trim21 avatar Oct 07 '25 07:10 trim21

That could improve it, as long as it only checks whether connection is alive and not whether the downloader is ready.

The health check should primarily confirm if flood itself is ready to serve incoming requests and should not require any authentication on the endpoint.

We don't want to check the health of any downloaders flood may connect to. Downloaders (containerized or otherwise) should be able to perform their own health check to determine if they are ready to serve.

Elegant996 avatar Oct 08 '25 06:10 Elegant996

I mean when --auth=none, the connection info has been provided by flags, and should this be considered as "ready to serve incoming requests"? in this case if the conn info is wrong flood can't work properly

trim21 avatar Oct 08 '25 08:10 trim21