我可以在AWS Cloudwatch Alert中包括自定义数据吗? [英] Can I include Custom data in a AWS Cloudwatch Alert?

查看:118
本文介绍了我可以在AWS Cloudwatch Alert中包括自定义数据吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用AWS Cloudwatch监视我的AWS EC2实例上的应用程序日志文件.当我定义的指标触发了自定义数据(即堆栈跟踪)时,是否有办法将其包含在Cloudwatch Alert中?

I'm using AWS Cloudwatch to monitor application log files on my AWS EC2 instances. Is there a way to include Custom data (I.E. stack trace) in the Cloudwatch Alert when it is triggered by the metric I define?

推荐答案

我最终将警报事件路由到我编写的REST服务而不是SNS通知组. Web服务使用事件名称"和时间戳生成定制通知.它从包括ELK堆栈在内的多种服务中提取诊断信息,并将其与典型的Cloudwatch Alert数据一起包含在自定义通知中.然后,Web服务将自定义通知发送到要分发的原始SNS通知组.

I ended up routing the alert event to a REST service I wrote rather than to the SNS notification group. The web service uses the "event name" and timestamp to generate a custom notification. It pulls diagnostic information from several services, including our ELK stack, and includes it in the custom notification along with the typical Cloudwatch Alert data. The web service then sends the custom notification to the original SNS notification group to be distributed.

这篇关于我可以在AWS Cloudwatch Alert中包括自定义数据吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆