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 rule to invoke the Lambda function on a regular schedule. Conned 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 can be used for real-time data processing but are not directly linked to DynamoDB table changes. Instead, DynamoDB Streams is the service that captures changes, and Kinesis would require additional integration steps, making this option less efficient.
Using Amazon EventBridge to invoke the Lambda function on a schedule does not provide real-time processing of changes to the DynamoDB table. It would be more suitable for regular polling rather than event-driven architecture.
Enabling DynamoDB Streams on the table allows capturing changes (inserts, updates, deletes) in real time. Creating a trigger connects the DynamoDB stream to the Lambda function, allowing it to process these changes as they occur.
Amazon Kinesis Data Firehose is used for delivering real-time streaming data to destinations like S3 or Redshift. While it can process data, it is not designed to directly detect changes in a DynamoDB table and would require additional configurations, making this option less appropriate for real-time change detection.