A software company operates a multi-tenant SaaS application that stores client organization profiles in an Amazon DynamoDB table. To minimize read latency for authorization checks, the developer deployed an Amazon DynamoDB Accelerator (DAX) cluster. However, an administrative microservice updates these organization profiles by writing directly to the DynamoDB table. Consequently, users report that profile updates take up to five minutes to reflect in the main application. Which of the following developer actions will resolve this cache staleness issue most efficiently?
- Configure the administrative microservice to perform write operations through the DAX cluster client rather than directly to the DynamoDB table.Cevap
- BModify the main application to perform a full Scan operation on the DAX cluster every five minutes to refresh the cache for all client organization profiles.
- CIncrease the provisioned read capacity units (RCUs) and write capacity units (WCUs) of the underlying DynamoDB table to handle the direct updates without partition throttling.
- DConfigure the Lambda functions in the main application to initialize a new DAX client connection on every request rather than reusing the client across execution contexts.
Cevap
Configure the administrative microservice to perform write operations through the DAX cluster client rather than directly to the DynamoDB table.
Directing writes through the DAX cluster client ensures that DAX performs a write-through operation. This updates the DAX cache (item cache) synchronously while writing to the DynamoDB table, so subsequent reads immediately see the updated configuration.
Adım Adım Çözüm
Anahtar Kavram
DAX Cache Consistency and Write-Through Strategy