@InterfaceAudience.LimitedPrivate(value="Configuration") public class DateTieredCompactionPolicy extends SortedCompactionPolicy
comConf, storeConfigInfo
Constructor and Description |
---|
DateTieredCompactionPolicy(org.apache.hadoop.conf.Configuration conf,
StoreConfigInformation storeConfigInfo) |
Modifier and Type | Method and Description |
---|---|
protected CompactionRequest |
createCompactionRequest(ArrayList<StoreFile> candidateSelection,
boolean tryingMajor,
boolean mayUseOffPeak,
boolean mayBeStuck) |
boolean |
needsCompaction(Collection<StoreFile> storeFiles,
List<StoreFile> filesCompacting)
Heuristics for guessing whether we need minor compaction.
|
CompactionRequest |
selectMajorCompaction(ArrayList<StoreFile> candidateSelection) |
CompactionRequest |
selectMinorCompaction(ArrayList<StoreFile> candidateSelection,
boolean mayUseOffPeak,
boolean mayBeStuck)
We receive store files sorted in ascending order by seqId then scan the list of files.
|
boolean |
shouldPerformMajorCompaction(Collection<StoreFile> filesToCompact) |
checkMinFilesCriteria, filterBulk, getCurrentEligibleFiles, getNextMajorCompactTime, preSelectCompactionForCoprocessor, removeExcessFiles, selectCompaction, skipLargeFiles, throttleCompaction
getConf, setConf
public DateTieredCompactionPolicy(org.apache.hadoop.conf.Configuration conf, StoreConfigInformation storeConfigInfo) throws IOException
IOException
public boolean needsCompaction(Collection<StoreFile> storeFiles, List<StoreFile> filesCompacting)
needsCompaction
in class SortedCompactionPolicy
public boolean shouldPerformMajorCompaction(Collection<StoreFile> filesToCompact) throws IOException
shouldPerformMajorCompaction
in class SortedCompactionPolicy
filesToCompact
- Files to compact. Can be null.IOException
protected CompactionRequest createCompactionRequest(ArrayList<StoreFile> candidateSelection, boolean tryingMajor, boolean mayUseOffPeak, boolean mayBeStuck) throws IOException
createCompactionRequest
in class SortedCompactionPolicy
IOException
public CompactionRequest selectMajorCompaction(ArrayList<StoreFile> candidateSelection)
public CompactionRequest selectMinorCompaction(ArrayList<StoreFile> candidateSelection, boolean mayUseOffPeak, boolean mayBeStuck) throws IOException
IOException
Copyright © 2007–2019 The Apache Software Foundation. All rights reserved.