-
-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Compacting History #628
Comments
Hi! It depends on what you are storing, if you are referring the document itself—i.e. the Now, if you are storing all |
Thanks for the summary :) |
You just store the patches then. They have the built-in import {Patch} from 'json-joy/lib/json-crdt';
const binary = patch.toBinary();
const patch2 = Patch.fromBinary(binary);
You only need to store the patches on the node which is expected to get up to speed other nodes. For example, if you have a centra server, you would store all the patches only on that central server. If you have a peer-to-peer app, you would store all the known patches on each peer. |
Hi -
Do I need to be mindful of history length when using this library? For example a document with a lot of deletes?
Does it act like an immutable datastructure?
Do I need to create my own 'flattening' algorithm?
For example I could take the history
n
-steps ago, and create a new CRDT based on the absolute value at that point + then
undo steps, in order to create a moving window.Or am I misunderstanding how they work?
The text was updated successfully, but these errors were encountered: