This is an automated email from the ASF dual-hosted git repository.
dsmiley pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/solr.git
The following commit(s) were added to refs/heads/main by this push:
new ffc75e2c67d SOLR-16104 Fix TestCoreDiscovery.testTooManyTransientCores
ffc75e2c67d is described below
commit ffc75e2c67dd9dc945a21e58469a5403eedac371
Author: David Smiley <[email protected]>
AuthorDate: Sat Feb 25 00:59:53 2023 -0500
SOLR-16104 Fix TestCoreDiscovery.testTooManyTransientCores
Leniency, finally
---
solr/core/src/test/org/apache/solr/core/TestCoreDiscovery.java | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/solr/core/src/test/org/apache/solr/core/TestCoreDiscovery.java
b/solr/core/src/test/org/apache/solr/core/TestCoreDiscovery.java
index cfab1f69c15..cf5b75d77e7 100644
--- a/solr/core/src/test/org/apache/solr/core/TestCoreDiscovery.java
+++ b/solr/core/src/test/org/apache/solr/core/TestCoreDiscovery.java
@@ -345,10 +345,11 @@ public class TestCoreDiscovery extends SolrTestCaseJ4 {
() -> {
// See SOLR-16104 about this flakiness
final var loadedCoreNames = cc.getLoadedCoreNames();
- if (3 == loadedCoreNames.size()) {
+ if (3 == loadedCoreNames.size() || 4 == loadedCoreNames.size()) {
+ // 4 sometimes... Caffeine or background threads makes it hard
to be deterministic?
return true;
}
- log.warn("Waiting for 3 loaded cores but got: {}",
loadedCoreNames);
+ log.warn("Waiting for 3|4 loaded cores but got: {}",
loadedCoreNames);
return false;
});