本文介绍了使用更多的vCPU是否有助于提高node.js的性能?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在AWS ECS上的docker容器内运行node.js.我有一个过程.

I am running node.js inside of a docker container on AWS ECS. I have one process.

通常添加更多的vCPU,特别是在使用AWS ECS的情况下,是否可以提高我的应用程序的性能?

Does adding more vCPU in general and specifically in case of using AWS ECS makes performance of my app better?

如果我运行4个vCPU,我会看到CPU利用率比1个vCPU低得多,但不能保证将使用此备用CPU.

Cause if I run 4 vCPUs I see CPUUtilisation is much lower than with 1 vCPU but it doesn't guarantee than this spare CPU will ever be used.

vCPU与物理CPU有何不同?

And how vCPU is different from physical CPU?

推荐答案

使用容器的妙处在于,您可以在几秒钟内创建一个相同的容器,因此您无需放置额外的cpu即可处理窥视时间.您只需创建一个新容器并平衡流量即可.您只需要创建一个ecs服务,ecs就会负责扩展和负载平衡.

awesomeness of using container is you can create an identical container within seconds so you don't need to put additional cpu to handle peek time . you just create a new container and load balanced the traffic. you just have to create a ecs service and ecs will take care of the scaling and load balancing.

我不知道vcpu和cpu之间的区别.但1个vcpu = 1024个cpu单位.

i don't know the exect differens between vcpu vs cpu . but 1 aws vcpu = 1024 cpu units.

不用担心使用高CPU的应用程序,因为当达到90%时,您可以弹出一个新的1并对其进行负载均衡.那就是最经济有效的方式

and don't worry about application using high cpu because when it reaches 90 % you can popup a new 1 and load balanced it. thats the most cost effectively way

这篇关于使用更多的vCPU是否有助于提高node.js的性能?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-18 13:14