Shoothzj opened a new pull request, #17856:
URL: https://github.com/apache/pulsar/pull/17856

   ### Motivation
   
https://github.com/apache/pulsar/blob/b89c1451551a6bbe681465726906a2e61c9d8a69/pulsar-client/src/main/java/org/apache/pulsar/client/impl/ClientCnx.java#L282-L297
 
   The `pendingLookupRequestSemaphore` will leak when channel inactive. There 
are `LookUpRequestSemaphore` not released when removing it from 
`pendingRequests`
   
   ### Modifications
   We can't easily release the semaphore in `channelInactive`, because there 
are not only `LookUpRequest`. So release the semaphore when connectionException
   
   ### Verifying this change
   Add unit test case to cover this change
   
   ### Documentation
   
   <!-- DO NOT REMOVE THIS SECTION. CHECK THE PROPER BOX ONLY. -->
   
   - [ ] `doc-required` 
   (Your PR needs to update docs and you will update later)
   
   - [x] `doc-not-needed` 
   bug fixs, no need doc
   
   - [ ] `doc` 
   (Your PR contains doc changes)
   
   - [ ] `doc-complete`
   (Docs have been already added)


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