From 9c8302099de20be264d1bf357b6bceb963ada021 Mon Sep 17 00:00:00 2001 From: Alan Conway Date: Tue, 8 Jun 2010 15:31:31 +0000 Subject: Cluster handle connection-negotiation phase in local broker. The connection negotiation phase up to the "open" or "open-ok" frame establishes whether/what encryption to use for the rest of the connection. With this patch a cluster broker completes the initial negotiation with its local clients and only then begins multicasting to other brokers. The local broker decrypts if necessary and multicasts in the clear. This replaces a problematic locking scheme that was formerly in place which caused deadlocks. git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@952692 13f79535-47bb-0310-9956-ffa450edef68 --- cpp/src/tests/cluster_test.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'cpp/src/tests/cluster_test.cpp') diff --git a/cpp/src/tests/cluster_test.cpp b/cpp/src/tests/cluster_test.cpp index d5f2c457e5..0565ecc34c 100644 --- a/cpp/src/tests/cluster_test.cpp +++ b/cpp/src/tests/cluster_test.cpp @@ -510,7 +510,7 @@ QPID_AUTO_TEST_CASE(testUpdateMessageBuilder) { Client c1(cluster[1], "c1"); BOOST_CHECK(c1.subs.get(m, "q", TIMEOUT)); BOOST_CHECK_EQUAL(m.getData(), "abcd"); - BOOST_CHECK_EQUAL(2u, knownBrokerPorts(c1.connection).size()); + BOOST_CHECK_EQUAL(2u, knownBrokerPorts(c1.connection, 2).size()); } QPID_AUTO_TEST_CASE(testConnectionKnownHosts) { @@ -518,13 +518,13 @@ QPID_AUTO_TEST_CASE(testConnectionKnownHosts) { prepareArgs(args, durableFlag); ClusterFixture cluster(1, args, -1); Client c0(cluster[0], "c0"); - set kb0 = knownBrokerPorts(c0.connection); + set kb0 = knownBrokerPorts(c0.connection, 1); BOOST_CHECK_EQUAL(kb0.size(), 1u); BOOST_CHECK_EQUAL(kb0, makeSet(cluster)); cluster.add(); Client c1(cluster[1], "c1"); - set kb1 = knownBrokerPorts(c1.connection); + set kb1 = knownBrokerPorts(c1.connection, 2); kb0 = knownBrokerPorts(c0.connection, 2); BOOST_CHECK_EQUAL(kb1.size(), 2u); BOOST_CHECK_EQUAL(kb1, makeSet(cluster)); @@ -532,7 +532,7 @@ QPID_AUTO_TEST_CASE(testConnectionKnownHosts) { cluster.add(); Client c2(cluster[2], "c2"); - set kb2 = knownBrokerPorts(c2.connection); + set kb2 = knownBrokerPorts(c2.connection, 3); kb1 = knownBrokerPorts(c1.connection, 3); kb0 = knownBrokerPorts(c0.connection, 3); BOOST_CHECK_EQUAL(kb2.size(), 3u); -- cgit v1.2.1