A digital publishing company is building an automated newsletter system. When articles are published or updated, metadata events must be processed in sequence to update the search index and subscriber email caches. The publishing rate can spike dramatically during breaking news events, and downstream update workers sometimes experience transient database connection timeouts. The company needs a resilient, decoupled architecture that processes updates in the order they occur per article, buffers traffic spikes, and ensures that failing messages do not block the processing of other articles. Which TWO actions should the solutions architect take to meet these requirements? (Select TWO.)
- Send the article update events to an Amazon SQS FIFO queue, setting the article ID as the message group ID.Answer
- Configure a dead-letter queue (DLQ) on the main Amazon SQS FIFO queue to capture messages that fail to process after the maximum receive count is exceeded.Answer
- CSend the article update events to an Amazon SQS Standard queue and enable message deduplication using the MessageDeduplicationId parameter.
- DSend the article update events to an Amazon SQS Standard queue and configure a dead-letter queue (DLQ) to handle failed messages while ensuring ordered delivery by setting the visibility timeout to zero.
Answer
To achieve decoupling, order preservation, and fault tolerance, the solution must use an Amazon SQS FIFO queue with the article ID as the MessageGroupId, combined with a Dead-Letter Queue (DLQ) to handle processing failures without blocking other articles.
To decouple the systems while maintaining strict order processing per article, a Solutions Architect should use an Amazon SQS FIFO (First-In-First-Out) queue. By setting the article ID as the MessageGroupId, SQS ensures that messages belonging to the same article are processed sequentially in the order they were received. Setting up a dead-letter queue (DLQ) ensures that poison-pill messages (those that fail repeatedly) are isolated after a specified number of attempts, allowing other messages in the queue to continue processing without blocking the pipeline.
Step-by-Step Solution
Key Concept
Decoupling message processing using SQS FIFO queues and MessageGroupIds to maintain ordering, combined with DLQs to handle poison-pill messages.