Quizzes · Service

Lambda

Level 0 questions on Lambda. Read about it first if it's new to you.

Works with: IAM (10), VPC (7), DynamoDB (5), API Gateway (5), EC2 (4), SQS (4), ECS + Fargate (3), RDS (2), CloudWatch Logs (1)

  • 15 questions, from a pool of 26
  • Most have 1 correct answer of 4; some ask for 2 of 5
  • Pass line 80%

Questions and answers come in a new order every time, and every choice is explained. Your answers feed your weak spots on the exam page; they don't change your exam score.

Question 1A Todo.io Lambda function must write to a DynamoDB table. How should it get that permission?

Choose one answer

Learn it: IAM role · Lambda

Question 2A developer may create Lambda functions, but gets AccessDenied when choosing an existing execution role for a new function. What is missing?

Choose one answer

Learn it: iam:PassRole

Question 3What does a security group attach to?

Choose one answer

Learn it: ENI (Elastic Network Interface) · Security group

Question 4Todo.io's backend runs on Lambda. Browsers need an HTTPS address to send requests to. What should sit in front of the function?

Choose one answer

Learn it: API Gateway

Question 5Todo.io's API Gateway invokes its Lambda function. In Todo.io's setup, which policy says that API Gateway may invoke the function?

Choose one answer

Learn it: API Gateway · IAM policy · Lambda

Question 6Todo.io's Lambda function tries to push a message to a browser by POSTing to the WebSocket API's @connections URL, and gets AccessDenied. What fixes it?

Choose one answer

Learn it: WebSocket (API Gateway WebSocket API) · IAM policy

Question 7Todo.io wants an API with no servers to patch or scale. Which combination is the classic serverless pattern?

Choose one answer

Learn it: API Gateway · Lambda

Question 8Todo.io attaches its Lambda function to the VPC so it can reach the MySQL database in a private subnet. Since then, the function's calls to SQS time out. IAM allows sqs:SendMessage. What fixes it?

Choose one answer

Learn it: NAT gateway · Lambda · IAM policy · ENI

Question 9Todo.io's Lambda function processes large uploads and always stops at exactly 15 minutes, unfinished. What is the right fix?

Choose one answer

Learn it: Lambda

Question 10How is Todo.io billed for a Lambda function?

Choose one answer

Learn it: Lambda

Question 11Todo.io creates a new Lambda function and doesn't attach it to any VPC. Can it call DynamoDB?

Choose one answer

Learn it: Lambda · DynamoDB

Question 12When should Todo.io attach a Lambda function to its VPC?

Choose one answer

Learn it: Lambda

Question 13How many execution roles does a Lambda function have?

Choose one answer

Learn it: Lambda · IAM role

Question 14Todo.io's Lambda function prints log lines, but nothing appears in CloudWatch Logs. What is the most likely cause?

Choose one answer

Learn it: Lambda · CloudWatch Logs

Question 15Todo.io's worker is a Lambda function that handles messages from an SQS queue. How do the messages reach the function?

Choose one answer

Learn it: Lambda · SQS

Question 16A Lambda function with a 60-second timeout processes an SQS queue whose visibility timeout is 30 seconds. Some messages are processed twice. What is the fix?

Choose one answer

Learn it: Lambda · SQS (Simple Queue Service)

Question 17Todo.io moves its API to Lambda. Which of these is still Todo.io's job?

Choose one answer

Learn it: Lambda

Question 18A Lambda function that isn't attached to a VPC writes to DynamoDB. Which security group is involved?

Choose one answer

Learn it: DynamoDB · Security group

Question 19Todo.io moves its app from an EC2 instance to a Lambda function. On EC2, the app wrote to DynamoDB with a role attached through an instance profile. What gives the function the same access?

Choose one answer

Learn it: Lambda · EC2 (Elastic Compute Cloud) · IAM role

Question 20Todo.io's API gets a few hundred requests a day and sits idle most of the night, yet it runs on an EC2 instance around the clock. Which swap cuts the cost of the idle hours the most?

Choose one answer

Learn it: Lambda · EC2 (Elastic Compute Cloud) · ECS and Fargate

Question 21Todo.io's Lambda function, not attached to any VPC, swaps its DynamoDB table for an RDS MySQL database in a private subnet. Which two network changes let the function reach the database?

Choose two answers

Choose two.

Learn it: Lambda · Subnet · Security group · RDS (Relational Database Service) · NAT gateway

Question 22On EC2, browsers reached Todo.io's app through the internet gateway, at the server's public IP. Todo.io moves the app to a Lambda function. What is the front door now?

Choose one answer

Learn it: API Gateway · NAT gateway · VPC (Virtual Private Cloud) · Security group · Internet gateway

Question 23Todo.io moves "update the monthly stats" out of its API function and into a worker, with an SQS queue between them. What should the API function's execution role gain?

Choose one answer

Learn it: SQS (Simple Queue Service) · Lambda · IAM policy · VPC (Virtual Private Cloud)

Question 24What does "Lambda" mean?

Choose one answer

Learn it: Lambda

Question 25Which term is this? "Upload a function; AWS runs it only when something calls it."

Choose one answer

Learn it: Lambda

Question 26Which AWS term is described by this analogy? "A taxi. You pay for the ride, not for owning the car."

Choose one answer

Learn it: Lambda