available social comments and store in the DynamoDB table. There are millions of rows for storing this data and needs to be scaled as demand increases. You have to make sure that all the data stored in DynamoDB table
is uniformly distributed. Which of the following strategy you can use to achieve this?
A. You will be creating Unique Index on the DynamoDB table.
B. You will be creating Primary key on the DynamoDB table.
C. You will be creating DIST_KEY on the DynamoDB table.
D. You will be Sharding Using Random Suffixes
E. You will be Sharding Using Calculated Suffixes
1. A,B
2. B,C
3. C,D
4. D,E
5. A,E
Correct Answer : 4 Exp : Using Write Sharding to Distribute Workloads Evenly
One way to better distribute writes across a partition key space in DynamoDB is to expand the space. You can do this in several different ways. You can add a random number to the partition key values to distribute the
items among partitions, or you can use a number that is calculated based on something that you are querying on.
Sharding Using Random Suffixes
One strategy for distributing loads more evenly across a partition key space is to add a random number to the end of the partition key values. Then you randomize the writes across the larger space.
Sharding Using Calculated Suffixes
A randomizing strategy can greatly improve write throughput. But its difficult to read a specific item because you dont know which suffix value was used when writing the item. To make it easier to read individual
items, you can use a different strategy. Instead of using a random number to distribute the items among partitions, use a number that you can calculate based upon something that you want to query on.
4