ExamGecko
Question list
Search
Search

List of questions

Search

Related questions











Question 52 - DVA-C02 discussion

Report
Export

A developer is designing a serverless application with two AWS Lambda functions to process photos. One Lambda function stores objects in an Amazon S3 bucket and stores the associated metadata in an Amazon DynamoDB table. The other Lambda function fetches the objects from the S3 bucket by using the metadata from the DynamoDB table. Both Lambda functions use the same Python library to perform complex computations and are approaching the quota for the maximum size of zipped deployment packages.

What should the developer do to reduce the size of the Lambda deployment packages with the LEAST operational overhead?

A.
Package each Python library in its own .zip file archive. Deploy each Lambda function with its own copy of the library.
Answers
A.
Package each Python library in its own .zip file archive. Deploy each Lambda function with its own copy of the library.
B.
Create a Lambda layer with the required Python library. Use the Lambda layer in both Lambda functions.
Answers
B.
Create a Lambda layer with the required Python library. Use the Lambda layer in both Lambda functions.
C.
Combine the two Lambda functions into one Lambda function. Deploy the Lambda function as a single .zip file archive.
Answers
C.
Combine the two Lambda functions into one Lambda function. Deploy the Lambda function as a single .zip file archive.
D.
Download the Python library to an S3 bucket. Program the Lambda functions to reference the object URLs.
Answers
D.
Download the Python library to an S3 bucket. Program the Lambda functions to reference the object URLs.
Suggested answer: B

Explanation:

AWS Lambda is a service that lets developers run code without provisioning or managing servers. Lambda layers are a distribution mechanism for libraries, custom runtimes, and other dependencies. The developer can create a Lambda layer with the required Python library and use the layer in both Lambda functions. This will reduce the size of the Lambda deployment packages and avoid reaching the quota for the maximum size of zipped deployment packages. The developer can also benefit from using layers to manage dependencies separately from function code.

Reference:

[What Is AWS Lambda? - AWS Lambda]

[AWS Lambda Layers - AWS Lambda]

asked 16/09/2024
Lars Bleckmann
41 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first