A ticketing application named 'PassGate' registers entry scans for high-attendance live events in a DynamoDB table. The table is configured with provisioned write capacity units (WCUs). During the check-in period for a major music concert, the application frequently encounters ProvisionedThroughputExceededException errors. CloudWatch metrics indicate that the table's overall consumed WCUs are well below the provisioned threshold, but a single partition key matching the popular EventID is receiving almost all the write traffic. Which action should the developer take to resolve this throttling issue?
- AIncrease the visibility timeout of the SQS queue that feeds ticket scans to the application, allowing more time for message processing.
- Modify the table schema to append a random or calculated suffix to the EventID partition key, distributing the write load across multiple partitions.Cevap
- CTransition the application's read operations to perform a full Scan with filter expressions instead of using Query operations.
- DEmbed static access keys in the application's SDK client configuration to ensure client credentials do not expire during peak throughput.
Cevap
Modify the table schema to append a random or calculated suffix to the EventID partition key, distributing the write load across multiple partitions.
The correct answer is correct because salting the partition key (appending a random or calculated suffix) distributes the writes across multiple logical partitions, preventing a hot key issue on a single partition.
Adım Adım Çözüm
Anahtar Kavram
DynamoDB Partition Key Salting and Hot Partitions
Tahmini Süre:1m 30s