Q24 — AWS SAP-C02 Ch.1
Question 24 of 75 | ← Chapter 1
Q99. A company is running a traditional web application on Amazon EC2 instances. The company needs to refactor the application as microservices that run on containers. Separate versions of the application exist in two distinct environments: production and testing. Load for the application is variable, but the minimum load and the maximum load are known.A solutions architect needs to design the updated application with a serverless architecture that minimizes operational complexity. Which solution will meet these requirements MOST cost-effectively?
- A. Upload the container images to AWS Lambda as functions. Configure a concurrency limit for the associated Lambda functions to handle the expected peak load. Configure two separate Lambda integrations within Amazon API Gateway: one for production and one for testing.
- B. Upload the container images to Amazon Elastic Container Registry (Amazon ECR). Configure two auto scaled Amazon Elastic Container Service (Amazon ECS) clusters with the Fargate launch type to handle the expected load. Deploy tasks from the ECR images. Configure two separate Application Load Balancers to direct traffic to the ECS clusters. ✓
- C. Upload the container images to Amazon Elastic Container Registry (Amazon ECR). Configure two auto scaled Amazon Elastic Kubernetes Service (Amazon EKS) clusters with the Fargate launch type to handle the expected load. Deploy tasks from the ECR images. Configure two separate Application Load Balancers to direct traic to the EKS clusters.
- D. Upload the container images to AWS Elastic Beanstalk. In Elastic Beanstalk, create separate environments and deployments for production and testing. Configure two separate Application Load Balancers to direct traffic to the Elastic Beanstalk deployments
Correct Answer: B. Upload the container images to Amazon Elastic Container Registry (Amazon ECR). Configure two auto scaled Amazon Elastic Container Service (Amazon ECS) clusters with the Fargate launch type to handle the expected load. Deploy tasks from the ECR images. Configure two separate Application Load Balancers to direct traffic to the ECS clusters.
Explanation
To refactor the traditional web application into microservices running on containers with a serverless architecture that minimizes operational complexity and is cost-effective, the following solution can be implemented: B. Upload the container images to Amazon Elastic Container Registry (Amazon ECR). Configure two auto-scaled Amazon Elastic Container Service (Amazon ECS) clusters with the Fargate launch type to handle the expected load. Deploy tasks from the ECR images. Configure two separate Application Load Balancers to direct traffic to the ECS clusters. By uploading the container images to Amazon ECR, the company can store and manage the container images in a secure and scalable registry. Configuring two auto-scaled Amazon ECS clusters with the Fargate launch type allows for the efficient management of containerized microservices. The ECS clusters can automatically scale up or down based on the load, ensuring optimal resource utilization. Deploying tasks from the ECR images allows for easy provisioning and management of containers. Configuring two separate Application Load Balancers ensures that traffic can be directed to the appropriate ECS clusters based on the environment (production or testing). This solution leverages the benefits of containerization, auto-scaling, and load balancing while minimizing operational complexity. It also provides cost-effectiveness by dynamically scaling resources based on load and utilizing serverless capabilities for container management. Therefore, the solution that meets the requirements most cost-effectively is to upload the container images to Amazon ECR, configure two auto-scaled Amazon ECS clusters with the Fargate launch type, and deploy tasks from the ECR images. Additionally, configure two separate Application Load Balancers to direct traffic to the ECS clusters.