Author: borges
Date: 2011-11-18 05:46:38 -0500 (Fri, 18 Nov 2011)
New Revision: 11707
Modified:
trunk/tests/integration-tests/src/test/java/org/hornetq/tests/integration/cluster/distribution/ClusterTestBase.java
trunk/tests/integration-tests/src/test/java/org/hornetq/tests/integration/cluster/failover/ClusterWithBackupFailoverTestBase.java
trunk/tests/integration-tests/src/test/java/org/hornetq/tests/integration/cluster/failover/MultipleLivesMultipleBackupsFailoverTest.java
Log:
Improve tearDown()
Modified:
trunk/tests/integration-tests/src/test/java/org/hornetq/tests/integration/cluster/distribution/ClusterTestBase.java
===================================================================
---
trunk/tests/integration-tests/src/test/java/org/hornetq/tests/integration/cluster/distribution/ClusterTestBase.java 2011-11-18
10:46:23 UTC (rev 11706)
+++
trunk/tests/integration-tests/src/test/java/org/hornetq/tests/integration/cluster/distribution/ClusterTestBase.java 2011-11-18
10:46:38 UTC (rev 11707)
@@ -243,6 +243,12 @@
}
}
}
+
+ @Override
+ public String toString()
+ {
+ return "id=" + id + ", consumer=" + consumer + ",
session=" + session;
+ }
}
protected ClientConsumer getConsumer(final int node)
Modified:
trunk/tests/integration-tests/src/test/java/org/hornetq/tests/integration/cluster/failover/ClusterWithBackupFailoverTestBase.java
===================================================================
---
trunk/tests/integration-tests/src/test/java/org/hornetq/tests/integration/cluster/failover/ClusterWithBackupFailoverTestBase.java 2011-11-18
10:46:23 UTC (rev 11706)
+++
trunk/tests/integration-tests/src/test/java/org/hornetq/tests/integration/cluster/failover/ClusterWithBackupFailoverTestBase.java 2011-11-18
10:46:38 UTC (rev 11707)
@@ -56,9 +56,6 @@
protected void setUp() throws Exception
{
super.setUp();
-
- //FailoverManagerImpl.enableDebug();
-
setupServers();
}
Modified:
trunk/tests/integration-tests/src/test/java/org/hornetq/tests/integration/cluster/failover/MultipleLivesMultipleBackupsFailoverTest.java
===================================================================
---
trunk/tests/integration-tests/src/test/java/org/hornetq/tests/integration/cluster/failover/MultipleLivesMultipleBackupsFailoverTest.java 2011-11-18
10:46:23 UTC (rev 11706)
+++
trunk/tests/integration-tests/src/test/java/org/hornetq/tests/integration/cluster/failover/MultipleLivesMultipleBackupsFailoverTest.java 2011-11-18
10:46:38 UTC (rev 11707)
@@ -35,6 +35,8 @@
public class MultipleLivesMultipleBackupsFailoverTest extends
MultipleBackupsFailoverTestBase
{
protected Map<Integer, TestableServer> servers = new HashMap<Integer,
TestableServer>();
+ private ServerLocator locator2;
+ private ServerLocator locator;
@Override
protected void tearDown() throws Exception
@@ -53,6 +55,8 @@
}
}
}
+ closeServerLocator(locator);
+ closeServerLocator(locator2);
super.tearDown();
}
@@ -72,20 +76,20 @@
servers.get(3).start();
waitForServer(servers.get(3).getServer());
-
+
servers.get(1).start();
waitForServer(servers.get(1).getServer());
servers.get(2).start();
-
+
servers.get(4).start();
waitForServer(servers.get(4).getServer());
-
+
servers.get(5).start();
waitForServer(servers.get(4).getServer());
- ServerLocator locator = getServerLocator(0);
+ locator = getServerLocator(0);
locator.setBlockOnNonDurableSend(true);
locator.setBlockOnDurableSend(true);
@@ -100,7 +104,7 @@
int liveAfter0 = waitForNewLive(10000, true, servers, 1, 2);
- ServerLocator locator2 = getServerLocator(3);
+ locator2 = getServerLocator(3);
locator2.setBlockOnNonDurableSend(true);
locator2.setBlockOnDurableSend(true);
locator2.setBlockOnAcknowledge(true);
@@ -249,6 +253,7 @@
new SameProcessHornetQServer(createInVMFailoverServer(true, config0,
nodeManager, liveNode)));
}
+ @Override
protected boolean isNetty()
{
return false;