Topic 1 Question 117
A developer maintains a critical business application that uses Amazon DynamoDB as the primary data store. The DynamoDB table contains millions of documents and receives 30-60 requests each minute. The developer needs to perform processing in near-real time on the documents when they are added or updated in the DynamoDB table.
How can the developer implement this feature with the LEAST amount of change to the existing application code?
Set up a cron job on an Amazon EC2 instance. Run a script every hour to query the table for changes and process the documents.
Enable a DynamoDB stream on the table. Invoke an AWS Lambda function to process the documents.
Update the application to send a PutEvents request to Amazon EventBridge. Create an EventBridge rule to invoke an AWS Lambda function to process the documents.
Update the application to synchronously process the documents directly after the DynamoDB write.
ユーザの投票
コメント(2)
- 正解だと思う選択肢: B
Option B is the best solution because it proposes enabling a DynamoDB stream on the table, which allows the developer to capture document-level changes in near-real time without modifying the application code. Then, the stream can be configured to invoke an AWS Lambda function to process the documents in near-real time. This solution requires minimal changes to the existing application code, and the Lambda function can be developed and deployed separately, enabling the developer to easily maintain and update it as needed.
👍 5MrTee2023/04/22 - 正解だと思う選択肢: B
To implement near-real-time processing on documents added or updated in a DynamoDB table with the least amount of change to the existing application code, the developer should:
B. Enable a DynamoDB stream on the table and invoke an AWS Lambda function to process the documents.
Enabling a DynamoDB stream on the table allows capturing and processing of the changes made to the table in near-real-time. The stream provides an ordered sequence of item-level modifications (inserts, updates, and deletes) that can be consumed by other AWS services, such as AWS Lambda.
👍 1loctong2023/05/17
シャッフルモード