AWS Serverless and Lambda Architecture 2 — Questions and Answers
Question 1: What is the maximum deployment package size for a Lambda function uploaded directly (not via S3)?
- 10 MB
- 50 MB (Correct answer)
- 250 MB
- 500 MB
Correct answer: 50 MB
Lambda allows a maximum direct upload package size of 50 MB; larger packages must be uploaded via Amazon S3.
Question 2: Which invocation type causes Lambda to process events asynchronously and retry automatically on failure?
- Synchronous invocation
- Asynchronous invocation (Correct answer)
- Polling invocation
- Direct invocation
Correct answer: Asynchronous invocation
Asynchronous invocation places the event in an internal queue and Lambda retries failed executions up to two additional times.
Question 3: A company wants to run serverless container workloads without managing servers. Which AWS service should they use?
- AWS Fargate (Correct answer)
- AWS Lambda
- Amazon EKS
- AWS Elastic Beanstalk
Correct answer: AWS Fargate
AWS Fargate is a serverless compute engine for containers that removes the need to provision or manage EC2 instances.
Question 4: Which AWS Lambda resource-based policy feature controls which AWS services or accounts can invoke your function?
- Execution role
- Resource policy (Correct answer)
- Lambda alias
- Environment variable encryption
Correct answer: Resource policy
A Lambda resource-based policy (function policy) grants permissions to other AWS accounts or services to invoke the function.
Question 5: What happens when a Lambda function's reserved concurrency is set to 0?
- The function scales without limit
- The function is throttled and cannot be invoked (Correct answer)
- The function uses on-demand concurrency only
- The function is deleted
Correct answer: The function is throttled and cannot be invoked
Setting reserved concurrency to 0 effectively throttles the function, preventing any invocations.
Question 6: Which trigger allows Lambda to automatically process messages from an Amazon SQS queue?
- Lambda Destination
- Event Source Mapping (Correct answer)
- SNS Subscription
- S3 Event Notification
Correct answer: Event Source Mapping
An Event Source Mapping enables Lambda to poll an SQS queue and invoke the function with batches of messages.
What is the maximum deployment package size for a Lambda function uploaded directly (not via S3)?