
Ultimate access to all questions.
Deep dive into the quiz with AI chat providers.
We prepare a focused prompt with your quiz and certificate details so each AI can offer a more tailored, in-depth explanation.
A company is hosting a three-tier ecommerce application in the AWS Cloud. The company hosts the website on Amazon S3 and integrates the website with an API that handles sales requests. The company hosts the API on three Amazon EC2 instances behind an Application Load Balancer (ALB). The API consists of static and dynamic front-end content along with backend workers that process sales requests asynchronously.
The company is expecting a significant and sudden increase in the number of sales requests during events for the launch of new products.
What should a solutions architect recommend to ensure that all the requests are processed successfully?
A
Add an Amazon CloudFront distribution for the dynamic content. Increase the number of EC2 instances to handle the increase in traffic.
B
Add an Amazon CloudFront distribution for the static content. Place the EC2 instances in an Auto Scaling group to launch new instances based on network traffic.
C
Add an Amazon CloudFront distribution for the dynamic content. Add an Amazon ElastiCache instance in front of the ALB to reduce traffic for the API to handle.
D
Add an Amazon CloudFront distribution for the static content. Add an Amazon Simple Queue Service (Amazon SQS) queue to receive requests from the website for later processing by the EC2 instances.
Explanation:
Correct Answer: D
Why Option D is correct:
Amazon CloudFront for static content: The website is hosted on Amazon S3, which serves static content. CloudFront is a content delivery network (CDN) that caches static content at edge locations, reducing latency and offloading traffic from the origin servers. This is the appropriate use of CloudFront for static content.
Amazon SQS for asynchronous processing: The scenario mentions that the API has "backend workers that process sales requests asynchronously." This is a perfect use case for Amazon SQS (Simple Queue Service). During traffic spikes, sales requests can be placed in an SQS queue, and EC2 instances can process them at their own pace. This decouples the front-end request handling from the backend processing, ensuring that requests are not lost during traffic surges.
Why other options are incorrect:
Option A: Incorrect because:
Option B: Partially correct about CloudFront for static content, but:
Option C: Incorrect because:
Key architectural principles demonstrated:
This solution ensures that all sales requests are received and queued for processing, even during sudden traffic increases, without overwhelming the backend systems.