nerdexam
AmazonAmazon

DOP-C02 · Question #303

DOP-C02 Question #303: Real Exam Question with Answer & Explanation

The correct answer is B: Create an Amazon CloudWatch metric alarm with a period of 1 hour and a static threshold to. The ApproximateNumberOfMessagesVisible CloudWatch metric provides a count of the messages in the SQS queue that are ready to be processed (i.e., not yet picked up by consumers). When this metric exceeds the expected value, it indicates that the queue is growing beyond normal limi

Submitted by suresh_in· Mar 6, 2026Monitoring and Logging

Question

A DevOps team manages infrastructure for an application. The application uses long-running processes to process items from an Amazon Simple Queue Service (Amazon SQS) queue. The application is deployed to an Auto Scaling group. The application recently experienced an issue where items were taking significantly longer to process. The queue exceeded the expected size, which prevented various business processes from functioning properly. The application records all logs to a third-party tool. The team is currently subscribed to an Amazon Simple Notification Service (Amazon SNS) topic that the team uses for alerts. The team needs to be alerted if the queue exceeds the expected size. Which solution will meet these requirements with the MOST operational efficiency?

Options

  • ACreate an Amazon CloudWatch metric alarm with a period of 1 hour and a static threshold to
  • BCreate an Amazon CloudWatch metric alarm with a period of 1 hour and a static threshold to
  • CCreate an AWS Lambda function that retrieves the ApproximateNumberOfMessages SQS queue
  • DCreate an AWS Lambda function that checks the ApproximateNumberOfMessagesDelayed SQS

Explanation

The ApproximateNumberOfMessagesVisible CloudWatch metric provides a count of the messages in the SQS queue that are ready to be processed (i.e., not yet picked up by consumers). When this metric exceeds the expected value, it indicates that the queue is growing beyond normal limits, potentially leading to delayed processing. By creating a CloudWatch metric alarm on the ApproximateNumberOfMessagesVisible metric, you can efficiently monitor the queue's size without needing to build or maintain custom logic. CloudWatch is already integrated with SQS metrics, so this solution leverages AWS-native features to provide alerts. The alarm can be configured with a static threshold based on the expected queue size. When the threshold is breached, the alarm will trigger and send a notification to the SNS topic, which the DevOps team is already subscribed to. This approach uses an existing feature in CloudWatch to monitor the sum of the messages over a period of time, ensuring that the team is notified if the queue grows too large. This avoids the need for additional tools or complex configurations, making it the most operationally efficient

Topics

#Amazon SQS#CloudWatch Alarms#Queue monitoring#Backlog detection

Community Discussion

No community discussion yet for this question.

Full DOP-C02 PracticeBrowse All DOP-C02 Questions