summaryrefslogtreecommitdiff
path: root/cpp/src/qpid/cluster/UpdateClient.cpp
diff options
context:
space:
mode:
authorAlan Conway <aconway@apache.org>2009-04-06 14:55:57 +0000
committerAlan Conway <aconway@apache.org>2009-04-06 14:55:57 +0000
commitcfb5d33487829f2b63e3fa08c3ba0c41b526158c (patch)
tree8b6c283d271cda76dbb700c10a246f9834f46ec7 /cpp/src/qpid/cluster/UpdateClient.cpp
parent557e3ceb4cec0bbbfb62700afdf0f3c96aeb64f5 (diff)
downloadqpid-python-cfb5d33487829f2b63e3fa08c3ba0c41b526158c.tar.gz
Cluster: fix exception handling if updater fails to connect to updatee.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@762370 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/cluster/UpdateClient.cpp')
-rw-r--r--cpp/src/qpid/cluster/UpdateClient.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/cpp/src/qpid/cluster/UpdateClient.cpp b/cpp/src/qpid/cluster/UpdateClient.cpp
index 97eae7efa3..c00b811a20 100644
--- a/cpp/src/qpid/cluster/UpdateClient.cpp
+++ b/cpp/src/qpid/cluster/UpdateClient.cpp
@@ -98,10 +98,7 @@ UpdateClient::UpdateClient(const MemberId& updater, const MemberId& updatee, con
expiry(expiry_), connections(cons), decoder(decoder_),
connection(catchUpConnection()), shadowConnection(catchUpConnection()),
done(ok), failed(fail), connectionSettings(cs)
-{
- connection.open(url, cs);
- session = connection.newSession(UPDATE);
-}
+{}
UpdateClient::~UpdateClient() {}
@@ -110,6 +107,8 @@ const std::string UpdateClient::UPDATE("qpid.cluster-update");
void UpdateClient::run() {
try {
+ connection.open(updateeUrl, connectionSettings);
+ session = connection.newSession(UPDATE);
update();
done();
} catch (const std::exception& e) {