You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by "merlimat (via GitHub)" <gi...@apache.org> on 2026/04/03 22:56:24 UTC

[PR] [fix][test] Fix flaky IsolatedBookieEnsemblePlacementPolicyTest.testBookieInfoChange [pulsar]

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

   ## Motivation
   
   `IsolatedBookieEnsemblePlacementPolicyTest.testBookieInfoChange` is flaky because `initialize()` loads the bookie rack configuration asynchronously. When `newEnsemble()` runs before the async load completes, `cachedRackConfiguration` is null, no bookie isolation is applied, and the ensemble may include bookies from the wrong group.
   
   ### Stack trace
   ```
   IsolatedBookieEnsemblePlacementPolicyTest > testBookieInfoChange FAILED
       java.lang.AssertionError: expected [true] but found [false]
           at org.testng.Assert.fail(Assert.java:110)
           at org.testng.Assert.failNotEquals(Assert.java:1577)
           at org.testng.Assert.assertTrue(Assert.java:56)
           at org.testng.Assert.assertTrue(Assert.java:66)
           at IsolatedBookieEnsemblePlacementPolicyTest.testBookieInfoChange(IsolatedBookieEnsemblePlacementPolicyTest.java:390)
   ```
   
   ## Modifications
   
   Add an Awaitility wait after `initialize()` to ensure the async cache load has completed before calling `newEnsemble()`.
   
   ### Documentation
   - [x] `doc-not-needed`


-- 
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: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [fix][test] Fix flaky IsolatedBookieEnsemblePlacementPolicyTest.testBookieInfoChange [pulsar]

Posted by "merlimat (via GitHub)" <gi...@apache.org>.
merlimat merged PR #25473:
URL: https://github.com/apache/pulsar/pull/25473


-- 
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: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org