You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-commits@jackrabbit.apache.org by js...@apache.org on 2026/09/28 09:36:00 UTC
(jackrabbit-oak) branch OAK-12421-flaky-ForkJoinUtilsTest created (now d590058d5d)
This is an automated email from the ASF dual-hosted git repository.
jsedding pushed a change to branch OAK-12421-flaky-ForkJoinUtilsTest
in repository https://gitbox.apache.org/repos/asf/jackrabbit-oak.git
at d590058d5d OAK-12421 - ForkJoinUtilsTest can be flaky
This branch includes the following new commits:
new d590058d5d OAK-12421 - ForkJoinUtilsTest can be flaky
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
(jackrabbit-oak) 01/01: OAK-12421 - ForkJoinUtilsTest can be flaky
Posted by js...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
jsedding pushed a commit to branch OAK-12421-flaky-ForkJoinUtilsTest
in repository https://gitbox.apache.org/repos/asf/jackrabbit-oak.git
commit d590058d5d3647a3015485726a87415e93b7b86e
Author: Julian Sedding <js...@apache.org>
AuthorDate: Mon Sep 28 11:35:40 2026 +0200
OAK-12421 - ForkJoinUtilsTest can be flaky
- block main thread for longer in order to effectively filter it out
---
.../oak/commons/internal/concurrent/ForkJoinUtilsTest.java | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/oak-commons/src/test/java/org/apache/jackrabbit/oak/commons/internal/concurrent/ForkJoinUtilsTest.java b/oak-commons/src/test/java/org/apache/jackrabbit/oak/commons/internal/concurrent/ForkJoinUtilsTest.java
index 8bdf01d4ec..9d15124dc2 100644
--- a/oak-commons/src/test/java/org/apache/jackrabbit/oak/commons/internal/concurrent/ForkJoinUtilsTest.java
+++ b/oak-commons/src/test/java/org/apache/jackrabbit/oak/commons/internal/concurrent/ForkJoinUtilsTest.java
@@ -44,7 +44,7 @@ public class ForkJoinUtilsTest {
.map(i -> Map.entry(i, isInCommonPool(Thread.currentThread())))
.collect(Collectors.toMap(Map.Entry::getKey, Map.Entry::getValue));
assertThat(results)
- .hasSizeBetween(9, 10) // account for the main thread executing an item
+ .hasSize(9) // the main thread is filtered out
.allSatisfy((key, value) -> {
assertThat(key).isBetween(0, 9);
assertThat(value).isTrue();
@@ -168,12 +168,13 @@ public class ForkJoinUtilsTest {
if (isMainThread) {
try {
// make sure "main" thread processes at most one item
- latch.await(100, TimeUnit.MILLISECONDS);
+ latch.await(5, TimeUnit.SECONDS);
} catch (InterruptedException e) {
throw new RuntimeException(e);
}
+ } else {
+ latch.countDown();
}
- latch.countDown();
return !isMainThread;
});
}