codelipenghui opened a new pull request #10768: URL: https://github.com/apache/pulsar/pull/10768
Fixes #10767 ### Motivation The deadlock will happen in following steps: 1. The client internal thread got the consumer instance lock when call internalBatchReceiveAsync 2. The timer thread got the write lock of the UnAckedMessageTracker and then waiting on the consumer instance lock when call redeliverUnacknowledgedMessages 3. The client internal thread try to get the write lock of the UnAckedMessageTracker when adding unacked messages The deadlock happens. The fix is to ensure the timer thread unlock the write lock before call redeliverUnacknowledgedMessages -- 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. For queries about this service, please contact Infrastructure at: [email protected]
