From d790331dcc2180c4a244d1df75375d0a8c73901d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nicol=C3=B2=20Boschi?= Date: Tue, 9 Apr 2024 14:00:57 +0200 Subject: [PATCH] timeout --- .github/workflows/tests.yaml | 3 --- .../java/com/datastax/oss/pulsar/jms/SelectorsTestsBase.java | 3 +++ 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index 3aafaf89..80cdbbc8 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -30,9 +30,6 @@ jobs: restore-keys: | ${{ runner.os }}-maven- - - name: Setup upterm session - uses: lhotari/action-upterm@v1 - - name: Build and test run: mvn -B clean javadoc:javadoc verify diff --git a/pulsar-jms/src/test/java/com/datastax/oss/pulsar/jms/SelectorsTestsBase.java b/pulsar-jms/src/test/java/com/datastax/oss/pulsar/jms/SelectorsTestsBase.java index 507d485c..7026d290 100644 --- a/pulsar-jms/src/test/java/com/datastax/oss/pulsar/jms/SelectorsTestsBase.java +++ b/pulsar-jms/src/test/java/com/datastax/oss/pulsar/jms/SelectorsTestsBase.java @@ -33,6 +33,7 @@ import java.util.UUID; import java.util.concurrent.CompletableFuture; import java.util.concurrent.CopyOnWriteArrayList; +import java.util.concurrent.TimeUnit; import javax.jms.CompletionListener; import javax.jms.Message; import javax.jms.MessageProducer; @@ -51,6 +52,7 @@ import org.apache.pulsar.common.util.FutureUtil; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.TestInstance; +import org.junit.jupiter.api.Timeout; import org.junit.jupiter.api.extension.RegisterExtension; @Slf4j @@ -482,6 +484,7 @@ public void onException(Message message, Exception e) { // This test may take long time, because it depends on how the broker // chooses the Consumer to try to dispatch the messages. @Test + @Timeout(value = 10, unit = TimeUnit.MINUTES) public void sendBatchWithCompetingConsumersOnQueue() throws Exception { Map properties = buildProperties(); if (enableBatching) {