
Answer-first summary for fast verification
Answer: Storing files in the Lambda's /tmp directory.
The correct answer is C. AWS Lambda provides a /tmp directory in its execution environment with a storage limit of 512 MB, which can be increased up to 10 GB if needed. This space is intended for temporary storage during the function's execution. Given that the required storage is 100 MB, it fits well within the limits of the /tmp directory. Using this directory is both efficient and cost-effective, as it does not involve additional services or costs, and AWS Lambda manages the cleanup of this directory automatically after the function execution is complete.
Author: LeetQuiz Editorial Team
Ultimate access to all questions.
How should a developer efficiently manage 100 MB of temporary storage for a Lambda function generating and exporting files, with no need to retain the files post-execution?
A
Using Amazon EBS and deleting files post-execution.
B
Utilizing Amazon EFS and removing files after execution.
C
Storing files in the Lambda's /tmp directory.
D
Placing files in an S3 bucket with a deletion lifecycle policy.
No comments yet.