@InterfaceAudience.Private public class HMobStore extends HStore
BLOCK_STORAGE_POLICY_KEY, BLOCKING_STOREFILES_KEY, COMPACTCHECKER_INTERVAL_MULTIPLIER_KEY, conf, DEEP_OVERHEAD, DEFAULT_BLOCK_STORAGE_POLICY, DEFAULT_BLOCKING_STOREFILE_COUNT, DEFAULT_COMPACTCHECKER_INTERVAL_MULTIPLIER, FIXED_OVERHEAD, memstore, MEMSTORE_CLASS_NAMENO_PRIORITY, PRIORITY_USER| Constructor and Description |
|---|
HMobStore(HRegion region,
ColumnFamilyDescriptor family,
org.apache.hadoop.conf.Configuration confParam,
boolean warmup) |
| Modifier and Type | Method and Description |
|---|---|
void |
commitFile(org.apache.hadoop.fs.Path sourceFile,
org.apache.hadoop.fs.Path targetPath)
Commits the mob file.
|
protected KeyValueScanner |
createScanner(Scan scan,
ScanInfo scanInfo,
NavigableSet<byte[]> targetCols,
long readPt)
Gets the MobStoreScanner or MobReversedStoreScanner.
|
protected StoreEngine<?,?,?,?> |
createStoreEngine(HStore store,
org.apache.hadoop.conf.Configuration conf,
CellComparator cellComparator)
Creates the mob store engine.
|
StoreFileWriter |
createWriter(Date date,
long maxKeyCount,
Compression.Algorithm compression,
byte[] startKey,
boolean isCompaction,
Consumer<org.apache.hadoop.fs.Path> writerCreationTracker)
Creates the writer for the mob file in the mob family directory.
|
StoreFileWriter |
createWriterInTmp(Date date,
long maxKeyCount,
Compression.Algorithm compression,
byte[] startKey,
boolean isCompaction)
Creates the writer for the mob file in temp directory.
|
StoreFileWriter |
createWriterInTmp(MobFileName mobFileName,
org.apache.hadoop.fs.Path basePath,
long maxKeyCount,
Compression.Algorithm compression,
boolean isCompaction,
Consumer<org.apache.hadoop.fs.Path> writerCreationTracker)
Creates the writer for the mob file in temp directory.
|
StoreFileWriter |
createWriterInTmp(String date,
org.apache.hadoop.fs.Path basePath,
long maxKeyCount,
Compression.Algorithm compression,
byte[] startKey,
boolean isCompaction,
Consumer<org.apache.hadoop.fs.Path> writerCreationTracker)
Creates the writer for the mob file in temp directory.
|
long |
getCellsCountCompactedFromMob() |
long |
getCellsCountCompactedToMob() |
long |
getCellsSizeCompactedFromMob() |
long |
getCellsSizeCompactedToMob() |
org.apache.hadoop.conf.Configuration |
getConfiguration()
Gets current config.
|
List<org.apache.hadoop.fs.Path> |
getLocations(TableName tableName) |
long |
getMobFlushCount() |
long |
getMobFlushedCellsCount() |
long |
getMobFlushedCellsSize() |
long |
getMobScanCellsCount() |
long |
getMobScanCellsSize() |
org.apache.hadoop.fs.Path |
getPath()
Gets the mob file path.
|
byte[] |
getRefCellTags() |
MobCell |
resolve(Cell reference,
boolean cacheBlocks)
Reads the cell from the mob file, and the read point does not count.
|
MobCell |
resolve(Cell reference,
boolean cacheBlocks,
boolean readEmptyValueOnMobCellMiss)
Reads the cell from the mob file with readEmptyValueOnMobCellMiss
|
MobCell |
resolve(Cell reference,
boolean cacheBlocks,
long readPt,
boolean readEmptyValueOnMobCellMiss)
Reads the cell from the mob file.
|
void |
updateCellsCountCompactedFromMob(long count) |
void |
updateCellsCountCompactedToMob(long count) |
void |
updateCellsSizeCompactedFromMob(long size) |
void |
updateCellsSizeCompactedToMob(long size) |
void |
updateMobFlushCount() |
void |
updateMobFlushedCellsCount(long count) |
void |
updateMobFlushedCellsSize(long size) |
void |
updateMobScanCellsCount(long count) |
void |
updateMobScanCellsSize(long size) |
add, add, addChangedReaderObserver, areWritesEnabled, assertBulkLoadHFileOk, bulkLoadHFile, bulkLoadHFile, cancelRequestedCompaction, canSplit, close, closeAndArchiveCompactedFiles, compact, createCacheConf, createFlushContext, deleteChangedReaderObserver, deregisterChildren, determineTTLFromFamily, doCompaction, finishCompactionRequest, flushCache, getAvgStoreFileAge, getBlockingFileCount, getBloomFilterEligibleRequestsCount, getBloomFilterNegativeResultsCount, getBloomFilterRequestsCount, getCacheConfig, getColumnFamilyDescriptor, getColumnFamilyName, getCompactedCellsCount, getCompactedCellsSize, getCompactedFiles, getCompactedFilesCount, getCompactionCheckMultiplier, getCompactionPressure, getCompactionProgress, getCompactPriority, getComparator, getCoprocessorHost, getCurrentParallelPutCount, getDataBlockEncoder, getFileSystem, getFlushableSize, getFlushedCellsCount, getFlushedCellsSize, getFlushedOutputFileSize, getHFilesSize, getHRegion, getLastCompactSize, getMajorCompactedCellsCount, getMajorCompactedCellsSize, getMaxCompactedStoreFileRefCount, getMaxMemStoreTS, getMaxSequenceId, getMaxStoreFileAge, getMemStoreFlushSize, getMemstoreOnlyRowReadsCount, getMemStoreSize, getMinStoreFileAge, getMixedRowReadsCount, getNumHFiles, getNumReferenceFiles, getOffPeakHours, getReadOnlyConfiguration, getRegionFileSystem, getRegionInfo, getScanInfo, getScanner, getScanners, getScanners, getScanners, getScanners, getSize, getSmallestReadPoint, getSnapshotSize, getSplitPoint, getStoreEngine, getStorefiles, getStoreFilesBeingWritten, getStorefilesCount, getStorefilesRootLevelIndexSize, getStorefilesSize, getStoreFileTtl, getStoreRefCount, getStoreSizeUncompressed, getTableName, getTotalStaticBloomSize, getTotalStaticIndexSize, hasReferences, hasTooManyStoreFiles, heapSize, isPrimaryReplicaStore, isSloppyMemStore, needsCompaction, onConfigurationChange, postSnapshotOperation, preBulkLoadHFile, preFlushSeqIDEstimation, preSnapshotOperation, recreateScanners, refreshStoreFiles, refreshStoreFiles, refreshStoreSizeAndTotalBytes, registerChildren, replayCompactionMarker, requestCompaction, requestCompaction, shouldPerformMajorCompaction, startReplayingFromWAL, stopReplayingFromWAL, throttleCompaction, timeOfOldestEdit, toString, triggerMajorCompaction, tryCommitRecoveredHFile, updateCompactedMetrics, upsertpublic HMobStore(HRegion region, ColumnFamilyDescriptor family, org.apache.hadoop.conf.Configuration confParam, boolean warmup) throws IOException
IOExceptionpublic org.apache.hadoop.conf.Configuration getConfiguration()
protected KeyValueScanner createScanner(Scan scan, ScanInfo scanInfo, NavigableSet<byte[]> targetCols, long readPt) throws IOException
createScanner in class HStoreIOExceptionprotected StoreEngine<?,?,?,?> createStoreEngine(HStore store, org.apache.hadoop.conf.Configuration conf, CellComparator cellComparator) throws IOException
createStoreEngine in class HStorestore - The store. An unfortunate dependency needed due to it being passed to
coprocessors via the compactor.conf - Store configuration.cellComparator - KVComparator for storeFileManager.IOExceptionpublic StoreFileWriter createWriterInTmp(Date date, long maxKeyCount, Compression.Algorithm compression, byte[] startKey, boolean isCompaction) throws IOException
date - The latest date of written cells.maxKeyCount - The key count.compression - The compression algorithm.startKey - The start key.isCompaction - If the writer is used in compaction.IOExceptionpublic StoreFileWriter createWriter(Date date, long maxKeyCount, Compression.Algorithm compression, byte[] startKey, boolean isCompaction, Consumer<org.apache.hadoop.fs.Path> writerCreationTracker) throws IOException
date - The latest date of written cells.maxKeyCount - The key count.compression - The compression algorithm.startKey - The start key.isCompaction - If the writer is used in compaction.IOExceptionpublic StoreFileWriter createWriterInTmp(String date, org.apache.hadoop.fs.Path basePath, long maxKeyCount, Compression.Algorithm compression, byte[] startKey, boolean isCompaction, Consumer<org.apache.hadoop.fs.Path> writerCreationTracker) throws IOException
date - The date string, its format is yyyymmmdd.basePath - The basic path for a temp directory.maxKeyCount - The key count.compression - The compression algorithm.startKey - The start key.isCompaction - If the writer is used in compaction.IOExceptionpublic StoreFileWriter createWriterInTmp(MobFileName mobFileName, org.apache.hadoop.fs.Path basePath, long maxKeyCount, Compression.Algorithm compression, boolean isCompaction, Consumer<org.apache.hadoop.fs.Path> writerCreationTracker) throws IOException
mobFileName - The mob file name.basePath - The basic path for a temp directory.maxKeyCount - The key count.compression - The compression algorithm.isCompaction - If the writer is used in compaction.IOExceptionpublic void commitFile(org.apache.hadoop.fs.Path sourceFile,
org.apache.hadoop.fs.Path targetPath)
throws IOException
sourceFile - The source file.targetPath - The directory path where the source file is renamed to.IOExceptionpublic MobCell resolve(Cell reference, boolean cacheBlocks) throws IOException
reference - The cell found in the HBase, its value is a path to a mob file.cacheBlocks - Whether the scanner should cache blocks.IOExceptionpublic MobCell resolve(Cell reference, boolean cacheBlocks, boolean readEmptyValueOnMobCellMiss) throws IOException
reference - The cell found in the HBase, its value is a path to a mob
file.cacheBlocks - Whether the scanner should cache blocks.readEmptyValueOnMobCellMiss - should return empty mob cell if reference can not be
resolved.IOExceptionpublic MobCell resolve(Cell reference, boolean cacheBlocks, long readPt, boolean readEmptyValueOnMobCellMiss) throws IOException
reference - The cell found in the HBase, its value is a path to a mob
file.cacheBlocks - Whether the scanner should cache blocks.readPt - the read point.readEmptyValueOnMobCellMiss - Whether return null value when the mob file is missing or
corrupt.IOExceptionpublic List<org.apache.hadoop.fs.Path> getLocations(TableName tableName) throws IOException
tableName - to look up locations for, can not be nullIOExceptionpublic org.apache.hadoop.fs.Path getPath()
public void updateCellsCountCompactedToMob(long count)
public long getCellsCountCompactedToMob()
public void updateCellsCountCompactedFromMob(long count)
public long getCellsCountCompactedFromMob()
public void updateCellsSizeCompactedToMob(long size)
public long getCellsSizeCompactedToMob()
public void updateCellsSizeCompactedFromMob(long size)
public long getCellsSizeCompactedFromMob()
public void updateMobFlushCount()
public long getMobFlushCount()
public void updateMobFlushedCellsCount(long count)
public long getMobFlushedCellsCount()
public void updateMobFlushedCellsSize(long size)
public long getMobFlushedCellsSize()
public void updateMobScanCellsCount(long count)
public long getMobScanCellsCount()
public void updateMobScanCellsSize(long size)
public long getMobScanCellsSize()
public byte[] getRefCellTags()
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.