lordcheng10 commented on code in PR #16420:
URL: https://github.com/apache/pulsar/pull/16420#discussion_r915576289


##########
managed-ledger/src/main/java/org/apache/bookkeeper/mledger/impl/ManagedLedgerImpl.java:
##########
@@ -1545,21 +1546,21 @@ public void operationFailed(MetaStoreException e) {
                 }
             };
 
-            updateLedgersListAfterRollover(cb);
+            updateLedgersListAfterRollover(cb, 
getManagedLedgerInfo(ledgersTmp));
         }
     }
-
-    private void updateLedgersListAfterRollover(MetaStoreCallback<Void> 
callback) {
+    private void updateLedgersListAfterRollover(MetaStoreCallback<Void> 
callback, ManagedLedgerInfo mlInfo) {
         if (!metadataMutex.tryLock()) {
             // Defer update for later
-            scheduledExecutor.schedule(() -> 
updateLedgersListAfterRollover(callback), 100, TimeUnit.MILLISECONDS);
+            scheduledExecutor.schedule(() -> 
updateLedgersListAfterRollover(callback, mlInfo),

Review Comment:
   
   
   
   > Why do we need to create a new method?
   
   
   In order to avoid affecting other logic that uses getManagedLedgerInfo, a 
getManagedLedgerInfo method is added here.
   The new method has made some changes again, please review again, thanks! 
@mattisonchao 



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to