This is an automated email from the ASF dual-hosted git repository.
clebertsuconic pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/artemis.git
The following commit(s) were added to refs/heads/main by this push:
new 5ce64dfcbf NO-JIRA Fixing intermittent test failure
5ce64dfcbf is described below
commit 5ce64dfcbf140f9b1ed86cd503cb348ae1a05f0b
Author: Clebert Suconic <[email protected]>
AuthorDate: Tue Mar 17 16:27:13 2026 -0400
NO-JIRA Fixing intermittent test failure
---
.../integration/amqp/connect/BrokerInSyncTest.java | 19 +++++++++++++------
1 file changed, 13 insertions(+), 6 deletions(-)
diff --git
a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/amqp/connect/BrokerInSyncTest.java
b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/amqp/connect/BrokerInSyncTest.java
index 702be046c7..1696a108af 100644
---
a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/amqp/connect/BrokerInSyncTest.java
+++
b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/amqp/connect/BrokerInSyncTest.java
@@ -180,7 +180,7 @@ public class BrokerInSyncTest extends AmqpClientTestSupport
{
public void testSingleMessage(String protocol) throws Exception {
server.setIdentity("Server1");
{
- AMQPBrokerConnectConfiguration amqpConnection = new
AMQPBrokerConnectConfiguration("connectTowardsServer2", "tcp://localhost:" +
AMQP_PORT_2).setReconnectAttempts(3).setRetryInterval(100);
+ AMQPBrokerConnectConfiguration amqpConnection = new
AMQPBrokerConnectConfiguration("connectTowardsServer2", "tcp://localhost:" +
AMQP_PORT_2).setReconnectAttempts(300).setRetryInterval(100);
amqpConnection.addElement(new
AMQPMirrorBrokerConnectionElement().setDurable(true));
server.getConfiguration().addAMQPConnection(amqpConnection);
}
@@ -190,7 +190,7 @@ public class BrokerInSyncTest extends AmqpClientTestSupport
{
server_2.setIdentity("Server2");
{
- AMQPBrokerConnectConfiguration amqpConnection = new
AMQPBrokerConnectConfiguration("connectTowardsServer1", "tcp://localhost:" +
AMQP_PORT).setReconnectAttempts(-1).setRetryInterval(100);
+ AMQPBrokerConnectConfiguration amqpConnection = new
AMQPBrokerConnectConfiguration("connectTowardsServer1", "tcp://localhost:" +
AMQP_PORT).setReconnectAttempts(300).setRetryInterval(100);
amqpConnection.addElement(new
AMQPMirrorBrokerConnectionElement().setDurable(true));
server_2.getConfiguration().addAMQPConnection(amqpConnection);
}
@@ -265,8 +265,15 @@ public class BrokerInSyncTest extends
AmqpClientTestSupport {
session1.commit();
}
- connection1.close();
- connection2.close();
+ try {
+ connection1.close();
+ } catch (Exception ignored) {
+ }
+
+ try {
+ connection2.close();
+ } catch (Exception ignored) {
+ }
Wait.assertEquals(0L, queueOnServer1::getMessageCount, 5000, 100);
Wait.assertEquals(0L, queueOnServer2::getMessageCount, 5000, 100);
@@ -344,7 +351,7 @@ public class BrokerInSyncTest extends AmqpClientTestSupport
{
server_2.setIdentity("Server2");
{
- AMQPBrokerConnectConfiguration amqpConnection = new
AMQPBrokerConnectConfiguration("to_1", "tcp://localhost:" +
AMQP_PORT).setReconnectAttempts(-1).setRetryInterval(100);
+ AMQPBrokerConnectConfiguration amqpConnection = new
AMQPBrokerConnectConfiguration("to_1", "tcp://localhost:" +
AMQP_PORT).setReconnectAttempts(300).setRetryInterval(100);
amqpConnection.addElement(new
AMQPMirrorBrokerConnectionElement().setDurable(true));
server_2.getConfiguration().addAMQPConnection(amqpConnection);
}
@@ -444,7 +451,7 @@ public class BrokerInSyncTest extends AmqpClientTestSupport
{
server_2.setIdentity("Server2");
{
- AMQPBrokerConnectConfiguration amqpConnection = new
AMQPBrokerConnectConfiguration("to_1", "tcp://localhost:" +
AMQP_PORT).setReconnectAttempts(-1).setRetryInterval(100);
+ AMQPBrokerConnectConfiguration amqpConnection = new
AMQPBrokerConnectConfiguration("to_1", "tcp://localhost:" +
AMQP_PORT).setReconnectAttempts(300).setRetryInterval(100);
amqpConnection.addElement(new
AMQPMirrorBrokerConnectionElement().setDurable(true));
server_2.getConfiguration().addAMQPConnection(amqpConnection);
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]