DVA-C02 · Question #52
A developer has created an AWS Lambda function that is written in Python. The Lambda function reads data from objects in Amazon S3 and writes data to an Amazon DynamoDB table. The function is successf
The correct answer is C. The Lambda function does not have IAM permissions to write to DynamoDB.. The Lambda function needs to have the appropriate IAM permissions to write to the DynamoDB table. If the function does not have these permissions, it will fail when it attempts to write to the https://aws.amazon.com/blogs/security/how-to-create-an-aws-iam-policy-to-grant-aws-lamb
Question
A developer has created an AWS Lambda function that is written in Python. The Lambda function reads data from objects in Amazon S3 and writes data to an Amazon DynamoDB table. The function is successfully invoked from an S3 event notification when an object is created. However, the function fails when it attempts to write to the DynamoDB table. What is the MOST likely cause of this issue?
Options
- AThe Lambda function's concurrency limit has been exceeded.
- BDynamoDB table requires a global secondary index (GSI) to support writes.
- CThe Lambda function does not have IAM permissions to write to DynamoDB.
- DThe DynamoDB table is not running in the same Availability Zone as the Lambda function.
How the community answered
(45 responses)- A4% (2)
- B7% (3)
- C87% (39)
- D2% (1)
Explanation
The Lambda function needs to have the appropriate IAM permissions to write to the DynamoDB table. If the function does not have these permissions, it will fail when it attempts to write to the https://aws.amazon.com/blogs/security/how-to-create-an-aws-iam-policy-to-grant-aws-lambda- access-to-an-amazon-dynamodb-table
Community Discussion
No community discussion yet for this question.