public class VersionSet extends Object
| Constructor and Description |
|---|
VersionSet(Options options,
File databaseDir,
TableCache tableCache,
InternalKeyComparator internalKeyComparator,
Env env) |
public VersionSet(Options options, File databaseDir, TableCache tableCache, InternalKeyComparator internalKeyComparator, Env env) throws IOException
IOExceptionpublic void release()
throws IOException
IOExceptionpublic void removeVersion(Version version)
public InternalKeyComparator getInternalKeyComparator()
public TableCache getTableCache()
public Version getCurrent()
public long getManifestFileNumber()
public long getNextFileNumber()
public long getLogNumber()
public long getPrevLogNumber()
public MergingIterator iterator(ReadOptions options) throws IOException
IOExceptionpublic MergingIterator makeInputIterator(Compaction c) throws IOException
IOExceptionpublic boolean overlapInLevel(int level,
Slice smallestUserKey,
Slice largestUserKey)
public int numberOfFilesInLevel(int level)
public long numberOfBytesInLevel(int level)
public long getLastSequence()
public void setLastSequence(long newLastSequence)
public void logAndApply(VersionEdit edit, ReentrantLock mutex) throws IOException
IOExceptionpublic boolean recover()
throws IOException
true if manifest should be saved, false otherwiseIOExceptionpublic List<FileMetaData> getLiveFiles()
public long targetFileSize()
public long maxGrandParentOverlapBytes()
public long expandedCompactionByteSizeLimit()
public long maxFileSizeForLevel()
public long totalFileSize(List<FileMetaData> files)
public boolean needsCompaction()
public Compaction compactRange(int level, InternalKey begin, InternalKey end)
public Compaction pickCompaction()
public long getMaxNextLevelOverlappingBytes()
public CharSequence levelSummary()
Copyright © 2011–2020. All rights reserved.