---
title: CRDTs and Eventual Consistency Anti-Patterns on AWS
description: Whole-item last-write-wins is how Global Tables lose cart merges. When to use counters, OR-Sets, and conflict-free merges vs when to keep a single Aurora writer.
url: https://www.joinhorizon.co/blog/crdts-eventual-consistency-anti-patterns-aws/
datePublished: 2026-06-12T00:00:00.000Z
dateModified: 2026-10-28T00:00:00.000Z
author: palaniappan-p
category: Cloud Architecture
tags: engineering-guide, distributed-systems, aws, dynamodb
---

# CRDTs and Eventual Consistency Anti-Patterns on AWS

> Whole-item last-write-wins is how Global Tables lose cart merges. When to use counters, OR-Sets, and conflict-free merges vs when to keep a single Aurora writer.

**June 2026**: Multi-Region active-active without a merge strategy is how **eventual consistency anti-patterns** ship: users see flickering state, not “high availability.”

## Symptom → mechanism → AWS control

| Production symptom                 | Mechanism                                    | AWS control                                                  |
| ---------------------------------- | -------------------------------------------- | ------------------------------------------------------------ |
| Lost edits under concurrent writes | Last-write-wins silently drops updates       | DynamoDB conditional writes, CRDT merge in application layer |
| Unbounded item growth              | CRDT tombstones accumulate                   | DynamoDB TTL on compaction checkpoints, periodic snapshot    |
| Divergent replicas after replay    | Eventual consistency without merge semantics | Kinesis event sourcing with deterministic merge function     |

**Opinionated take:** CRDTs solve collaborative state, not money, and pair best with DynamoDB or ElastiCache when you can tolerate seconds of convergence, not milliseconds of serializability.

> **Benchmark pattern (hypothetical workload):** collaborative doc editor on DynamoDB with per-field CRDT merges, 800 concurrent editors, 2.1M ops/day, merge conflicts drop from 14% (whole-item last-write-wins) to 0.3% (per-field CRDT) at cost of 38% larger item payloads.

## Anti-patterns

1. **RWM on same record across Regions** without merge → lost updates
2. **Cache-aside as source of truth** across Regions
3. **SQS at-least-once** without idempotent handlers (looks like consistency bug)

## CRDTs (when they help)

Conflict-free replicated data types (counters, OR-Sets, LWW-Element-Set with care) suit **collaboration** and **device sync**. On AWS, implement in app layer or use services with documented merge (DynamoDB counters are not full CRDTs).

**Opinionated take:** Prefer **single-writer Aurora Global** for financial aggregates; use CRDT-style merges only when product accepts semantic merge rules in writing.

## AWS services map

| Pattern             | Service                                    |
| ------------------- | ------------------------------------------ |
| Active-active items | DynamoDB Global Tables + version attribute |
| Session sync        | ElastiCache + sticky + short TTL           |
| Ordered workflow    | SQS FIFO + dedup                           |

## What to do this week

1. Document merge function for each Global Table entity.
2. Add integration test simulating concurrent cross-Region writes.
3. Metric: conflict resolution count per hour.

## More in This Track

Part of the **Engineering Guides** library (June 2026).

- Previous: [Part 1](https://www.joinhorizon.co/blog/cap-theorem-practice-aws-multi-region/)
- Next: [Part 3](https://www.joinhorizon.co/blog/distributed-coordination-redlock-consistent-hashing-elasticache/)
- Browse tracks: [Engineering Guides hub](https://www.joinhorizon.co/resources/engineering-guides/)

## What this guide doesn't cover

Distributed locks: next guide in the track.

## FAQ

### When should I not use a CRDT on DynamoDB Global Tables?
Do not CRDT money. Prefer a single-writer Aurora Global Database for financial aggregates. CRDTs fit collaboration and device sync when the product can write down merge rules and tolerate seconds of convergence, not serializable milliseconds.

### Is last-write-wins a CRDT?
No. LWW silently drops concurrent edits, which is the cart-merge failure this guide starts with. Use conditional writes plus an application merge (counters, OR-Sets, documented LWW-Register) or keep one writer.

### What could go wrong if cache-aside is the source of truth across Regions?
Replicas diverge and look like “eventual consistency bugs.” Cache-aside is not a merge strategy. Document a merge function per Global Table entity and test concurrent cross-Region writes in integration tests.

### Do DynamoDB counters count as a full CRDT?
No. Atomic counters are not OR-Sets or LWW-Element-Sets. Tombstones can grow items without bound; use TTL on compaction checkpoints and periodic snapshots if you implement CRDT-style merges in the app layer.

---

*Source: https://www.joinhorizon.co/blog/crdts-eventual-consistency-anti-patterns-aws/*
