You are migrating a legacy monolith that performs frequent read-after-write on a relational store. The new design uses DynamoDB with a TTL attribute for some items and GSIs for query patterns. To ensure correctness for immediate reads after writes, which approach is most appropriate?

Answer

Use strongly consistent reads for the base table partition key when you need read-after-write guarantees; for GSI queries, design for eventual consistency or re-query base table

Explanation

DynamoDB provides strong consistency only for base table reads by partition key; GSIs are eventually consistent. If strict correctness is needed immediately, query the base table with strong reads.

Last reviewed: October 2026

Reviewed by FirstInTest Editorial Team

Report an error

Related questions

A multi-account organization uses SCPs to prevent direct attachment of AdministratorAccess. A workload needs cross-account access to an encrypted S3 bucket using KMS keys. Which combination best satisfies least privilege while still enabling decryption?

View question →

Your team must implement fine-grained access control for a multi-tenant SaaS. Tenants are isolated by data prefix in a shared S3 bucket and by a DynamoDB partition key. You must prevent a tenant from querying other tenants using the AWS console or API. Which approach is strongest?

View question →

A system behind an ALB must support HTTP/2, and responses must be compressed selectively based on content type and size. Additionally, you need consistent client IP visibility and strict WAF protection with rate limiting. Which design best matches these requirements?

View question →

A company must ensure that images uploaded to S3 are virus-scanned before becoming publicly accessible. Uploads can occur at high volume. Which pattern best enforces this with minimal manual operations?

View question →

You need a streaming data pipeline that ingests from Kinesis Data Streams, transforms records with event-time semantics, and writes to S3 in an optimized layout for Athena. There is a requirement to reprocess data deterministically for a specific time window if an error occurs. Which approach best achieves deterministic replay?

View question →

You must design a disaster recovery plan for an active-active architecture across two Regions using Route 53. Constraints: RPO ≤ 15 minutes, RTO ≤ 30 minutes, and workloads are stateful (relational DB). Which architecture is the most aligned while minimizing cutover risk?

View question →

QuestionBack to list