Google App Engine运行状况检查垃圾邮件应用程序 [英] Google App Engine health checks spamming app

查看:149
本文介绍了Google App Engine运行状况检查垃圾邮件应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经使用以下 app.yaml 配置部署了在Google App Engine Flex运行时上运行的nodejs应用程序:

 运行时:nodejs 
env:flex
health_check:
enable_health_check:True
check_interval_sec:20
timeout_sec:4
unhealthy_threshold:2
healthy_threshold:2

根据



任何想法为什么会发生这种情况?

解决方案

不幸的是,它似乎就像我们的文档有一个错误。今天的确,应用程序确实经常在相当频繁的基础上进行健康检查。

原因有很多,但通常每个虚拟机将按照您指定的重复间隔进行3 * 2次不同的运行状况检查(默认情况下, , 1秒)。其原因是两种类型的健康检查(autohealer和LB的)以及每种情况下有3种可用的原因。

这就是说,我们目前正在研究新的健康检查的形状很快就会发布,并且应该解决现有健康检查行为的这一问题和其他问题(至少使默认设置更易于管理并为用户提供更多调整选项)。

敬请关注!

I've deployed a nodejs app running on the Google App Engine Flex runtime using the following app.yaml configuration:

runtime: nodejs
env: flex
health_check:
  enable_health_check: True
  check_interval_sec: 20
  timeout_sec: 4
  unhealthy_threshold: 2
  healthy_threshold: 2

According to the health check documentation the health checks should hit the /_ah/health endpoint every 20 seconds. However I noticed that my app is getting spammed with these health checks multiple times per second, even though the app responds with 200 status code:

Any idea why this is happening?

解决方案

Unfortunately it does seem like we have a bug on our docs. Today, indeed, apps do get health checked on a pretty frequent basis.

The reason is many fold, but in general each VM will be hit by 3 * 2 different health checks at the recurrence interval you specify (by default, the, very aggressive, 1 sec). The reason for this is 2 types of health check (autohealer and LB ones) and 3 of each for availability reasons.

That being said, we are currently working on a new shape of health checks that will be released pretty soon and should fix this and other problems with the existing health checking behavior (at least make the defaults more manageable and giving more tuning options to users).

Stay tuned!

这篇关于Google App Engine运行状况检查垃圾邮件应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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