Author: ataylor
Date: 2010-11-30 12:42:12 -0500 (Tue, 30 Nov 2010)
New Revision: 9954
Modified:
branches/2_2_0_HA_Improvements_preMerge/tests/src/org/hornetq/tests/integration/cluster/topology/TopologyClusterTestBase.java
Log:
added latch for nodes being removed
Modified:
branches/2_2_0_HA_Improvements_preMerge/tests/src/org/hornetq/tests/integration/cluster/topology/TopologyClusterTestBase.java
===================================================================
---
branches/2_2_0_HA_Improvements_preMerge/tests/src/org/hornetq/tests/integration/cluster/topology/TopologyClusterTestBase.java 2010-11-30
16:27:01 UTC (rev 9953)
+++
branches/2_2_0_HA_Improvements_preMerge/tests/src/org/hornetq/tests/integration/cluster/topology/TopologyClusterTestBase.java 2010-11-30
17:42:12 UTC (rev 9954)
@@ -414,6 +414,7 @@
final List<String> nodes = new ArrayList<String>();
final CountDownLatch upLatch = new CountDownLatch(5);
+ final CountDownLatch downLatch = new CountDownLatch(5);
locator.addClusterTopologyListener(new ClusterTopologyListener()
{
@@ -434,6 +435,7 @@
if (nodes.contains(nodeID))
{
nodes.remove(nodeID);
+ downLatch.countDown();
}
}
});
@@ -454,6 +456,8 @@
waitForClusterConnections(4, 4);
stopServers(0, 4, 2, 3, 1);
+
+ assertTrue("Was not notified that all servers are Down",
upLatch.await(10, SECONDS));
checkContains(new int[] { }, nodeIDs, nodes);
for (int i = 0; i < sfs.length; i++)
Show replies by date