AWS Certified Developer – Associate / Question #1057 of 557

Question #1057

A company uses an Amazon DynamoDB table to manage customer orders. They need their order tracking dashboard to reflect real-time updates whenever an order is placed, modified, or completed. The solution must ensure the dashboard is automatically updated with the latest order status without manual intervention.

Which approach fulfills these requirements?

A

Create a DynamoDB Accelerator (DAX) cluster for the table. Set the view type to old image. Develop an AWS Lambda function that retrieves data from the cluster to update the dashboard. Subscribe the Lambda function to the cluster.

B

Create a DynamoDB Accelerator (DAX) cluster for the table. Set the view type to new image. Develop an AWS Lambda function that retrieves data from the cluster to update the dashboard. Subscribe the Lambda function to the cluster.

C

Enable a DynamoDB stream for the table. Set the view type to new image. Develop an AWS Lambda function that processes the stream data to update the dashboard. Subscribe the Lambda function to the stream.

D

Enable a DynamoDB stream for the table. Set the view type to old image. Develop an AWS Lambda function that processes the stream data to update the dashboard. Subscribe the Lambda function to the stream.

Explanation

Option C is correct because DynamoDB streams capture item-level changes (inserts, updates, deletes) in real-time. By enabling a stream with the 'new image' view, the Lambda function receives the updated item data after changes, ensuring the dashboard reflects the latest order status. Subscribing Lambda to the stream triggers automatic updates without manual intervention.

Options A and B incorrectly use DAX, which is a caching layer for read acceleration, not change capture. DAX does not provide real-time change notifications. Options D uses the 'old image' view, which provides the item state before the change, making it unsuitable for displaying the latest status.

Answer

The correct answer is: C