liangyepianzhou commented on code in PR #21274:
URL: https://github.com/apache/pulsar/pull/21274#discussion_r1379527495


##########
pulsar-broker/src/main/java/org/apache/pulsar/broker/transaction/pendingack/impl/PendingAckHandleImpl.java:
##########
@@ -945,12 +955,35 @@ public void completeHandleFuture() {
     }
 
     public void exceptionHandleFuture(Throwable t) {
+        if(isRetryableException(t)) {
+            long retryTime = backoff.next();
+            log.warn("[{}][{}] Failed to init transaction pending ack handler. 
It will be retried in {} Ms",
+                    persistentSubscription.getTopic().getName(), subName, 
retryTime, t);
+            transactionOpTimer.newTimeout((timeout) -> init(), retryTime, 
TimeUnit.MILLISECONDS);
+            return;
+        }
+        log.error("PendingAckHandleImpl init fail! TopicName : {}, SubName: 
{}", topicName, subName, t);
+        handleCacheRequest();
+        changeToErrorState();
+        this.pendingAckStoreFuture.completeExceptionally(new 
TransactionPendingAckException
+                
.TransactionPendingAckStoreInitException(String.format("PendingAckHandleImpl 
init fail! TopicName : "

Review Comment:
   First, the definition of `TransactionPendingAckStoreInitException` does not 
provide the error message.
   Secondly, this might not be an end-to-end request. It could happen when the 
topic loading.
   ```
       public static class TransactionPendingAckStoreInitException extends 
TransactionPendingAckException {
           public TransactionPendingAckStoreInitException(String message) {
               super(message);
           }
   
           public TransactionPendingAckStoreInitException(String message, 
Throwable throwable) {
               super(message, throwable);}
       }
   ```



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