Q39 — AWS DVA-C02 Ch.1
Question 39 of 100 | ← Chapter 1
A developer is building a serverless application and needs to use an AWS Lambda function to process any changes to an Amazon DynamoDB table. How should the developer configure the Lambda function to detect changes to the DynamoDB table?
- A. Create an Amazon Kinesis data stream and attach it to the DynamoDB table. Create a trigger to connect the data stream to the Lambda function.
- B. Create an Amazon EventBridge rule to invoke the Lambda function periodically. Connect the Lambda function to the DynamoDB table to poll for changes.
- C. Enable DynamoDB Streams on the table. Create a trigger to connect the DynamoDB stream to the Lambda function. ✓
- D. Create an Amazon Kinesis Data Firehose delivery stream and attach it to the DynamoDB table. Configure the delivery stream destination as the Lambda function.
Correct Answer: C. Enable DynamoDB Streams on the table. Create a trigger to connect the DynamoDB stream to the Lambda function.
Explanation
To detect changes to a DynamoDB table, the optimal approach is to enable DynamoDB Streams. DynamoDB Streams is a real-time streaming service that captures item-level modifications and delivers them to a Lambda function via a stream-trigger integration. Thus, Option C is the best choice. Other options involve polling (B), or indirect streaming via Kinesis (A, D), which are less direct and efficient. 【Lantern Certification provided by: swufelp1999】