Class CompressedSegment
- java.lang.Object
-
- org.apache.cassandra.db.commitlog.CommitLogSegment
-
- org.apache.cassandra.db.commitlog.FileDirectSegment
-
- org.apache.cassandra.db.commitlog.CompressedSegment
-
public class CompressedSegment extends FileDirectSegment
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 byCommitLogDescriptor.writeHeader(ByteBuffer, CommitLogDescriptor)
) - a series of 'sync segments' that are written every time the commit log is sync()'ed -- a sync section header, seeCommitLogSegment.writeSyncMarker(long, ByteBuffer, int, int, int)
-- total plain text length for this section -- a block of compressed data
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static class
CompressedSegment.CompressedSegmentBuilder
-
Nested 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
All Methods Instance Methods Concrete Methods Modifier and Type Method Description long
onDiskSize()
-
Methods inherited from class org.apache.cassandra.db.commitlog.FileDirectSegment
flush, internalClose
-
Methods 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, setCDCState, toString, writeCDCIndexFile, writeSyncMarker
-
-
-
-
Method Detail
-
onDiskSize
public long onDiskSize()
- Specified by:
onDiskSize
in classCommitLogSegment
-
-