How should the developer configure the Lambda function to detect changes to the DynamoDB table?
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.
Create an Amazon EventBridge (Amazon CloudWatch Events) rule to invoke the Lambda function on a regular schedule. Connect to the DynamoDB table from the Lambda function to detect changes.
Enable DynamoDB Streams on the table. Create a trigger to connect the DynamoDB stream to the Lambda function.
Create an Amazon Kinesis Data Firehose delivery stream, and attach it to the DynamoDB table. Configure the delivery stream destination as the Lambda function.
Explanations:
Amazon Kinesis data streams are not directly attached to DynamoDB tables. DynamoDB Streams should be used instead to track changes in the table.
Amazon EventBridge rules invoke Lambda on a schedule, which isn’t appropriate for detecting immediate changes in DynamoDB tables. DynamoDB Streams should be used for real-time changes.
DynamoDB Streams allows tracking of changes to the DynamoDB table and can trigger the Lambda function whenever changes occur in the table.
Amazon Kinesis Data Firehose is not used to detect DynamoDB table changes. It is for streaming data to destinations like Amazon S3, not for processing real-time changes from DynamoDB.