Kubernetes 中的自动缩放微服务

发布于 2025-01-16 13:53:58 字数 244 浏览 2 评论 0原文

我想创建与此类似的内容:

在此处输入图像描述

基本上我有一个微服务,我想扩展它的实例,但要使用相同的 MongoDB 容器。这些容器应连接到负载均衡器。如何使用 Kubernetes 实现这一目标?

I want to create something similar with this:

enter image description here

Basically I have a microservice and I want to scale the instances of it, but to use the same MongoDB container. These containers should be connected to a load balancer. How can I achieve this using Kubernetes?

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

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

发布评论

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

评论(1

自由如风 2025-01-23 13:53:58

您可以使用 k8s Horizo​​ntalPodAutoscaler 来扩展您的随着需求的增加微服务。当所有节点都充满微服务时,您可以使用集群自动缩放器 扩展您的节点,以便更多的微服务可以上线。

You can use k8s HorizontalPodAutoscaler to scale out your microservice as the demand goes up. When all of your nodes are filled up with microservices, you use cluster autoscaler to scale out your node so more microservices can come online.

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