Skip to content
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

Double stabilisation for remote updates check, remove one ? #337

Open
aletomsic opened this issue Apr 10, 2018 · 1 comment
Open

Double stabilisation for remote updates check, remove one ? #337

aletomsic opened this issue Apr 10, 2018 · 1 comment

Comments

@aletomsic
Copy link
Contributor

When a remote updates arrives, the interDC protocol at the receiver checks that the update's dependencies have been applied. If the check passes, the update will be added to the materializer and the log.
Otherwise, it will be buffered until the check passes.
https://github.com/SyncFree/antidote/blob/master/src/inter_dc_dep_vnode.erl#L127-L146

My intuition is that this check is redundant, as the stabilisation protocol guarantees that a transaction only reads stable updates. Therefore, if we bypass this check and send the updates to the materialiser as they arrive, the materialiser might be in an inconsistent state, but the stabilisation algorithm will ensure this inconsistent state is not visible by transactions. I hope this is clear.

@deepthidevaki
Copy link
Member

The materializer assumes that the operations it receives are in causal order. That assumption will be violated if we remove this check by the inter-dc module. It makes sense for the materializer to have this assumption. Otherwise, it has to check for causal dependency and reorder the operations.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants