Soru

Zorluk: OrtaResolving DynamoDB Throttling and Key Distribution Issues

A telemetry ingestion application named ThermoSense logs sensor status updates to an Amazon DynamoDB table. The table is configured with provisioned write capacity and uses SensorModel as the partition key. During a firmware update deployment, the application encounters multiple ProvisionedThroughputExceededException errors. CloudWatch metrics indicate that a specific, widely deployed sensor model is generating a high volume of writes, resulting in a hot partition. Which TWO actions should the developer take to resolve the write throttling and ensure even load distribution across partitions? (Select TWO.)

  1. Modify the application logic to append a random numeric suffix to the partition key value before writing the items.Cevap
  2. Configure the AWS SDK client to use exponential backoff and jitter for request retries.Cevap
  3. C
    Modify the queries to use Scan operations instead of Query operations to distribute the read requests across the table.
  4. D
    Increase the visibility timeout of the Amazon SQS queue that receives the telemetry messages to 12 hours.
  5. E
    Hardcode the AWS IAM access keys directly into the application's SDK client configuration to reduce credential resolution overhead.

Cevap

To resolve the throttling and key distribution issues, the developer should modify the application logic to append a random numeric suffix to the partition key value and configure the AWS SDK client to use exponential backoff and jitter for request retries.
The correct strategy combines database-level partition sharding and application-level retry patterns. Appending a random numeric suffix to the partition key distributes the write load across multiple database partitions, effectively dispersing the hot key bottleneck. Configuring the AWS SDK client to use exponential backoff and jitter ensures that the client application handles transient ProvisionedThroughputExceededException errors gracefully without overwhelming the database with immediate retries.

Adım Adım Çözüm

1
Analyze the cause of the throttling.
The CloudWatch metrics reveal that the ProvisionedThroughputExceededException is caused by a hot partition key because a single SensorModel partition is receiving an unevenly high volume of writes.
Before applying a fix, the developer must determine whether the throughput exhaustion is due to overall table limits or an uneven partition key distribution.
2
Implement partition key sharding (suffixing).
By appending a random numeric suffix to the hot partition key value, writes are distributed across multiple distinct partitions.
This resolves the hot key issue by spreading the write load more evenly across DynamoDB's physical partition structure.
3
Configure client-side error handling.
The AWS SDK is configured to handle transient throttling errors by retrying failed writes using exponential backoff and randomized jitter.
This prevents retry storms and ensures that the client application gracefully recovers when throughput limits are temporarily reached.

Anahtar Kavram

Resolving DynamoDB hot partition key bottlenecks using write sharding (random suffixing) combined with client-side retry logic (exponential backoff and jitter).
Tahmini Süre:2m 0s
Bu soruyu puanla