Skip to content

Commit 9f2c879

Browse files
akarnokdviktorklang
authored andcommitted
Try a plain thread in case FJP deadlocks on CI
1 parent b14b00a commit 9f2c879

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Diff for: tck-flow/src/test/java/org/reactivestreams/tck/flow/SubmissionPublisherTest.java

+3-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ public SubmissionPublisherTest() {
2727
public Flow.Publisher<Integer> createFlowPublisher(final long elements) {
2828
final SubmissionPublisher<Integer> sp = new SubmissionPublisher<Integer>();
2929

30-
ForkJoinPool.commonPool().submit(new Runnable() {
30+
Thread t = new Thread(new Runnable() {
3131
@Override
3232
public void run() {
3333
while (sp.getNumberOfSubscribers() == 0) {
@@ -45,6 +45,8 @@ public void run() {
4545
sp.close();
4646
}
4747
});
48+
t.setDaemon(true);
49+
t.start();
4850

4951
return sp;
5052
}

0 commit comments

Comments
 (0)