AWS - Sending Custom Metrics From AWS Lambda With Code Examples
Repost from https://stackify.com/custom-metrics-aws-lambda/ Today’s post is a detailed guide on how to send custom metrics to AWS CloudWatch monitoring using AWS Lambda . Starting from scratch, we’re going to finish up this post by leaving a serverless project running on Amazon Web Services (AWS). And do you want to hear the best part? Getting started will cost you less than you might spend on a cheeseburger. I’ve used AWS Lambda to send custom metrics to CloudWatch to collect data on business metrics like purchases made in the application. At one company where I used to work, there were times where users were starting to experience problems, and system metrics like CPU or memory were in the normal trend. By sending those metrics to AWS CloudWatch, I was able to act proactively with the infrastructure, either by restarting the app or by scaling out the infrastructure. Let’s get started! Create an IAM Policy The first thing we need to do is ...