Package org.apache.hadoop.hbase.mob
Class FaultyMobStoreCompactor
java.lang.Object
org.apache.hadoop.hbase.regionserver.compactions.Compactor<org.apache.hadoop.hbase.regionserver.StoreFileWriter>
org.apache.hadoop.hbase.regionserver.compactions.DefaultCompactor
org.apache.hadoop.hbase.mob.DefaultMobStoreCompactor
org.apache.hadoop.hbase.mob.FaultyMobStoreCompactor
@Private
public class FaultyMobStoreCompactor
extends org.apache.hadoop.hbase.mob.DefaultMobStoreCompactor
This class is used for testing only. The main purpose is to emulate random failures during MOB
compaction process. Example of usage:
{ @code public class SomeTest { public void initConfiguration(Configuration conf) { conf.set(MobStoreEngine.DEFAULT_MOB_COMPACTOR_CLASS_KEY, FaultyMobStoreCompactor.class.getName()); conf.setDouble("hbase.mob.compaction.fault.probability", 0.1); } } }
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.hadoop.hbase.regionserver.compactions.Compactor
org.apache.hadoop.hbase.regionserver.compactions.Compactor.CellSinkFactory<S extends Object>, org.apache.hadoop.hbase.regionserver.compactions.Compactor.FileDetails, org.apache.hadoop.hbase.regionserver.compactions.Compactor.InternalScannerFactory
-
Field Summary
Modifier and TypeFieldDescription(package private) static double
private static final org.slf4j.Logger
static AtomicLong
(package private) static Random
static AtomicLong
static AtomicLong
static AtomicLong
Fields inherited from class org.apache.hadoop.hbase.mob.DefaultMobStoreCompactor
disableIO, ioOptimizedMode, mobLengthMap, mobRefSet, mobSizeThreshold, mobStore, userRequest
Fields inherited from class org.apache.hadoop.hbase.regionserver.compactions.Compactor
COMPACTION_PROGRESS_LOG_INTERVAL, compactionKVMax, compactScannerSizeLimit, conf, defaultScannerFactory, dropCacheMajor, dropCacheMinor, keepSeqIdPeriod, MAJOR_COMPACTION_DROP_CACHE, majorCompactionCompression, MINOR_COMPACTION_DROP_CACHE, minorCompactionCompression, store
-
Constructor Summary
ConstructorDescriptionFaultyMobStoreCompactor
(org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.hbase.regionserver.HStore store) -
Method Summary
Modifier and TypeMethodDescriptionprotected boolean
performCompaction
(org.apache.hadoop.hbase.regionserver.compactions.Compactor.FileDetails fd, org.apache.hadoop.hbase.regionserver.InternalScanner scanner, org.apache.hadoop.hbase.regionserver.CellSink writer, long smallestReadPoint, boolean cleanSeqId, org.apache.hadoop.hbase.regionserver.throttle.ThroughputController throughputController, org.apache.hadoop.hbase.regionserver.compactions.CompactionRequestImpl request, org.apache.hadoop.hbase.regionserver.compactions.CompactionProgress progress) Methods inherited from class org.apache.hadoop.hbase.mob.DefaultMobStoreCompactor
commitWriter, compact, getStoreInfo
Methods inherited from class org.apache.hadoop.hbase.regionserver.compactions.DefaultCompactor
abortWriter
Methods inherited from class org.apache.hadoop.hbase.regionserver.compactions.Compactor
compact, createParams, createScanner, createScanner, createWriter, createWriter, getProgress, isCompacting
-
Field Details
-
LOG
-
mobCounter
-
totalFailures
-
totalCompactions
-
totalMajorCompactions
-
failureProb
-
rnd
-
-
Constructor Details
-
FaultyMobStoreCompactor
public FaultyMobStoreCompactor(org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.hbase.regionserver.HStore store)
-
-
Method Details
-
performCompaction
protected boolean performCompaction(org.apache.hadoop.hbase.regionserver.compactions.Compactor.FileDetails fd, org.apache.hadoop.hbase.regionserver.InternalScanner scanner, org.apache.hadoop.hbase.regionserver.CellSink writer, long smallestReadPoint, boolean cleanSeqId, org.apache.hadoop.hbase.regionserver.throttle.ThroughputController throughputController, org.apache.hadoop.hbase.regionserver.compactions.CompactionRequestImpl request, org.apache.hadoop.hbase.regionserver.compactions.CompactionProgress progress) throws IOException - Overrides:
performCompaction
in classorg.apache.hadoop.hbase.mob.DefaultMobStoreCompactor
- Throws:
IOException
-