diff options
| author | nsfisis <nsfisis@gmail.com> | 2025-12-31 15:46:41 +0900 |
|---|---|---|
| committer | nsfisis <nsfisis@gmail.com> | 2025-12-31 15:46:41 +0900 |
| commit | 3810450c20326998aef17c0acfcd5893e7b3ca20 (patch) | |
| tree | adf5434c2afe3b24ddada7066c697070be0d5950 /docs | |
| parent | f3952a509b2d98a25cbb80c9ad091b3b471be52e (diff) | |
| download | kioku-3810450c20326998aef17c0acfcd5893e7b3ca20.tar.gz kioku-3810450c20326998aef17c0acfcd5893e7b3ca20.tar.zst kioku-3810450c20326998aef17c0acfcd5893e7b3ca20.zip | |
feat(crdt): replace LWW conflict resolution with Automerge merge
The ConflictResolver now defaults to CRDT strategy which uses Automerge
to merge local and server documents during sync conflicts. This provides
conflict-free resolution that preserves changes from both sides.
Key changes:
- Add CRDT merge methods for all entity types (deck, card, note, etc.)
- Update resolve methods to accept optional CRDT binary data
- Fall back to server_wins when CRDT data is unavailable or invalid
- Add comprehensive tests for CRDT conflict resolution scenarios
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Diffstat (limited to 'docs')
| -rw-r--r-- | docs/dev/roadmap.md | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/docs/dev/roadmap.md b/docs/dev/roadmap.md index 9251e15..d2a4d3b 100644 --- a/docs/dev/roadmap.md +++ b/docs/dev/roadmap.md @@ -25,7 +25,7 @@ Replace the current Last-Write-Wins (LWW) conflict resolution with Automerge CRD - [x] Modify `src/client/sync/push.ts` - Add crdtChanges to push payload - [x] Modify `src/client/sync/pull.ts` - Handle crdtChanges in pull response -- [ ] Modify `src/client/sync/conflict.ts` - Replace LWW with Automerge merge +- [x] Modify `src/client/sync/conflict.ts` - Replace LWW with Automerge merge - [ ] Modify `src/client/sync/manager.ts` - Integrate CRDT sync flow ### Phase 4: Server-Side CRDT Support |
