i realised on the terraform code, the alarm dimension was pointing to an ecs service, which i think should point to the log-group instead, i am not also clear on the sns role and policy, i am thinking it should be a role to allow events to perform those policies
Hi, thanks for your question. Yes, it's possible. Do you want to get the alert notification when the service is auto-scaled, or do you want to get any other monitoring action?
Got it, thanks for the clarification. In that case, you can create a custom AWS CloudWatch Dashboard and visualize the number of running ECS tasks with the respective widget there.
Thanks for your feedback. There were some issues recently with ECS metrics, so I've made some updates in the Gist with the Terraform code. You can find the updated configuration by this link: gist.github.com/kuzemkon/03633f2e8aeb801053b18162db7f28e2
if you are creating the alarm from the console, you can easily click on the metric filter when you go to log-group>meetric-filter and use the create alarm button there
If you have done everything as in the video, don't forget the aws_cloudwatch_log_resource_policy to be able to store logs into log group.
Thank you for your feedback!
Thank you for sharing, it's very helpfull!!!
I'm glad that it helped. Thanks for your comment!
Thanks..that was really helpful
i realised on the terraform code, the alarm dimension was pointing to an ecs service, which i think should point to the log-group instead,
i am not also clear on the sns role and policy, i am thinking it should be a role to allow events to perform those policies
Hi, I have a question, is it possible to monitor the ecs auto scaling in metrics?
If yes, how can we do that?
Hi, thanks for your question.
Yes, it's possible.
Do you want to get the alert notification when the service is auto-scaled, or do you want to get any other monitoring action?
Hi, thanks for the response.
I don't need an alert, I just want to see the number of running tasks in metrics along with cpu and memory utilisation.
Got it, thanks for the clarification. In that case, you can create a custom AWS CloudWatch Dashboard and visualize the number of running ECS tasks with the respective widget there.
while creating an alarm i am not able to fetch my metric which i have created
Thanks for your feedback. There were some issues recently with ECS metrics, so I've made some updates in the Gist with the Terraform code. You can find the updated configuration by this link: gist.github.com/kuzemkon/03633f2e8aeb801053b18162db7f28e2
if you are creating the alarm from the console, you can easily click on the metric filter when you go to log-group>meetric-filter and use the create alarm button there