如何在 Elastic Beanstalk 中为 Auto Scaling EC2 实例配置触发器?

发布于 2024-10-21 01:47:49 字数 113 浏览 2 评论 0原文

我想在 Elastic Beanstalk 中配置 Auto Scaling 的触发器。

基本上,如果用户超过 4 秒没有得到响应,我想扩展新实例。

您能告诉我如何实现这一目标吗?

I would like to configure triggers for Auto Scaling in Elastic Beanstalk.

Basically I want to scale-out new instance if the user does not get response for more than 4 seconds.

Can you please advise how can I achieve this?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

十六岁半 2024-10-28 01:47:49

在 Elastic Beanstalk 中,您可以设置触发器,如果​​用户在指定时间内未收到响应,则触发器将启动新实例。在 Elastic Beanstalk 中配置环境时,您可以设置 EC2 实例运行状况检查并配置运行状况检查间隔和运行状况检查超时。如果服务器在运行状况检查间隔内没有响应,Auto Scaling 将启动新实例。

有关更多详细信息: http://docs .amazonwebservices.com/elasticbeanstalk/latest/ug/index.html?using-features.managing.elb.html

In Elastic Beanstalk, you can set triggers which will start new instances, if users don't get responses in the specified time. While configuring your environment in Elastic Beanstalk, you can setup an EC2 instance health check and configure the health check interval and health check timeout. If the server doesn't respond within the health check interval, Auto Scaling will bring up new instances.

For more details: http://docs.amazonwebservices.com/elasticbeanstalk/latest/ug/index.html?using-features.managing.elb.html

故事↓在人 2024-10-28 01:47:49

AWS EB 有一个针对延迟等的特定扩展指标,这就是您希望在您的案例中使用的指标。正如 SanketDangi 提到的,健康检查很重要,但需要明确的是,它不会自动“启动新实例”。它肯定会使失败的实例停止服务。至于这是否会启动扩展操作,取决于自动扩展策略,例如 EB 在创建新的 EB 应用程序时为您设置的配置的最小实例数。

AWS EB has a specific scaling metric for latency, amongst others, which is what you'd want to use in your case. The health check is important as SanketDangi mentioned, but to be clear it won't automatically "bring up new instances". It WILL for sure take that failed instance out of service. As to whether this kicks off a scaling operation, that depends on the auto scaling policies, like the configured Min Instances for example that EB sets up for you when creating a new EB app.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文