
Answer-first summary for fast verification
Answer: Use the local directory /tmp
Overall explanation Correct option: Use the local directory /tmp This is 512MB of temporary space you can use for your Lambda functions. Incorrect options: Create a tmp/ directory in the source zip file and use it - This option has been added as a distractor, as you can't access a directory within a zip file. Use the local directory /opt - This option has been added as a distractor. This path is not accessible. Use an S3 bucket - This won't be temporary after the Lambda function is deleted, so this option is incorrect.
Author: LeetQuiz Editorial Team
Ultimate access to all questions.
Your Lambda function is designed to handle file processing tasks for your customers. During this process, the function generates numerous intermediary files that need to be temporarily stored on disk. These files are only required for the duration of the function's execution and are discarded once the function completes its task and stops running.
What is the most efficient method to temporarily store these files for your Lambda functions, ensuring they are discarded once the function execution ends?
A
Use the local directory /opt
B
Use the local directory /tmp
C
Create a tmp/ directory in the source zip file and use it
D
Use an S3 bucket
No comments yet.