public abstract class CompactFutureManager extends Object implements CompactManager
CompactManager
which runs compaction in a separate thread.Modifier and Type | Field and Description |
---|---|
protected Future<CompactResult> |
taskFuture |
Constructor and Description |
---|
CompactFutureManager() |
Modifier and Type | Method and Description |
---|---|
void |
cancelCompaction()
Cancel currently running compaction task.
|
protected Optional<CompactResult> |
innerGetCompactionResult(boolean blocking) |
boolean |
isCompacting()
Check if a compaction is in progress, or if a compaction result remains to be fetched.
|
protected CompactResult |
obtainCompactResult() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
addNewFile, allFiles, getCompactionResult, shouldWaitForLatestCompaction, shouldWaitForPreparingCheckpoint, triggerCompaction
protected Future<CompactResult> taskFuture
public void cancelCompaction()
CompactManager
cancelCompaction
in interface CompactManager
public boolean isCompacting()
CompactManager
isCompacting
in interface CompactManager
protected final Optional<CompactResult> innerGetCompactionResult(boolean blocking) throws ExecutionException, InterruptedException
@VisibleForTesting protected CompactResult obtainCompactResult() throws InterruptedException, ExecutionException
Copyright © 2023–2024 The Apache Software Foundation. All rights reserved.