Technoboy- opened a new pull request, #21708:
URL: https://github.com/apache/pulsar/pull/21708

   Fixes #21534 
   
   ### Motivation
   
   The root cause is that `retryStrategically` only tries to test 50 times, not 
caring about the result. So the result can be false after 50 times. Then the 
broker deletes the topic and 
`pulsar1.getBrokerService().getTopics().containsKey(topicName)=false`.
   But the `close` command from broker to producer is async, so the 
`producer1(line-97)` can be connected at that time.
   
   ```
   MockedPulsarServiceBaseTest.retryStrategically((test) -> 
!pulsar1.getBrokerService().getTopics().containsKey(topicName), 50, 150);
   ```
   
   
   ### 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 -->
   
   
   


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