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

Health-check endpoint for AWS Target Groups #251

fra967 opened this Issue May 2, 2017 · 1 comment


4 participants
Copy link

fra967 commented May 2, 2017

In AWS API can be deployed as an auto-scaling group behind a load-balancer. The LB runs a regular health-check on the registered instances, which it's just a PING on port 80 (if configured correctly).

However, API can also be deployed as a target group, for example when the LB acts as a listener, terminating HTTPS requests and routing them to a Target Group.

An AWS Target Group has its own health checks, however they consist of HTTP or HTTPS requests only (a path can be customised, but no more than this, i.e. no configurable headers). API always expects an authentication token in the request headers, therefore it returns a 401, and the health checks from the Target Group fail, marking the API instances as unhealthy.

We need a way to configure API so that, in the above deployment scenario, it returns a 200 HTTP status code on a specific request used to monitor its health.

Possibly this could be the Status endpoint?
It currently expects an authentication token - maybe an additional configuration option could be added to allow un-authenticated requests.
I am not sure whether this would expose sensitive information.
Alternatively, we can add a "Hello World" endpoint which does not require authentication.

API: 1.16.3


This comment has been minimized.

Copy link

jimlambie commented May 3, 2017

I think I'll allow requests at the root which will return a "Welcome to DADI API" page, as CDN also does. Web has a friendly first page as well, for first time users - perhaps we could do a similar one for API, with a little detail and information on where to go for help.

Thoughts @josephdenne @abovebored @fra967 ?

@jimlambie jimlambie added this to Backlog in API Version 3.0 May 31, 2017

@jimlambie jimlambie modified the milestone: 3.0.0 May 31, 2017

@jimlambie jimlambie moved this from Backlog to In Progress in API Version 3.0 Jul 7, 2017

@jimlambie jimlambie moved this from In Progress to Ready for Release in API Version 3.0 Sep 24, 2017

@jimlambie jimlambie closed this Dec 7, 2017

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