DynamoDB Data Replication and Scaling | BDS-C00 Exam Answer

Managing DynamoDB Data Replication and Scaling

Question

A company is planning on using DynamoDB for storing all data related to tweets.

The data will go into millions of rows and needs to scale based on demand.

At the same time, they need to ensure that the data from the DynamoDB table with all the tweets gets continually replicated to a DynamoDB table in another region.

Which of the following can help effectively manage this requirement? Choose 2 answers from the options given below.

Answers

Explanations

Click on the arrows to vote for the correct answer

A. B. C. D.

Answer - A and B.

An example of this is given in the AWS Documentation.

Option A is correct: Amazon DynamoDB global tables provide a fully managed solution for deploying a multi-region, multi-master database, without having to build and maintain your own replication solution.

When you create a global table, you specify the AWS regions where you want the table to be available.

DynamoDB performs all of the necessary tasks to create identical tables in these regions, and propagate ongoing data changes to all of them.

For more information, click on:

https://docs.aws.amazon.com/amazondynamodb/latest/developerguide/GlobalTables.html

Option B is correct : Auto Scaling for DynamoDB will help automate capacity management for your tables and global secondary indexes.

You simply specify the desired target utilization and provide upper and lower bounds for read and write capacity.

https://aws.amazon.com/blogs/database/amazon-dynamodb-auto-scaling-performance-and-cost-optimization-at-any-scale/

Option D is incorrect since you need to use the KCL library to consume the tweets.

For more information on working with streams and KCL, please refer to the below URL.

https://aws.amazon.com/blogs/big-data/process-large-dynamodb-streams-using-multiple-amazon-kinesis-client-library-kcl-workers/
DynamoDB Stream

Worker

Worker2

Worker3

KCL.

Lease table

DynamoDB

The two options that can help effectively manage the requirement of replicating data from a DynamoDB table to another region are A) Use DynamoDB Global Tables and D) Use the KPL Library to store the data into the destination table.

  1. DynamoDB Global Tables: DynamoDB Global Tables can help replicate the data to another region by creating a multi-region, multi-master database table. The data is automatically replicated across all the regions where the table is enabled. This ensures that the data is always available in all regions, and if there is a failure in one region, the data is still available in other regions. It also provides low-latency, read and write access to the table from any region, and consistency guarantees across all regions.

  2. KPL Library: The KPL (Kinesis Producer Library) can help store the data into the destination table by providing a simple, efficient way to produce data into Amazon Kinesis. Kinesis can then be used to stream the data to another DynamoDB table in another region. The KPL allows for batching, compressing, and encrypting the data before sending it to Kinesis, making it highly efficient and secure. Additionally, the Kinesis Data Streams automatically replicates data across multiple availability zones within a region, providing high availability and durability.

  3. DynamoDB Autoscaling: While DynamoDB Autoscaling can help automatically adjust read and write capacity based on demand, it does not directly address the requirement of replicating data to another region.

  4. KCL Library: The KCL (Kinesis Client Library) is used to process data from Kinesis streams and does not directly address the requirement of replicating data to another region.