Question #662
A company operates a serverless application in a single AWS Region. The application processes web content by retrieving external URLs and extracting site data. The company uses an Amazon Simple Notification Service (Amazon SNS) topic to send URLs to an Amazon Simple Queue Service (Amazon SQS) queue. An AWS Lambda function processes the URLs from the queue and saves results to an Amazon S3 bucket in the same Region.
The company now needs to process each URL in multiple Regions to analyze regional content variations. URLs must originate from the existing Region, and results must be stored in the original S3 bucket.
Which combination of steps will create a multi-Region deployment that fulfills these requirements? (Choose two.)
Deploy the SQS queue and Lambda function to additional Regions.
Subscribe the SNS topic in each Region to the local SQS queue.
Subscribe the SQS queues in other Regions to the central SNS topic.
Configure the SQS queue to forward URLs to SNS topics in other Regions.
Deploy the SNS topic and Lambda function to all Regions.
Explanation
The solution requires distributing URLs from the central SNS topic in the original Region to SQS queues in multiple Regions.
- A is correct because deploying SQS queues and Lambda functions to additional Regions allows processing URLs locally in each Region. The Lambda functions can then save results to the original S3 bucket.
- C is correct because subscribing SQS queues in other Regions to the central SNS topic enables cross-Region message delivery. The central SNS topic can publish messages to SQS queues in any Region.
Other options are incorrect:
- B: Subscribing regional SNS topics to local SQS queues is unnecessary, as the SNS topic remains centralized.
- D: SQS cannot forward messages to SNS topics directly; this requires a separate mechanism.
- E: Deploying the SNS topic to all Regions violates the requirement that URLs originate from the existing Region.
Key Points:
1. SNS supports cross-Region subscriptions to SQS queues.
2. SQS queues and Lambda functions must be deployed per Region for local processing.
3. The original S3 bucket remains the storage endpoint regardless of processing Region.
Answer
The correct answer is: AC