Cloudfront cache mutation:

0

Can anyone tell me the best practice of caching in cloudfront? Why mutation in the dynamodb table isn't reflecting? I have set the cache behaviour to max TTL:3sec, min TTL:0sec. When I'm refreshing the cloudfront url after 3 sec it is showing the mutation. But in the second refresh after 3 sec it is showing the older result.

1 Risposta
0
Risposta accettata

Are you doing strongly-consistent reads rather than eventually-consistent reads in DynamoDB? If not, then after a mutation a sequence of reads may return a mix of old and new values until full consistency is achieved.

ESPERTO
con risposta 2 anni fa
  • I want something like when any mutation occurs it should pass through cloudfront to dynamoDB. When a mutation will occur cloudfront will match the ID of objects in cache, if id matches it will be updated in CloudFront and then in DynamoDB.

Accesso non effettuato. Accedi per postare una risposta.

Una buona risposta soddisfa chiaramente la domanda, fornisce un feedback costruttivo e incoraggia la crescita professionale del richiedente.

Linee guida per rispondere alle domande