8212899: java/util/concurrent/tck/JSR166TestCase.java - testMissedSignal_8187947(SubmissionPublisherTest): timed out waiting for CountDownLatch for 40 sec
Reviewed-by: martin, dholmes
--- a/test/jdk/java/util/concurrent/tck/SubmissionPublisherTest.java Wed Nov 28 14:28:28 2018 -0800
+++ b/test/jdk/java/util/concurrent/tck/SubmissionPublisherTest.java Wed Nov 28 15:25:14 2018 -0800
@@ -1011,7 +1011,11 @@
*/
public void testMissedSignal_8187947() throws Exception {
if (!atLeastJava9()) return; // backport to jdk8 too hard
- final int N = expensiveTests ? (1 << 20) : (1 << 10);
+ final int N =
+ ((ForkJoinPool.getCommonPoolParallelism() < 2) // JDK-8212899
+ ? (1 << 5)
+ : (1 << 10))
+ * (expensiveTests ? (1 << 10) : 1);
final CountDownLatch finished = new CountDownLatch(1);
final SubmissionPublisher<Boolean> pub = new SubmissionPublisher<>();
class Sub implements Subscriber<Boolean> {