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

   ### Motivation
   
   | `time`| `thread-reconnect` | `thread-close-consumer` |
   | --- | --- | --- |
   | 1 | check connect state: <br> - reconnectiong <br> - `cnx` is `null` | |
   | 2 | | Change state to `ready` |
   | 3 | | Reconnected |
   | 4 | Change state to `closed` and skip sending requests to remove consumer 
in broker memory | |
   
   After the above steps, there is an orphan consumer in the broker memory, 
which will cause the error `Exclusive consumer is already connected` and other 
errors.
   
   BTW, this issue may cause the compaction task stuck, because the new reader 
can not be created successfully due to the previous consumer has not been 
removed.
   
   You can reproduce the issue by 
   
   ### Modifications
   
   Fix the issue.
   
   
   
   ### Documentation
   
   <!-- DO NOT REMOVE THIS SECTION. CHECK THE PROPER BOX ONLY. -->
   
   - [ ] `doc` <!-- Your PR contains doc changes. -->
   - [ ] `doc-required` <!-- Your PR changes impact docs and you will update 
later -->
   - [x] `doc-not-needed` <!-- Your PR changes do not impact docs -->
   - [ ] `doc-complete` <!-- Docs have been already added -->
   
   ### Matching PR in forked repository
   
   PR in forked repository: x
   


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