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/activemq-artemis.git


The following commit(s) were added to refs/heads/main by this push:
     new 0906893934 ARTEMIS-5214 Trying to address intermittent failure on 
CuratorDistributedLockTest
0906893934 is described below

commit 090689393446031988f504df4a4bd1e95e3236d3
Author: Clebert Suconic <[email protected]>
AuthorDate: Mon Dec 16 12:14:39 2024 -0500

    ARTEMIS-5214 Trying to address intermittent failure on 
CuratorDistributedLockTest
    
    To be honest I am not 100% sure this will fix the issue I saw, but it will 
certainly help me diagnose future failures,
    by making sure the server is stopped and assigning a proper ID on each 
server.
    
    For future record I am seeing the following exception occasionally on a CI:
    
    Caused by: 
org.apache.zookeeper.server.quorum.QuorumPeerConfig$ConfigException: Client and 
election port must be different! Please update the configuration file on 
server.14
            at 
org.apache.zookeeper.server.quorum.QuorumPeer$QuorumServer.initializeWithAddressString(QuorumPeer.java:366)
---
 .../artemis/lockmanager/zookeeper/CuratorDistributedLockTest.java      | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git 
a/artemis-lockmanager/artemis-lockmanager-ri/src/test/java/org/apache/activemq/artemis/lockmanager/zookeeper/CuratorDistributedLockTest.java
 
b/artemis-lockmanager/artemis-lockmanager-ri/src/test/java/org/apache/activemq/artemis/lockmanager/zookeeper/CuratorDistributedLockTest.java
index 1d219bf5f2..f5bcfad156 100644
--- 
a/artemis-lockmanager/artemis-lockmanager-ri/src/test/java/org/apache/activemq/artemis/lockmanager/zookeeper/CuratorDistributedLockTest.java
+++ 
b/artemis-lockmanager/artemis-lockmanager-ri/src/test/java/org/apache/activemq/artemis/lockmanager/zookeeper/CuratorDistributedLockTest.java
@@ -78,7 +78,7 @@ public class CuratorDistributedLockTest extends 
DistributedLockTest {
 
       clusterSpecs = new InstanceSpec[zkNodes];
       for (int i = 0; i < zkNodes; i++) {
-         clusterSpecs[i] = new InstanceSpec(newFolder(tmpFolder, "node" + i), 
BASE_SERVER_PORT + i, -1, -1, true, -1, SERVER_TICK_MS, -1);
+         clusterSpecs[i] = new InstanceSpec(newFolder(tmpFolder, "node" + i), 
BASE_SERVER_PORT + i, -1, -1, true, i, SERVER_TICK_MS, -1);
       }
       testingServer = new TestingCluster(clusterSpecs);
       testingServer.start();
@@ -90,6 +90,7 @@ public class CuratorDistributedLockTest extends 
DistributedLockTest {
    @Override
    public void tearDownEnv() throws Throwable {
       super.tearDownEnv();
+      testingServer.stop();
       testingServer.close();
    }
 


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information, visit: https://activemq.apache.org/contact


Reply via email to