sealed abstract class VersionVector extends ReplicatedData with ReplicatedDataSerialization with RemovedNodePruning
Representation of a Vector-based clock (counting clock), inspired by Lamport logical clocks.
Reference: 1) Leslie Lamport (1978). "Time, clocks, and the ordering of events in a distributed system". Communications of the ACM 21 (7): 558-565. 2) Friedemann Mattern (1988). "Virtual Time and Global States of Distributed Systems". Workshop on Parallel and Distributed Algorithms: pp. 215-226
Based on code from akka.cluster.VectorClock
.
This class is immutable, i.e. "modifying" methods return a new instance.
- Annotations
- @SerialVersionUID()
- Source
- VersionVector.scala
- Alphabetic
- By Inheritance
- VersionVector
- RemovedNodePruning
- ReplicatedDataSerialization
- Serializable
- Serializable
- ReplicatedData
- AnyRef
- Any
- by any2stringadd
- by StringFormat
- by Ensuring
- by ArrowAssoc
- Hide All
- Show All
- Public
- All
Type Members
-
type
T = VersionVector
The type of the concrete implementation, e.g.
The type of the concrete implementation, e.g.
GSet[A]
. To be specified by subclass.- Definition Classes
- VersionVector → ReplicatedData
Abstract Value Members
- abstract def isEmpty: Boolean
-
abstract
def
merge(that: VersionVector): VersionVector
Merges this VersionVector with another VersionVector.
Merges this VersionVector with another VersionVector. E.g. merges its versioned history.
- Definition Classes
- VersionVector → ReplicatedData
-
abstract
def
modifiedByNodes: Set[UniqueAddress]
The nodes that have changed the state for this data and would need pruning when such node is no longer part of the cluster.
The nodes that have changed the state for this data and would need pruning when such node is no longer part of the cluster.
- Definition Classes
- RemovedNodePruning
-
abstract
def
needPruningFrom(removedNode: UniqueAddress): Boolean
Does it have any state changes from a specific node, which has been removed from the cluster.
Does it have any state changes from a specific node, which has been removed from the cluster.
- Definition Classes
- VersionVector → RemovedNodePruning
-
abstract
def
prune(removedNode: UniqueAddress, collapseInto: UniqueAddress): VersionVector
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.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.- Definition Classes
- VersionVector → RemovedNodePruning
-
abstract
def
pruningCleanup(removedNode: UniqueAddress): VersionVector
Remove data entries from a node that has been removed from the cluster and already been pruned.
Remove data entries from a node that has been removed from the cluster and already been pruned.
- Definition Classes
- VersionVector → RemovedNodePruning
Concrete Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
def
->[B](y: B): (VersionVector, B)
- Implicit
- This member is added by an implicit conversion from VersionVector to ArrowAssoc[VersionVector] performed by method ArrowAssoc in scala.Predef.
- Definition Classes
- ArrowAssoc
- Annotations
- @inline()
-
def
:+(node: SelfUniqueAddress): VersionVector
Increment the version for the node passed as argument.
Increment the version for the node passed as argument. Returns a new VersionVector.
-
def
<(that: VersionVector): Boolean
Returns true if
this
is beforethat
else false. -
def
<>(that: VersionVector): Boolean
Returns true if
this
andthat
are concurrent else false. -
def
==(that: VersionVector): Boolean
Returns true if this VersionVector has the same history as the 'that' VersionVector else false.
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
>(that: VersionVector): Boolean
Returns true if
this
is afterthat
else false. -
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate() @throws( ... )
-
def
compareTo(that: VersionVector): Ordering
Compare two version vectors.
Compare two version vectors. The outcome will be one of the following:
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.
-
def
ensuring(cond: (VersionVector) ⇒ Boolean, msg: ⇒ Any): VersionVector
- Implicit
- This member is added by an implicit conversion from VersionVector to Ensuring[VersionVector] performed by method Ensuring in scala.Predef.
- Definition Classes
- Ensuring
-
def
ensuring(cond: (VersionVector) ⇒ Boolean): VersionVector
- Implicit
- This member is added by an implicit conversion from VersionVector to Ensuring[VersionVector] performed by method Ensuring in scala.Predef.
- Definition Classes
- Ensuring
-
def
ensuring(cond: Boolean, msg: ⇒ Any): VersionVector
- Implicit
- This member is added by an implicit conversion from VersionVector to Ensuring[VersionVector] performed by method Ensuring in scala.Predef.
- Definition Classes
- Ensuring
-
def
ensuring(cond: Boolean): VersionVector
- Implicit
- This member is added by an implicit conversion from VersionVector to Ensuring[VersionVector] performed by method Ensuring in scala.Predef.
- Definition Classes
- Ensuring
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
formatted(fmtstr: String): String
- Implicit
- This member is added by an implicit conversion from VersionVector to StringFormat[VersionVector] performed by method StringFormat in scala.Predef.
- Definition Classes
- StringFormat
- Annotations
- @inline()
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @HotSpotIntrinsicCandidate()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @HotSpotIntrinsicCandidate()
-
def
increment(node: SelfUniqueAddress): VersionVector
Increment the version for the node passed as argument.
Increment the version for the node passed as argument. Returns a new VersionVector.
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
def
→[B](y: B): (VersionVector, B)
- Implicit
- This member is added by an implicit conversion from VersionVector to ArrowAssoc[VersionVector] performed by method ArrowAssoc in scala.Predef.
- Definition Classes
- ArrowAssoc
Shadowed Implicit Value Members
-
def
+(other: String): String
- Implicit
- This member is added by an implicit conversion from VersionVector to any2stringadd[VersionVector] performed by method any2stringadd in scala.Predef.
- Shadowing
- This implicitly inherited member is shadowed by one or more members in this class.
To access this member you can use a type ascription:(versionVector: any2stringadd[VersionVector]).+(other)
- Definition Classes
- any2stringadd
Deprecated Value Members
-
def
+(node: Cluster): VersionVector
- Annotations
- @deprecated
- Deprecated
(Since version 2.5.20) Use
:+
that takes aSelfUniqueAddress
parameter instead.
-
def
finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @Deprecated @deprecated @throws( classOf[java.lang.Throwable] )
- Deprecated
(Since version ) see corresponding Javadoc for more information.
-
def
increment(node: Cluster): VersionVector
- Annotations
- @deprecated
- Deprecated
(Since version 2.5.20) Use
increment
that takes aSelfUniqueAddress
parameter instead.