CLF-C02 Question 259
Single answerA company needs to build a scalable web application that handles unpredictable traffic spikes, requires minimal management effort, and only charges for the compute capacity actually consumed. Which AWS service is the most appropriate for this use case?
- A
Amazon EC2
- B
AWS Lambda
- C
Amazon RDS
- D
Amazon Elastic Kubernetes Service (EKS)
Show answer and explanation
Correct answer: B
Explanation
AWS Lambda is the most appropriate service for building a scalable web application with unpredictable traffic spikes. It is a serverless, fully managed service that automatically scales up or down based on demand. Additionally, Lambda charges only for the compute time consumed, ensuring cost efficiency. Other options, such as Amazon EC2 and Amazon EKS, involve infrastructure management, which contradicts the requirement for minimal management effort.
- A. Incorrect.
Amazon EC2 provides scalable virtual server instances, but it requires managing the underlying infrastructure, including scaling and provisioning, which is not ideal for unpredictable traffic spikes.
- B. Correct.
AWS Lambda is a serverless compute service that automatically scales to handle unpredictable traffic. It requires no management of servers and charges only for the compute time used, making it the best fit for this use case.
- C. Incorrect.
Amazon RDS is a managed relational database service. While it simplifies database management, it is not a compute service and does not address the requirements of handling unpredictable traffic spikes in a web application.
- D. Incorrect.
Amazon EKS is a managed Kubernetes service for container orchestration. While it supports scalability, it requires managing Kubernetes clusters, which adds complexity and is unnecessary for this scenario.