A company runs its application using Amazon EC2 instances and AWS Lambda functions. The EC2 instances are in private subnets of a VPC. The Lambda functions require direct network access to the EC2 instances for the application to work. The application will run for 1 year, and the number of Lambda functions used will increase during that year. The company must minimize costs across all application resources. Which solution meets these requirements?
Choose an answer
Tap an option to check your answer.
Correct answer: Purchase a Compute Savings Plan. Connect the Lambda functions to the private subnets that contain the EC2 instances..
Why this is the answer
The correct solution is to purchase a Compute Savings Plan and connect the Lambda functions to the private subnets that contain the EC2 instances. A Compute Savings Plan offers the most flexibility and cost savings for both EC2 instances and Lambda functions, as it applies to any EC2 instance usage regardless of family, size, OS, or region, and also covers Fargate and Lambda usage. This aligns with the requirement to minimize costs across all application resources, especially as Lambda usage increases. Connecting Lambda functions to the private subnets where the EC2 instances reside provides direct network access, fulfilling the application's requirement. Purchasing an EC2 Instance Savings Plan would only cover EC2 costs and not Lambda, making it less cost-effective overall. Connecting Lambda functions to public subnets is not ideal for security and might not allow direct access to private EC2 instances without additional networking configurations. Keeping Lambda functions in the Lambda service VPC would prevent direct network access to the EC2 instances in the company's VPC.
Pass your exam — without the endless answer hunt
Get every verified question and explanation for this exam in one place, and save hours of prep. 1,000+ certifications · 20+ languages · free to start.
Pass your exam faster → No card needed