DOP-C02 Question 203
Select 3Your organization runs a microservices-based application on Amazon ECS with Fargate. The application is experiencing intermittent latency issues, and the team suspects that specific services are encountering memory and CPU resource constraints. As a DevOps Engineer, you need to implement a monitoring solution to identify bottlenecks and resource issues efficiently. Which combination of steps should you take to achieve this?
- A
Enable Amazon CloudWatch Container Insights for the ECS cluster to collect detailed performance metrics and logs for the services.
- B
Use AWS X-Ray to trace the requests and identify which services are contributing to the latency.
- C
Set up custom CloudWatch Alarms on Fargate task memory and CPU utilization metrics to alert when thresholds are breached.
- D
Install the CloudWatch Agent on the Fargate tasks to collect detailed OS-level metrics for memory and CPU usage.
- E
Enable AWS Config rules to monitor the configuration compliance of ECS services to ensure they are using the optimal task definitions.
Show answer and explanation
Correct answers: A, B, C
Explanation
To effectively monitor and troubleshoot the latency issues in a microservices-based application running on ECS with Fargate, you need to use tools like CloudWatch Container Insights for detailed resource metrics, AWS X-Ray for tracing request paths across services, and CloudWatch Alarms for proactive resource monitoring. These steps ensure you can identify and address the root cause of latency issues efficiently. Options involving the CloudWatch Agent or AWS Config are irrelevant for this scenario.
- A. Correct.
Enabling Amazon CloudWatch Container Insights provides granular metrics such as memory, CPU usage, and network usage for ECS services, which is vital for identifying resource constraints.
- B. Correct.
AWS X-Ray is designed to trace requests across distributed services, helping identify which specific services are causing latency issues.
- C. Correct.
Setting up custom CloudWatch Alarms on memory and CPU utilization ensures you get notified when resources are constrained, allowing for proactive resolution of the issue.
- D. Incorrect.
The CloudWatch Agent cannot be installed on Fargate tasks as Fargate is a serverless compute engine. Metrics for Fargate are natively collected via CloudWatch without requiring an agent.
- E. Incorrect.
AWS Config rules are used for compliance and configuration drift detection, not for monitoring performance or resource constraints.