AWS Certified Developer – Associate (DVA-C02) — Question 465
A company is hosting an Amazon AP! Gateway REST API that calls a single AWS Lambda function. The function is infrequently invoked by multiple clients at the same time.
The code performance is optimal, but the company wants to optimize the startup time of the function
What can a developer do to optimize the initialization of the function?
Answer options
- A. Enable API Gateway caching for the REST API.
- B. Configure provisioned concurrency for the Lambda function.
- C. Use Lambda proxy integration for the REST API.
- D. Configure AWS Global Accelerator for the Lambda function.
Correct answer: B
Explanation
Provisioned concurrency pre-warms a specified number of Lambda execution environments, effectively eliminating cold starts and optimizing the startup/initialization time for infrequent, concurrent requests. API Gateway caching only caches responses and does not speed up the Lambda initialization phase when a cache miss occurs. Lambda proxy integration and AWS Global Accelerator address request routing and network transport latency rather than function initialization performance.