Skip to content

Health Check Status Codes #4780

@SoundsSerious

Description

@SoundsSerious

I am seeing some atypical behavior on the /api/health health check.

The first health check returns 200 which is normal, then the next with some user agents return 304 Not Modified.

This behavior doesn't seem to be documented, and further it is hard to actually make use of. Presumably if the container was not working well and gave one status check of 500, the following would be 304?

For the case of AWS, their target group health checks 200 by default. Health check shouldn't have a path-dependent status code, health checks should be ABSOLUTE. If youre healthy return 200, if not return something 500 (or equvalent)

If you want to get fancy with status just put the fancy stuff in the return body, and dont forget to document this!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions