Measuring and monitoring Node.JS server performance [closed]

。_饼干妹妹 提交于 2019-12-31 10:34:27

问题


I'm new to Node.JS, already Googled for aswers but there is a lot of ways of doing this. Do you have some sort of math to know when I'll need to scale my Node.JS server? And what tools you use for monitoring server performance and error track?

Thanks!


回答1:


As @ThiefMaster said, this depends on your system. You need to monitor the requests for your site, the CPU load, memory footprint etc and decide if and when to add mode servers.

If you want to know more about Node.js performance read this good article: http://blog.3rd-eden.com/post/5809079469/theoretical-node-js-real-time-performance

If you need a Node.js metrics library, there are 2 ones which I can recommend:
https://github.com/felixge/node-measured
https://github.com/mikejihbe/metrics

Resources:

monitoring a node.js server




回答2:


I recommend monitoring your event loop and if it starts to back up more than 200ms on a regular basis, you'll need to scale.



来源:https://stackoverflow.com/questions/8615577/measuring-and-monitoring-node-js-server-performance

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!