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) void
auditBookies()
protected void
runTask()
void
shutdown()
(package private) void
startAudit(boolean shutDownTask)
Start running the actual audit task.protected void
waitIfLedgerReplicationDisabled()
-
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:
runTask
in classAuditorTask
-
shutdown
public void shutdown()
- Specified by:
shutdown
in 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.BKAuditException
java.lang.InterruptedException
BKException
-
waitIfLedgerReplicationDisabled
protected void waitIfLedgerReplicationDisabled() throws ReplicationException.UnavailableException, java.lang.InterruptedException
- Throws:
ReplicationException.UnavailableException
java.lang.InterruptedException
-
-