Initially empty MVRegister.
Assigns a Versioned value from v
and vectorTimestamp
and returns an updated MV-Register.
Assigns a Versioned value from v
and vectorTimestamp
and returns an updated MV-Register.
value to assign.
vector timestamp of the value to assign.
system timestamp of the value to assign.
id of the value emitter.
Initially empty MVRegister.
Operation-based LWW-Register CRDT with an MVRegister-based implementation. Instead of returning multiple values in case of concurrent assignments, the last written value is returned. The last written value is determined by comparing the following Versioned fields in given order:
vectorTimestamp
: if causally related, return the value with the higher timestamp, otherwise comparesystemTimestamp
: if not equal, return the value with the higher timestamp, otherwise compareemitterId
Note that this relies on synchronized system clocks. LWWRegister should only be used when the choice of value is not important for concurrent updates occurring within the clock skew.
Initially empty MVRegister.
A comprehensive study of Convergent and Commutative Replicated Data Types, specification 9