更新的运行状况检查会导致App Engine部署失败? [英] are updated health checks causing App Engine deployment to fail?

查看:97
本文介绍了更新的运行状况检查会导致App Engine部署失败?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们使用以下方法将Google App Engine运行状况检查从旧版本更新为新版本,现在我们的部署失败.项目上的其他所有内容都没有改变.我们测试了默认设置,然后进行了扩展检查,以防万一.

we updated our google app engine health checks from the legacy version to the new version using and now our deployments are failing. Nothing else on the project has changed. We tested the default settings and then extended checks just in case.

这是错误: ERROR: (gcloud.app.deploy) Error Response: [4] Your deployment has failed to become healthy in the allotted time and therefore was rolled back. If you believe this was an error, try adjusting the 'app_start_timeout_sec' setting in the 'readiness_check' section.

This is the error: ERROR: (gcloud.app.deploy) Error Response: [4] Your deployment has failed to become healthy in the allotted time and therefore was rolled back. If you believe this was an error, try adjusting the 'app_start_timeout_sec' setting in the 'readiness_check' section.

这是我们的app.yaml:

This is our app.yaml:

liveness_check:
   check_interval_sec: 120
   timeout_sec: 40
   failure_threshold: 5
   success_threshold: 5
   initial_delay_sec: 500

readiness_check:
  check_interval_sec: 120
  timeout_sec: 40
  failure_threshold: 5
  success_threshold: 5
  app_start_timeout_sec: 1500

不幸的是,无论配置如何,准备情况检查和活动检查都抛出404错误.

Unfortunately, no matter the configuration, both the readiness and liveness checks are throwing 404s.

是什么原因引起的?以及我们该如何调试呢? 是否可以回滚到旧的运行状况检查?

What could be causing the problem? and how can we debug this? Is it possible to rollback to the legacy health checks?

推荐答案

通常是由于应用程序仍在从旧的运行状况检查标志中读取和/或使用gcloud app deploy部署应用程序而未先启用更新的运行状况检查而导致的.您可以通过以下方式进行检查:

This is usually caused when the application is still reading from the legacy health check flags and/or deploying the app using gcloud app deploy without enabling the updated health checks first. You can check this by:

1-确保您的app.yaml中不存在旧版health_check标志.

1- Making sure the legacy health_check flag does not exist on your app.yaml.

2-运行gcloud beta app describe来查看featureSettings下的splitHealthChecks标志是否设置为true.

2- Run gcloud beta app describe to see whether splitHealthChecks flag is set to true under featureSettings.

默认情况下,来自更新的运行状况检查的HTTP请求不会转发到您的应用程序容器.如果要将运行状况检查扩展到您的应用程序,请指定活动检查或准备情况检查的路径.

By default, HTTP requests from updated health checks are not forwarded to your application container. If you want to extend health checks to your application, then specify a path for liveness checks or readiness checks.

然后可以使用gcloud beta app update --split-health-checks --project [your-project-id]启用更新的运行状况检查.请参阅此公共问题跟踪器或有关

You can then enable updated health checks by using gcloud beta app update --split-health-checks --project [your-project-id]. See this public issue tracker or this article about Updated Health Checks about for more details.

这篇关于更新的运行状况检查会导致App Engine部署失败?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆