hrsakai commented on PR #17432:
URL: https://github.com/apache/pulsar/pull/17432#issuecomment-1236620722

   @eolivelli 
   I see.
   
   Checking for IllegalArgumentException in some logic, should we fix all of 
them?
   
   e.g.
   
https://github.com/apache/pulsar/blob/46b1239a23fd2a250b009df1e9b4a65341d299a7/managed-ledger/src/main/java/org/apache/bookkeeper/mledger/impl/ManagedCursorImpl.java#L1559-L1577
   
   <br>
   Also, should new exception extend ManagedLedgerException?
   
   e.g.
   ```
   -              if (exception.getCause() instanceof 
MarkDeletingMarkedPosition) {
   +              if (exception instanceof MarkDeletingMarkedPosition) {
                       // this is not actually a problem, we should not log a 
stacktrace
                       log.info("[{}][{}] Cannot flush mark-delete position: 
{}", ledger.getName(),
                               name, exception.getCause().getMessage());
                   } else {
                       log.warn("[{}][{}] Failed to flush mark-delete 
position", ledger.getName(), name, exception);
                   }
   ```


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