public final class VersionVector extends java.lang.Object implements ReplicatedData, ReplicatedDataSerialization, RemovedNodePruning, scala.Product, scala.Serializable
Modifier and Type | Class and Description |
---|---|
static class |
VersionVector.After$ |
static class |
VersionVector.Before$ |
static class |
VersionVector.Concurrent$ |
static interface |
VersionVector.Ordering |
static class |
VersionVector.Same$ |
Constructor and Description |
---|
VersionVector(scala.collection.immutable.TreeMap<akka.cluster.UniqueAddress,java.lang.Object> versions) |
Modifier and Type | Method and Description |
---|---|
static VersionVector.After$ |
AfterInstance()
Java API: The
VersionVector.After instance |
static VersionVector |
apply() |
static VersionVector.Before$ |
BeforeInstance()
Java API: The
VersionVector.Before instance |
VersionVector.Ordering |
compareTo(VersionVector that)
Compare two version vectors.
|
static VersionVector.Concurrent$ |
ConcurrentInstance()
Java API: The
VersionVector.Concurrent instance |
static VersionVector |
create()
Java API
|
static VersionVector |
empty() |
VersionVector |
increment(akka.cluster.Cluster node)
Increment the version for the node passed as argument.
|
VersionVector |
increment(akka.cluster.UniqueAddress node)
INTERNAL API
Increment the version for the node passed as argument.
|
VersionVector |
merge(VersionVector that)
Merges this VersionVector with another VersionVector.
|
boolean |
needPruningFrom(akka.cluster.UniqueAddress removedNode)
Does it have any state changes from a specific node,
which has been removed from the cluster.
|
VersionVector |
prune(akka.cluster.UniqueAddress removedNode,
akka.cluster.UniqueAddress collapseInto)
When the
removed node has been removed from the cluster the state
changes from that node will be pruned by collapsing the data entries
to another node. |
VersionVector |
pruningCleanup(akka.cluster.UniqueAddress removedNode)
Remove data entries from a node that has been removed from the cluster
and already been pruned.
|
static VersionVector.Same$ |
SameInstance()
Java API: The
VersionVector.Same instance |
java.lang.String |
toString() |
scala.collection.immutable.TreeMap<akka.cluster.UniqueAddress,java.lang.Object> |
versions() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
merge
public VersionVector(scala.collection.immutable.TreeMap<akka.cluster.UniqueAddress,java.lang.Object> versions)
public static VersionVector empty()
public static VersionVector apply()
public static VersionVector create()
public static VersionVector.After$ AfterInstance()
VersionVector.After
instancepublic static VersionVector.Before$ BeforeInstance()
VersionVector.Before
instancepublic static VersionVector.Same$ SameInstance()
VersionVector.Same
instancepublic static VersionVector.Concurrent$ ConcurrentInstance()
VersionVector.Concurrent
instancepublic scala.collection.immutable.TreeMap<akka.cluster.UniqueAddress,java.lang.Object> versions()
public VersionVector increment(akka.cluster.Cluster node)
node
- (undocumented)public VersionVector increment(akka.cluster.UniqueAddress node)
node
- (undocumented)public VersionVector.Ordering compareTo(VersionVector that)
1. Version 1 is SAME (==) as Version 2 iff for all i c1(i) == c2(i)
2. Version 1 is BEFORE (<) Version 2 iff for all i c1(i) <= c2(i) and there exist a j such that c1(j) < c2(j)
3. Version 1 is AFTER (>) Version 2 iff for all i c1(i) >= c2(i) and there exist a j such that c1(j) > c2(j).
4. Version 1 is CONCURRENT (<>) to Version 2 otherwise.
that
- (undocumented)public VersionVector merge(VersionVector that)
that
- (undocumented)public boolean needPruningFrom(akka.cluster.UniqueAddress removedNode)
RemovedNodePruning
needPruningFrom
in interface RemovedNodePruning
removedNode
- (undocumented)public VersionVector prune(akka.cluster.UniqueAddress removedNode, akka.cluster.UniqueAddress collapseInto)
RemovedNodePruning
removed
node has been removed from the cluster the state
changes from that node will be pruned by collapsing the data entries
to another node.prune
in interface RemovedNodePruning
removedNode
- (undocumented)collapseInto
- (undocumented)public VersionVector pruningCleanup(akka.cluster.UniqueAddress removedNode)
RemovedNodePruning
pruningCleanup
in interface RemovedNodePruning
removedNode
- (undocumented)public java.lang.String toString()
toString
in class java.lang.Object