File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
bookkeeper-server/src/main/java/org/apache/bookkeeper/replication Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change 3636import java .util .concurrent .TimeUnit ;
3737import java .util .concurrent .atomic .AtomicBoolean ;
3838import java .util .function .BiConsumer ;
39+ import java .util .stream .Collectors ;
3940import org .apache .bookkeeper .client .BKException ;
4041import org .apache .bookkeeper .client .BookKeeper ;
4142import org .apache .bookkeeper .client .BookKeeperAdmin ;
@@ -386,7 +387,12 @@ public void start() {
386387
387388 try {
388389 watchBookieChanges ();
389- knownBookies = getAvailableBookies ();
390+ // Start with all available bookies
391+ // to handle situations where the auditor
392+ // is started after some bookies have already failed
393+ knownBookies = admin .getAllBookies ().stream ()
394+ .map (BookieId ::toString )
395+ .collect (Collectors .toList ());
390396 this .ledgerUnderreplicationManager
391397 .notifyLostBookieRecoveryDelayChanged (new LostBookieRecoveryDelayChangedCb ());
392398 } catch (BKException bke ) {
You can’t perform that action at this time.
0 commit comments