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

/readiness_check occasionally returning 503 service unavailable #166

Open
tvolkert opened this issue Aug 10, 2019 · 4 comments
Open

/readiness_check occasionally returning 503 service unavailable #166

tvolkert opened this issue Aug 10, 2019 · 4 comments

Comments

@tvolkert
Copy link
Contributor

My app is restarting without context. Looking deeper into the logs, I see many requests for /readiness_check are returning 503, which seems to eventually cause the container to kill the app:

A 2019-08-10T02:04:44.874530055Z Waiting for termination, 1 seconds remaining. 
A 2019-08-10T02:04:44.809396670Z Sending SIGKILL to app. 
A 2019-08-10T02:04:44.805334192Z 50b2e7dca1284e0309c09ec3e19d2de195c2d4b5b84456ddeebf5324cbb654d8 
A 2019-08-10T02:04:44.738550379Z <13>Aug 10 02:04:44 vm_runtime_init: Aug 10 02:04:44 Pure compute version. Should skip _ah/start or stop. 
A 2019-08-10T02:04:44.731097521Z Sending SIGTERM to app. 
A 2019-08-10T02:04:44.729567774Z Aug 10 02:04:44 Pure compute version. Should skip _ah/start or stop. 
A 2019-08-10T02:04:44.677616932Z Triggering app shutdown handlers. 
A 2019-08-10T02:04:44.543Z GET 503 10 B 0 ms GoogleHC/1.0 /readiness_check GET 503 10 B 0 ms GoogleHC/1.0 

@jonasfj @dnfield

@dnfield
Copy link
Contributor

dnfield commented Aug 10, 2019

I've seen a few notifications about health checks, which may be related. I think we're off the legacy checks but maybe not

@tvolkert
Copy link
Contributor Author

The docs (https://cloud.google.com/appengine/docs/flexible/custom-runtimes/configuring-your-app-with-app-yaml) say that by default, readiness checks will not be forwarded form the container to your app - but they don't say what is responsible for responding in those cases.

I'm trying to update the service handlers to be aware of the new request paths (and to correspondingly update my app.yaml to manually handle the health checks).

https://github.com/dart-lang/appengine/blob/561deb1ee8fe1330fd7c42fbbde203acbdd54b03/lib/src/server/server.dart#L43-L47

@jonasfj
Copy link
Member

jonasfj commented Aug 12, 2019

You can do a gcloud app describe to check if you have split health checks enabled (you probably do, unless the app is old).

In pub.dev we handle the health checks manually, and specify an end-point they should hit. But according to the docs, this shouldn't be necessary.

@tvolkert
Copy link
Contributor Author

I tried updating my app.yaml to handle them manually, and the health checks seemed to be coming far more frequently than I had specified... but you're right - it shouldn't be necessary...

@devoncarew devoncarew transferred this issue from dart-archive/appengine Oct 2, 2024
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

4 participants