diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml
index 74c342f..e487b6f 100644
--- a/.github/workflows/maven.yml
+++ b/.github/workflows/maven.yml
@@ -16,9 +16,9 @@ jobs:
steps:
- uses: actions/checkout@v2
- - name: Set up JDK 11
+ - name: Set up JDK 17
uses: actions/setup-java@v1
with:
- java-version: 11
+ java-version: 17
- name: Build with Maven
run: mvn -B package --file pom.xml
diff --git a/pom.xml b/pom.xml
index f547d28..1af3e83 100644
--- a/pom.xml
+++ b/pom.xml
@@ -11,8 +11,8 @@
/usr/bin/${project.artifactId}
true
2.28.0
- 11
- 11
+ 17
+ 17
UTF-8
@@ -30,22 +30,22 @@
commons-cli
commons-cli
- 1.5.0
+ 1.9.0
commons-io
commons-io
- 2.11.0
+ 2.19.0
commons-codec
commons-codec
- 1.16.0
+ 1.18.0
org.apache.commons
commons-lang3
- 3.12.0
+ 3.17.0
org.apache.geronimo.specs
@@ -55,7 +55,7 @@
ch.qos.logback
logback-classic
- 1.4.11
+ 1.5.18
org.apache.qpid
@@ -76,7 +76,7 @@
org.jboss.logmanager
jboss-logmanager
- 2.1.19.Final
+ 3.1.2.Final
test
@@ -87,12 +87,12 @@
com.fasterxml.jackson.core
jackson-databind
- 2.15.2
+ 2.19.0
org.graalvm.js
js
- 22.3.2
+ 23.0.8
org.graalvm.js
@@ -202,7 +202,7 @@
org.apache.xbean
xbean-spring
- 4.23
+ 4.27
test
@@ -261,7 +261,7 @@
jdeb
org.vafer
- 1.10
+ 1.13
package
@@ -307,7 +307,7 @@
maven-compiler-plugin
- 3.11.0
+ 3.14.0
-Xlint:all
diff --git a/src/main/java/co/nordlander/a/A.java b/src/main/java/co/nordlander/a/A.java
index 1e6abd2..1124a52 100755
--- a/src/main/java/co/nordlander/a/A.java
+++ b/src/main/java/co/nordlander/a/A.java
@@ -262,7 +262,8 @@ protected void executeMove(CommandLine cmdLine) throws JMSException,
DEFAULT_WAIT));
int j = 0;
while (j < count || count == 0) {
- Message msg = mq.receive(wait);
+ // some message system do not properly handle receive(0)
+ Message msg = wait == 0 ? mq.receive() : mq.receive(wait);
if (msg == null) {
output("No message received, due to the timeout expiring or the consumer is closed");
break;
@@ -423,7 +424,8 @@ protected void executeGet(final CommandLine cmdLine) throws JMSException,
DEFAULT_WAIT));
int i = 0;
while (i < count || count == 0) {
- Message msg = mq.receive(wait);
+ // some message system do not properly handle receive(0)
+ Message msg = wait == 0 ? mq.receive() : mq.receive(wait);
if (msg == null) {
output("No message received");
break;
@@ -614,7 +616,8 @@ protected List consumeMessages(CommandLine cmdLine) throws JMSException
List msgs = new ArrayList<>();
int i = 0;
while (i < count || count == 0) {
- Message msg = mq.receive(wait);
+ // some message system do not properly handle receive(0)
+ Message msg = wait == 0 ? mq.receive() : mq.receive(wait);
if (msg == null) {
break;
} else {