BewareMyPower commented on code in PR #20096:
URL: https://github.com/apache/pulsar/pull/20096#discussion_r1169408980


##########
managed-ledger/src/main/java/org/apache/bookkeeper/mledger/impl/ManagedCursorImpl.java:
##########
@@ -3066,21 +3068,25 @@ boolean shouldCloseLedger(LedgerHandle lh) {
         }
     }
 
-    void switchToNewLedger(final LedgerHandle lh, final VoidCallback callback) 
{
+    void switchToNewLedger(@Nonnull LedgerHandle lh, VoidCallback callback) {

Review Comment:
   I didn't get why should we add a `@Nonnull` annotation to `lh`. With this 
annotation, it seems that `lh` should not be null while `callback` might be 
`null`. However, `callback` should also be non-null.



-- 
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