---
title: "Conflict-free merges in 90 seconds"
url: "https://nsta1.github.io/Orleans.Lattice/docs/videos/conflict-free-merges.html"
source: "https://github.com/NSTA1/Orleans.Lattice/blob/release/10.5/docs/videos/conflict-free-merges.md"
agent_spec: "https://nsta1.github.io/Orleans.Lattice/docs/agents/concepts.yaml"
documents: "Orleans.Lattice 10.5.0 (release line 10.5)"
built: "2026-12-05"
all-pages: "https://nsta1.github.io/Orleans.Lattice/llms.txt"
---
# Conflict-free merges in 90 seconds

Part of [Videos](index.md).

A G-Set merges concurrent additions by taking their union, so both clusters converge on the same set.

Video: [Conflict-free merges in 90 seconds, video, 1:18](../../media/conflict-free-merges-1238894bf1b5.mp4). Captions: [English](../../media/conflict-free-merges-1238894bf1b5.vtt).

1:18, English captions, [Download the MP4](../../media/conflict-free-merges-1238894bf1b5.mp4) (3.4 MB)

## Transcript

### Opening

Values that merge showed how a chosen data type can resolve concurrent writes; now watch one merge in a set.

### G-Set merge

A plain write uses last-writer-wins: if two clusters write the same key, the later timestamp keeps its value and silently replaces the other.

A G-Set has a different rule. It only grows: you can add an element, but cannot remove one. Start with an empty set. Cluster A adds alice while cluster B, without seeing that change, adds bob.

Their sets are {alice} and {bob}; neither contains the other. When they merge, each takes the union, keeping every element from both sets.

Now deliver bob's add again. Both clusters hold {alice, bob}; the union gives the same result regardless of delivery order, and repeating an add does not duplicate an element.

Set union is commutative, associative and idempotent: swapping, regrouping or repeating a merge leaves the result unchanged. That is why both sides converge without choosing a winner.

Use a G-Set for append-only membership, such as seen identifiers or tags. If your data needs removals, choose an OR-Set or RW-Set instead; those define removal semantics.

Back on Build, next: Scans, filters and cursors. The links are on this episode's page in the documentation.

## Where next

- **Back to Build:** [Scans, filters and cursors](scans-filters-and-cursors.md)
- **The pages it introduces:** [CRDT primitives](../crdt/readme.md) and [state primitives](../lattice/state-primitives.md)
