Class AuditorBookieCheckTask
- java.lang.Object
-
- org.apache.bookkeeper.replication.AuditorTask
-
- org.apache.bookkeeper.replication.AuditorBookieCheckTask
-
- All Implemented Interfaces:
java.lang.Runnable
public class AuditorBookieCheckTask extends AuditorTask
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.apache.bookkeeper.replication.AuditorTask
AuditorTask.ShutdownTaskHandler
-
-
Field Summary
-
Fields inherited from class org.apache.bookkeeper.replication.AuditorTask
admin, auditorStats, conf, ledgerManager, ledgerUnderreplicationManager
-
-
Constructor Summary
Constructors Constructor Description AuditorBookieCheckTask(ServerConfiguration conf, AuditorStats auditorStats, BookKeeperAdmin admin, LedgerManager ledgerManager, LedgerUnderreplicationManager ledgerUnderreplicationManager, AuditorTask.ShutdownTaskHandler shutdownTaskHandler, BookieLedgerIndexer bookieLedgerIndexer, java.util.function.BiConsumer<java.util.concurrent.atomic.AtomicBoolean,java.lang.Throwable> hasAuditCheckTask, java.util.function.BiConsumer<java.lang.Void,java.lang.Throwable> submitCheckTask)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) voidauditBookies()protected voidrunTask()voidshutdown()(package private) voidstartAudit(boolean shutDownTask)Start running the actual audit task.protected voidwaitIfLedgerReplicationDisabled()-
Methods inherited from class org.apache.bookkeeper.replication.AuditorTask
getAvailableBookies, getBookKeeper, getBookKeeperAdmin, hasBookieCheckTask, isLedgerReplicationEnabled, publishSuspectedLedgersAsync, run, submitShutdownTask
-
-
-
-
Constructor Detail
-
AuditorBookieCheckTask
public AuditorBookieCheckTask(ServerConfiguration conf, AuditorStats auditorStats, BookKeeperAdmin admin, LedgerManager ledgerManager, LedgerUnderreplicationManager ledgerUnderreplicationManager, AuditorTask.ShutdownTaskHandler shutdownTaskHandler, BookieLedgerIndexer bookieLedgerIndexer, java.util.function.BiConsumer<java.util.concurrent.atomic.AtomicBoolean,java.lang.Throwable> hasAuditCheckTask, java.util.function.BiConsumer<java.lang.Void,java.lang.Throwable> submitCheckTask)
-
-
Method Detail
-
runTask
protected void runTask()
- Specified by:
runTaskin classAuditorTask
-
shutdown
public void shutdown()
- Specified by:
shutdownin classAuditorTask
-
startAudit
void startAudit(boolean shutDownTask)
Start running the actual audit task.- Parameters:
shutDownTask- A boolean that indicates whether or not to schedule shutdown task on any failure
-
auditBookies
void auditBookies() throws ReplicationException.BKAuditException, java.lang.InterruptedException, BKException- Throws:
ReplicationException.BKAuditExceptionjava.lang.InterruptedExceptionBKException
-
waitIfLedgerReplicationDisabled
protected void waitIfLedgerReplicationDisabled() throws ReplicationException.UnavailableException, java.lang.InterruptedException- Throws:
ReplicationException.UnavailableExceptionjava.lang.InterruptedException
-
-