Skip to content

Healthcheck endpoint for cap #301

Description

@msm-cert

what problem would this feature solve, if any?

We just had an issue where cap didn't recover after redis restart (coincidentally just reported at #299). In normal case our healthcheck infrastructure would detect this problem and either raise an alert, or restart the failed container (which would solve the problem in this case).

But it didn't, because even without redis, GET / returned 200 in cap.

describe the solution you'd like

I would like to ask for a healthcheck endpoint that would return 200 if cap appears to work, and 500 if cap appears broken (exact self-check mechanics to be defined, but at minimum check if the database is reachable and all the other preconditions to successfully generate a new captcha)

describe alternatives you've considered

We are considering generating new captchas as a part of healthcheck (if captcha is generated successfully, consider the system up). This actually sounds like a good idea, so if that sounds good then maybe dedicated endpoint is not necessary.

additional context:

n/a.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions