public class SkipListMemtable extends AbstractAllocatorMemtable
AbstractMemtable.AbstractFlushablePartitionSet<P extends Partition>, AbstractMemtable.ColumnsCollector, AbstractMemtable.StatsCollector
Memtable.Factory, Memtable.FlushablePartitionSet<P extends Partition>, Memtable.LastCommitLogPosition, Memtable.MemoryUsage, Memtable.Owner
Modifier and Type | Field and Description |
---|---|
static Memtable.Factory |
FACTORY |
protected static int |
ROW_OVERHEAD_HEAP_SIZE |
allocator, initialComparator, MEMORY_POOL, owner
columnsCollector, currentOperations, metadata, minLocalDeletionTime, minTimestamp, statsCollector
NO_MIN_TIMESTAMP
Modifier | Constructor and Description |
---|---|
protected |
SkipListMemtable(java.util.concurrent.atomic.AtomicReference<CommitLogPosition> commitLogLowerBound,
TableMetadataRef metadataRef,
Memtable.Owner owner) |
Modifier and Type | Method and Description |
---|---|
protected Memtable.Factory |
factory() |
Memtable.FlushablePartitionSet<?> |
getFlushSet(PartitionPosition from,
PartitionPosition to)
Get the collection of data between the given partition boundaries in a form suitable for flushing.
|
long |
getLiveDataSize()
Size of the data not accounting for any metadata / mapping overheads
|
boolean |
isClean()
True if the memtable contains no data
|
void |
makeUnflushable()
For testing only.
|
long |
partitionCount()
Number of partitions stored in the memtable
|
org.apache.cassandra.db.memtable.SkipListMemtable.MemtableUnfilteredPartitionIterator |
partitionIterator(ColumnFilter columnFilter,
DataRange dataRange,
SSTableReadsListener readsListener)
Returns a partition iterator for the given data range.
|
long |
put(PartitionUpdate update,
UpdateTransaction indexer,
OpOrder.Group opGroup)
Should only be called by ColumnFamilyStore.apply via Keyspace.apply, which supplies the appropriate
OpOrdering.
|
UnfilteredRowIterator |
rowIterator(DecoratedKey key) |
UnfilteredRowIterator |
rowIterator(DecoratedKey key,
Slices slices,
ColumnFilter selectedColumns,
boolean reversed,
SSTableReadsListener listener)
Returns a row iterator for the given partition, applying the specified row and column filters.
|
addMemoryUsageTo, createMemtableAllocatorPoolInternal, discard, flushLargestMemtable, getAllocator, localRangesUpdated, markExtraOffHeapUsed, markExtraOnHeapUsed, metadataUpdated, performSnapshot, shouldSwitch, switchOut, toString
accepts, getApproximateCommitLogLowerBound, getCommitLogLowerBound, getFinalCommitLogUpperBound, mayContainDataBefore
getMinLocalDeletionTime, getMinTimestamp, metadata, operationCount, updateMin, updateMin
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
compareTo, getMemoryUsage, newMemoryUsage
public static final Memtable.Factory FACTORY
protected static final int ROW_OVERHEAD_HEAP_SIZE
protected SkipListMemtable(java.util.concurrent.atomic.AtomicReference<CommitLogPosition> commitLogLowerBound, TableMetadataRef metadataRef, Memtable.Owner owner)
protected Memtable.Factory factory()
factory
in class AbstractAllocatorMemtable
public boolean isClean()
Memtable
public long put(PartitionUpdate update, UpdateTransaction indexer, OpOrder.Group opGroup)
update
- the partition update, may be a new partition or an update to an existing oneindexer
- receives information about the update's effectopGroup
- write operation group, used to permit the operation to complete if it is needed to complete a
flush to free space.update
. See CASSANDRA-7979.public long partitionCount()
Memtable
public org.apache.cassandra.db.memtable.SkipListMemtable.MemtableUnfilteredPartitionIterator partitionIterator(ColumnFilter columnFilter, DataRange dataRange, SSTableReadsListener readsListener)
UnfilteredSource
columnFilter
- filter to apply to all returned partitionsdataRange
- the partition and clustering range queriedreadsListener
- a listener used to handle internal read eventspublic UnfilteredRowIterator rowIterator(DecoratedKey key, Slices slices, ColumnFilter selectedColumns, boolean reversed, SSTableReadsListener listener)
UnfilteredSource
key
- the partition keyslices
- the row ranges to returnselectedColumns
- filter to apply to all returned partitionsreversed
- true if the content should be returned in reverse orderlistener
- a listener used to handle internal read eventspublic UnfilteredRowIterator rowIterator(DecoratedKey key)
public Memtable.FlushablePartitionSet<?> getFlushSet(PartitionPosition from, PartitionPosition to)
Memtable
public long getLiveDataSize()
Memtable
public void makeUnflushable()
Copyright © 2009- The Apache Software Foundation