Skip to content

feat: add GSet and LWWESet#1

Merged
aalpar merged 1 commit intomasterfrom
feat/gset-lwweset
Mar 14, 2026
Merged

feat: add GSet and LWWESet#1
aalpar merged 1 commit intomasterfrom
feat/gset-lwweset

Conversation

@aalpar
Copy link
Copy Markdown
Owner

@aalpar aalpar commented Mar 14, 2026

Summary

  • GSet (gset/): grow-only set with no causal context. Merge is plain set union. Zero dotcontext imports.
  • LWWESet (lwweset/): per-element LWW set where each element independently carries add/remove timestamps. Conflicts resolve by max timestamp; add-wins on equal timestamps.

Both are dotcontext-free, joining GCounter as CRDTs that demonstrate the causal algebra is optional machinery, not a mandatory tax.

Test plan

  • TestBasicOps, TestDeltaReturn, TestMerge per package
  • TestSharedProperties via crdttest.Harness (semilattice, delta propagation, convergence)
  • make lint && make && make test — all packages green

GSet is a grow-only set with no causal context — merge is set union,
no dots or CausalContext needed. LWWESet is a per-element LWW set
where each element independently carries add/remove timestamps;
conflicts resolve by max timestamp, add-wins on ties.

Both are dotcontext-free, joining GCounter as CRDTs that demonstrate
the causal algebra is optional, not mandatory.
@aalpar aalpar merged commit 226018c into master Mar 14, 2026
1 check failed
@aalpar aalpar deleted the feat/gset-lwweset branch March 14, 2026 04:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant