Class Row.Deletion
- Enclosing interface:
- Row
A row deletion mostly consists of the time of said deletion, but there is 2 variants: shadowable and regular row deletion.
A shadowable row deletion only exists if the row has no timestamp. In other words, the deletion is only valid as long as no newer insert is done (thus setting a row timestamp; note that if the row timestamp set is lower than the deletion, it is shadowed (and thus ignored) as usual).
That is, if a row has a shadowable deletion with timestamp A and an update is made to that row with a
timestamp B such that B > A (and that update sets the row timestamp), then the shadowable deletion is 'shadowed'
by that update. A concrete consequence is that if said update has cells with timestamp lower than A, then those
cells are preserved(since the deletion is removed), and this is contrary to a normal (regular) deletion where the
deletion is preserved and such cells are removed.
Currently, the only use of shadowable row deletions is Materialized Views, see CASSANDRA-10261.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintdataSize()booleandeletes(LivenessInfo info) booleanvoidbooleanfinal inthashCode()booleanisLive()Wether the deletion is live or not, that is if its an actual deletion or not.booleanWhether the deletion is a shadowable one or not.booleanisShadowedBy(LivenessInfo primaryKeyLivenessInfo) static Row.Deletionregular(DeletionTime time) static Row.Deletionshadowable(DeletionTime time) Deprecated.See CAASSANDRA-10261booleansupersedes(DeletionTime that) booleansupersedes(Row.Deletion that) time()The time of the row deletion.toString()long
-
Field Details
-
LIVE
-
-
Constructor Details
-
Deletion
-
-
Method Details
-
regular
-
shadowable
Deprecated.See CAASSANDRA-10261 -
time
The time of the row deletion.- Returns:
- the time of the row deletion.
-
isShadowable
public boolean isShadowable()Whether the deletion is a shadowable one or not.- Returns:
- whether the deletion is a shadowable one. Note that if
isLive(), then this is guarantee to returnfalse.
-
isLive
public boolean isLive()Wether the deletion is live or not, that is if its an actual deletion or not.- Returns:
trueif this represents no deletion of the row,falseif that's an actual deletion.
-
supersedes
-
supersedes
-
isShadowedBy
-
deletes
-
deletes
-
digest
-
dataSize
public int dataSize() -
equals
-
hashCode
public final int hashCode() -
toString
-