Cloud function SCF supports custom monitoring indicators to monitor how you DIY

 ◆  

SCF basis of monitoring indicators

When using cloud function, I believe we all noticed in the function console monitoring data show runtime. These monitoring data cloud functions can understand relevant information, such as:

  1. The number of function calls - can follow a service request volume, or the number of operations they perform other cloud offerings;

  2. Functions running memory and run time - can be performed to assess the performance function;

  3. A function of the number of errors - can be used to perform the function of abnormal problem.

In response to these monitoring data, can also configure alerts to help businesses detect abnormalities.

But these common level monitoring platform provided, can not fully meet the individual needs of the user. We often encounter this advice:

NodeJs Developer: Recently our Node is running too slow, you have Runtime level of monitoring it?

Business operation and maintenance: we are more concerned about the success rate of calls to evaluate service availability, you can invoke the correct frequency / number of calls to our calculation show a success rate of more intuitive it?

Electricity supplier Product Manager: The number of calls again detailed to specific business scenarios it? Add to Cart want to focus on the number, the number of purchase orders, the number of final payment .. ......

Now, cloud monitoring function SCF new upgrade customizable features! Users can be very easy to want to focus on DIY monitoring indicators of run-time function to monitor data display and alarm!

◆   

How to customize the monitoring indicators reported in the SCF

Step 1: without pre-registration, directly monitoring custom metrics reporting point in the function code buried

Step 2: After the report is complete, view the index view, the policy demand configuration warning

更详细的操作指南,可查看云+社区文章最佳实践:在SCF中上报自定义监控数据https://cloud.tencent.com/developer/article/1557566)

产品正在免费内测中,感兴趣的读者,也可点击阅读原文使用腾讯云主账号登陆申请试用。

附录:SCF上报自定义监控数据多方案对比

 ◆  

关于 Serverless Framework

Serverless Framework (产品页:https://cloud.tencent.com/product/sf)是构建和运维 Serverless 应用的框架,简单五步,即可通过 Serverless Framework 快速部署 hello_world 函数。

1. 安装 Serverless Framework CLI

$ npm install -g serverless

2. 使用 create —template 命令参数,基于 tencent_nodejs 模板创建 hello_world

$ serverless create --template tencent-nodejs --path my-service

3. 执行 npm install 安装相关依赖

$ cd my-service$ npm install

4. 扫描微信二维码一键登录,部署函数到云端

$ serverless deploy

5.触发云函数

$ serverless invoke -f hello_world

部署完成后,即可在您的命令行中看到部署详情,也可以在腾讯云控制台看到对应资源。

发布了50 篇原创文章 · 获赞 4 · 访问量 2166

Guess you like

Origin blog.csdn.net/weixin_42409476/article/details/103740483