Class CompressedSegment
java.lang.Object
org.apache.cassandra.db.commitlog.CommitLogSegment
org.apache.cassandra.db.commitlog.FileDirectSegment
org.apache.cassandra.db.commitlog.CompressedSegment
Compressed commit log segment. Provides an in-memory buffer for the mutation threads. On sync compresses the written
section of the buffer and writes it to the destination channel.
The format of the compressed commit log is as follows:
- standard commit log header (as written by
CommitLogDescriptor.writeHeader(ByteBuffer, CommitLogDescriptor))
- a series of 'sync segments' that are written every time the commit log is sync()'ed
-- a sync section header, see CommitLogSegment.writeSyncMarker(long, ByteBuffer, int, int, int)
-- total plain text length for this section
-- a block of compressed data-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static classNested classes/interfaces inherited from class org.apache.cassandra.db.commitlog.CommitLogSegment
CommitLogSegment.Allocation, CommitLogSegment.Builder, CommitLogSegment.CDCState, CommitLogSegment.CommitLogSegmentFileComparator -
Field Summary
Fields inherited from class org.apache.cassandra.db.commitlog.CommitLogSegment
descriptor, ENTRY_OVERHEAD_SIZE, id, manager -
Method Summary
Methods inherited from class org.apache.cassandra.db.commitlog.FileDirectSegment
flush, internalCloseMethods inherited from class org.apache.cassandra.db.commitlog.CommitLogSegment
additionalHeaderParameters, contains, contentSize, coverInMap, createBuffer, dirtyString, getCDCFile, getCDCIndexFile, getCDCState, getCurrentCommitLogPosition, getDirtyTableIds, getName, getPath, isStillAllocating, isUnused, markClean, resetReplayLimit, setCDCState, toString, writeCDCIndexFile, writeSyncMarker
-
Method Details
-
onDiskSize
public long onDiskSize()- Specified by:
onDiskSizein classCommitLogSegment
-