A Python AWS Lambda function is triggered by S3 object-creation events; it reads from S3 and writes to a DynamoDB table. The function executes on invocation but fails when attempting to write to DynamoDB. What is the MOST likely cause?
Choose an answer
Tap an option to check your answer.
Correct answer: The Lambda function’s IAM role does not have permission to write to the DynamoDB table..
Why this is the answer
The most likely cause for a Lambda function failing to write to DynamoDB is insufficient permissions. AWS services operate on the principle of least privilege, meaning the Lambda function's execution role must explicitly grant dynamodb:PutItem (or similar write actions) permissions to the target DynamoDB table. Without these permissions, the write operation will be denied. Incorrect options: Concurrency limits typically prevent the function from invoking or cause throttling errors, not permission-related write failures once invoked. DynamoDB write operations do not inherently require a GSI; GSIs are for optimizing query patterns, not for basic write functionality. DynamoDB is a regional service, and its tables are replicated across multiple Availability Zones within a region. The physical location of a Lambda function within an AZ relative to a DynamoDB table's underlying infrastructure does not cause permission errors.
Pass your exam — without the endless answer hunt
Get every verified question and explanation for this exam in one place, and save hours of prep. 1,000+ certifications · 20+ languages · free to start.
Pass your exam faster → No card needed