A Web application from development to successful deployment, this stage is a very important process, deployment should not only have a guardian mechanism, but also have a universal monitoring system, a good monitoring system, through the analysis of indicators, can be very convenient to find what problems and where the problems are. The same goes for Node.js Web applications, where you have to deploy to a machine, you have to provide services externally, and there are points of consumption and possibly improvement in the execution of business units. Not only memory utilization, CPU utilization, but also error log reporting, profile analysis, etc., using these indicators, to improve the robustness of the application, quickly fix problems.

Today, I would like to share the original and eggJS relatively appropriate Ali Cloud-Node. js performance monitoring platform, currently this service is free, its predecessor is the previous Alinode project, through this platform to monitor the performance of applications, but also in some daily affairs, through the log to feel the robustness of the program.

However, I also want to additional way, also is a set of alibaba open source application monitor, https://github.com/midwayjs/pandora, it integrates a variety of types of almost ability such as: Monitoring, link tracking, debugging, process management, etc., although there is some overlap with node.js performance monitoring platform in some aspects, but after all, it is a product that can be native to Ali Cloud ECS, double guarantee, and can better control the overall application.

To use the Node.js performance monitoring platform in EggJS, it is very simple. You need to create an application in the Node.js performance monitoring platform, obtain the APPID and APPSECRET, and install it

Egg-alinode, configure your Alinode in config.xxx.js, and finally install Alinode on your machine.

config.alinode = {
  server: 'wss://agentserver.node.aliyun.com:8080',
  appid: '',
  secret: ''}Copy the code

After a while, you’ll be able to see some of the health of your application, but the performance monitoring platform is mainly for the robustness of your machine and application. If you want to track business, it won’t do it for you, but Pandora.

Link tracing is a very important feature in a service. It can trace the whole process of each service request and intuitively identify the interface or page slowness, error, and timeout during operation. This is crucial for providing stable external services.

Try installing Pandora. Js, which comes with a dashboard that makes viewing data intuitive.

Because, I also just get in the car, the two pieces of things, further, how to use, or take some time to comb a piece of knowledge structure, such as what do you think of indicators, through what kind of index to reflect what kind of problem, the thinking, or agree with server-side knowledge system, go to see the problem.

The construction of operation and maintenance system is the key to the application of Node.js. Without a good operation and maintenance system, Node.js can only play its value in the tool ecosystem. Thanks to the whole community, node.js has solved some problems for node.js, and more problems still need joint efforts.


Long press the QR code to follow the public account:

You can also follow my Sina Weibo and search i_ICepy. I am looking forward to communicating with you.