You are working on an application that provides an online Car booking service using Amazon DynamoDB.
This is a read-heavy application that reads car & driver location details & provides the latest position to prospective car booking customers.
Which of the following can be used to have consistent data writes & avoid unpredictable spikes in DynamoDB requests during peak hours?
Click on the arrows to vote for the correct answer
A. B. C. D.Correct Answer - B.
DAX is intended for applications that require high-performance reads.
As a write-through cache, DAX allows you to issue writes directly so that your writes are immediately reflected in the item cache.
You do not need to manage cache invalidation logic because DAX handles it for you.
For more information, please check the below link-
https://docs.aws.amazon.com/amazondynamodb/latest/developerguide/dynamodb-dg.pdfOption A is incorrect.
Write Around Cache is generally useful when there is a considerable amount of data to be written to the database.
In this case, data is directly written to DynamoDB instead of DAX.
Option C is incorrect as Using Side Cache using Redis is eventually consistent and non-durable which may add additional delay.
Option D is incorrect.
As with Write Through cache using Redis, there are chances of missing data during new scaling out.
For more information on Caching with DAX, refer to the following URL-
https://aws.amazon.com/blogs/database/amazon-dynamodb-accelerator-dax-a-read-throughwrite-through-cache-for-dynamodb/To have consistent data writes and avoid unpredictable spikes in DynamoDB requests during peak hours for an online Car booking service application that reads car and driver location details, we need a caching solution that can handle high traffic and offer predictable performance.
A. Write Around Cache using DynamoDB DAX: DynamoDB Accelerator (DAX) is a caching service that can be used with DynamoDB to improve read performance. Write Around Cache is a cache strategy in which write operations are not cached. Therefore, using Write Around Cache with DynamoDB DAX might not be an effective solution for a read-heavy application that requires consistent data writes.
B. Write Through Cache using DynamoDB DAX: Write Through Cache is a cache strategy in which write operations are first written to the cache before writing them to the database. This strategy ensures that data is always consistent between the cache and the database. DynamoDB DAX supports Write Through Cache, which can be an effective solution for a read-heavy application that requires consistent data writes.
C. Use Side Cache using Redis along with DynamoDB: Redis is an in-memory data structure store that can be used as a caching solution. Side Cache is a cache strategy in which the cache sits alongside the database and receives copies of the data for reading operations. Redis can be used as a side cache with DynamoDB to provide consistent read performance. This strategy can be effective for a read-heavy application that requires consistent data writes.
D. Write Through Cache using Redis along with DynamoDB: Write Through Cache can be used with Redis along with DynamoDB to provide consistent data writes and read performance. In this strategy, write operations are first written to the cache and then to the database, ensuring consistency between the cache and the database. This can be an effective solution for a read-heavy application that requires consistent data writes.
Therefore, option D - Write Through Cache using Redis along with DynamoDB is the most effective solution for this scenario.