DVA-C02 Development with AWS Services Practice Question
A developer is creating an AWS Lambda function that processes messages from an Amazon SQS queue. The function should process each message only once. Which SQS queue type should the developer use?
⚠ Common exam trap
Test-takers frequently assume Standard queues are sufficient because they are the default, but they overlook the fact that Standard queues provide at-least-once delivery, not exactly-once, which directly contradicts the requirement to process each message only once.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
FIFO queue
Amazon SQS FIFO (First-In-First-Out) queues guarantee exactly-once processing within a message group. They use a deduplication ID (either content-based or explicitly provided) to prevent duplicate message delivery, ensuring that each message is processed only once by the consumer.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Amazon SQS does not support exactly-once processing.
Why it's wrong here
This statement is incorrect because Amazon SQS, as a service, does offer exactly-once processing guarantees through its First-In, First-Out (FIFO) queue type. While standard SQS queues provide at-least-once delivery and may deliver duplicates, FIFO queues ensure that messages are processed exactly once and in the order they were sent. Therefore, stating that SQS *as a whole* lacks this capability is a misrepresentation of its full feature set.
- ✗
Dead-letter queue
Why it's wrong here
A Dead-Letter Queue (DLQ) is primarily used as an error handling mechanism to capture messages that a consumer failed to process successfully after a specified number of retries. While crucial for building robust, fault-tolerant applications, a DLQ does not inherently provide exactly-once processing for the primary message flow. Its function is to isolate problematic messages for later analysis or reprocessing, not to guarantee the unique processing of every message in the main queue.
- ✓
FIFO queue
Why this is correct
An Amazon SQS FIFO queue is the correct choice for scenarios requiring exactly-once processing and strict message ordering. It achieves this by preventing duplicate messages from being sent to the queue using a deduplication ID or content-based deduplication, and by ensuring that a message is delivered to a consumer, processed, and deleted before the next message in its message group is delivered. This guarantee is critical for applications where message order and uniqueness are paramount, such as financial transactions or order processing systems.
- ✗
Standard queue
Why it's wrong here
An Amazon SQS Standard queue is designed for maximum throughput and best-effort ordering, making it unsuitable for applications requiring exactly-once processing. Standard queues provide at-least-once delivery, meaning a message might be delivered more than once, and message order is not strictly preserved. While highly scalable and cost-effective for many use cases, its inherent design prioritizes availability and throughput over the stringent requirements of exactly-once processing and strict ordering.
Quick reference
Cloud Service Model Comparison
| Model | You Manage | Provider Manages | Examples |
|---|---|---|---|
| IaaS | OS, runtime, apps, data | Hardware, hypervisor, networking | EC2, Azure VMs, GCP Compute Engine |
| PaaS | Apps and data | OS, runtime, middleware, hardware | Elastic Beanstalk, Azure App Service |
| SaaS | Data and settings only | Everything else | Microsoft 365, Salesforce, Workday |
| FaaS / Serverless | Function code only | Infra, scaling, runtime | Lambda, Azure Functions, Cloud Run |
| CaaS | Containers and apps | Kubernetes, OS, hardware | EKS, AKS, GKE |
Go deeper
Related to this question
About these practice questions
This DVA-C02 question is part of Courseiva's 1,135-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This DVA-C02 practice question is part of Courseiva's free Amazon Web Services certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the DVA-C02 exam.