public class CachedBTreePartition extends ImmutableBTreePartition implements CachedPartition
AbstractBTreePartition.Holder, AbstractBTreePartition.SliceableIterator, AbstractBTreePartition.SlicesIteratorholderEMPTY, metadata, partitionKeycacheSerializer| Modifier and Type | Method and Description |
|---|---|
int |
cachedLiveRows()
The number of rows that were live at the time the partition was cached.
|
static CachedBTreePartition |
create(UnfilteredRowIterator iterator,
int nowInSec)
Creates an
ArrayBackedCachedPartition holding all the data of the provided iterator. |
static CachedBTreePartition |
create(UnfilteredRowIterator iterator,
int initialRowCapacity,
int nowInSec)
Creates an
ArrayBackedCachedPartition holding all the data of the provided iterator. |
int |
nonExpiringLiveCells()
The number of cells in this cached partition that are neither tombstone nor expiring.
|
int |
nonTombstoneCellCount()
The number of
cell objects that are not tombstone in this cached partition. |
int |
rowsWithNonExpiringCells()
The number of rows in this cached partition that have at least one non-expiring
non-deleted cell.
|
canHaveShadowedData, create, holderbuild, build, columns, deletionInfo, getRow, hasRows, isEmpty, iterator, lastRow, metadata, partitionKey, partitionLevelDeletion, rowCount, searchIterator, sliceableUnfilteredIterator, sliceableUnfilteredIterator, staticRow, stats, toString, unfilteredIterator, unfilteredIterator, unfilteredIteratorclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitlastRow, rowCountcolumns, getRow, isEmpty, metadata, partitionKey, partitionLevelDeletion, searchIterator, stats, unfilteredIterator, unfilteredIteratorpublic static CachedBTreePartition create(UnfilteredRowIterator iterator, int nowInSec)
ArrayBackedCachedPartition holding all the data of the provided iterator.
Warning: Note that this method does not close the provided iterator and it is
up to the caller to do so.iterator - the iterator got gather in memory.nowInSec - the time of the creation in seconds. This is the time at which cachedLiveRows applies.public static CachedBTreePartition create(UnfilteredRowIterator iterator, int initialRowCapacity, int nowInSec)
ArrayBackedCachedPartition holding all the data of the provided iterator.
Warning: Note that this method does not close the provided iterator and it is
up to the caller to do so.iterator - the iterator got gather in memory.initialRowCapacity - sizing hint (in rows) to use for the created partition. It should ideally
correspond or be a good estimation of the number or rows in iterator.nowInSec - the time of the creation in seconds. This is the time at which cachedLiveRows applies.public int cachedLiveRows()
ColumnFamilyStore.isFilterFullyCoveredBy(org.apache.cassandra.db.filter.ClusteringIndexFilter, org.apache.cassandra.db.filter.DataLimits, org.apache.cassandra.db.partitions.CachedPartition, int) to see why we need this.cachedLiveRows in interface CachedPartitionpublic int rowsWithNonExpiringCells()
DataLimits.hasEnoughLiveData(org.apache.cassandra.db.partitions.CachedPartition, int) as an optimization.rowsWithNonExpiringCells in interface CachedPartitionpublic int nonTombstoneCellCount()
CachedPartitioncell objects that are not tombstone in this cached partition.
Please note that this is not the number of live cells since
some of the cells might be expired.nonTombstoneCellCount in interface CachedPartitionpublic int nonExpiringLiveCells()
CachedPartitionDataLimits#hasEnoughLiveData as an optimization.nonExpiringLiveCells in interface CachedPartitionCopyright © 2016 The Apache Software Foundation