diff options
author | Alan Conway <aconway@apache.org> | 2012-10-05 18:21:45 +0000 |
---|---|---|
committer | Alan Conway <aconway@apache.org> | 2012-10-05 18:21:45 +0000 |
commit | 3a0d4cd17abf3a39a8e5103cb0d9b5b4fd3bb55e (patch) | |
tree | 075cdd787c0a260c7b57b74bfeaea69e979035aa /cpp/src/qpid/client/ConnectionHandler.cpp | |
parent | 67d03ede53fa2ad521bf4769a0fd8cc39e7d38f2 (diff) | |
download | qpid-python-3a0d4cd17abf3a39a8e5103cb0d9b5b4fd3bb55e.tar.gz |
QPID-4360: Non-ready HA broker can be incorrectly promoted to primary
A joining broker now attempts to contact all known members of the cluster and
check their status. If any brokers are in a state other than "joining" the
broker will refuse to promote. This will allow rgmanager to continue to try
addresses till it finds a ready brokers.
Note this reqiures ha-brokers-url to be a list of all known brokers, not a
virtual IP. ha-public-url can still be a VIP.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1394706 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/client/ConnectionHandler.cpp')
-rw-r--r-- | cpp/src/qpid/client/ConnectionHandler.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/cpp/src/qpid/client/ConnectionHandler.cpp b/cpp/src/qpid/client/ConnectionHandler.cpp index 91838d8e8b..4f88cb97ee 100644 --- a/cpp/src/qpid/client/ConnectionHandler.cpp +++ b/cpp/src/qpid/client/ConnectionHandler.cpp @@ -82,9 +82,11 @@ void ConnectionHandler::Adapter::handle(qpid::framing::AMQFrame& f) handler.out(f); } -ConnectionHandler::ConnectionHandler(const ConnectionSettings& s, ProtocolVersion& v, Bounds& b) - : StateManager(NOT_STARTED), ConnectionSettings(s), outHandler(*this, b), proxy(outHandler), - errorCode(CLOSE_CODE_NORMAL), version(v) +ConnectionHandler::ConnectionHandler( + const ConnectionSettings& s, ProtocolVersion& v, Bounds& b) + : StateManager(NOT_STARTED), ConnectionSettings(s), + outHandler(*this, b), proxy(outHandler), errorCode(CLOSE_CODE_NORMAL), version(v), + properties(s.clientProperties) { insist = true; |