Package org.rocksdb
Class CompactionOptionsFIFO
java.lang.Object
org.rocksdb.AbstractNativeReference
org.rocksdb.AbstractImmutableNativeReference
org.rocksdb.RocksObject
org.rocksdb.CompactionOptionsFIFO
- All Implemented Interfaces:
AutoCloseable
Options for FIFO Compaction
-
Field Summary
Fields inherited from class org.rocksdb.RocksObject
nativeHandle_Fields inherited from class org.rocksdb.AbstractImmutableNativeReference
owningHandle_ -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanCheck if intra-L0 compaction is enabled.protected final voiddisposeInternal(long handle) longOnce the total sum of table files reaches this, we will delete the oldest table filesetAllowCompaction(boolean allowCompaction) If true, try to do compaction to compact smaller files into larger ones.setMaxTableFilesSize(long maxTableFilesSize) Once the total sum of table files reaches this, we will delete the oldest table fileMethods inherited from class org.rocksdb.RocksObject
disposeInternal, getNativeHandleMethods inherited from class org.rocksdb.AbstractImmutableNativeReference
close, disOwnNativeHandle, isOwningHandle
-
Constructor Details
-
CompactionOptionsFIFO
public CompactionOptionsFIFO()
-
-
Method Details
-
setMaxTableFilesSize
Once the total sum of table files reaches this, we will delete the oldest table fileDefault: 1GB
- Parameters:
maxTableFilesSize- The maximum size of the table files- Returns:
- the reference to the current options.
-
maxTableFilesSize
public long maxTableFilesSize()Once the total sum of table files reaches this, we will delete the oldest table fileDefault: 1GB
- Returns:
- max table file size in bytes
-
setAllowCompaction
If true, try to do compaction to compact smaller files into larger ones. Minimum files to compact follows options.level0_file_num_compaction_trigger and compaction won't trigger if average compact bytes per del file is larger than options.write_buffer_size. This is to protect large files from being compacted again.Default: false
- Parameters:
allowCompaction- true to allow intra-L0 compaction- Returns:
- the reference to the current options.
-
allowCompaction
public boolean allowCompaction()Check if intra-L0 compaction is enabled. When enabled, we try to compact smaller files into larger ones.See
setAllowCompaction(boolean).Default: false
- Returns:
- true if intra-L0 compaction is enabled, false otherwise.
-
disposeInternal
protected final void disposeInternal(long handle) - Specified by:
disposeInternalin classRocksObject
-