lhotari commented on issue #23056:
URL: https://github.com/apache/pulsar/issues/23056#issuecomment-2277901801

   > I solved this issue by modifying the consumer source code. Could you 
please ask the community if they would consider adopting this approach or if 
there are any more elegant solutions? The main modifications are:
   > 
   > 1. In the `org.apache.pulsar.client.impl.ConsumerImpl#connectionOpened`  , 
call the parent consumer’s  
`org.apache.pulsar.client.impl.MultiTopicsConsumerImpl`  
clearIncomingMessages().  ——  This is necessary because Pulsar does not perform 
this cleanup , these message will cause duplication
   
   @mawenyu Interesting. This seems to be related to #21767 which is a draft PR 
I have. 
   
   > 2. In the  `org.apache.pulsar.client.impl.ConsumerImpl#connectionOpened`   
delay the invoke of 
`org.apache.pulsar.client.impl.ConsumerImpl#increaseAvailablePermits`   by 3 
seconds and execute it asynchronously. —— This 3-second delay allows the client 
to acknowledge the received messages.
   
   Just wondering if the 
https://github.com/apache/pulsar/wiki/PIP-84-:-Pulsar-client:-Redeliver-command-add-epoch
 design or implementation has some gap.


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