summaryrefslogtreecommitdiff
path: root/cpp/src/qpid/client/ConnectionImpl.h
diff options
context:
space:
mode:
authorAlan Conway <aconway@apache.org>2008-10-09 19:36:51 +0000
committerAlan Conway <aconway@apache.org>2008-10-09 19:36:51 +0000
commitd6901e52ab3ee9c40eddc4ad3b4787127c36d874 (patch)
tree85b9ba2e0d0922be150480392ec1b706a6df5cd0 /cpp/src/qpid/client/ConnectionImpl.h
parent016ae5acebab0eaf6dd70f5d4d653fdfee93925d (diff)
downloadqpid-python-d6901e52ab3ee9c40eddc4ad3b4787127c36d874.tar.gz
Client-side support for amq.faiover exchange. Connection::getKnownBrokers provides latest list.
git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@703237 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/client/ConnectionImpl.h')
-rw-r--r--cpp/src/qpid/client/ConnectionImpl.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/cpp/src/qpid/client/ConnectionImpl.h b/cpp/src/qpid/client/ConnectionImpl.h
index aca26b963d..22450a7ddf 100644
--- a/cpp/src/qpid/client/ConnectionImpl.h
+++ b/cpp/src/qpid/client/ConnectionImpl.h
@@ -24,6 +24,7 @@
#include "Bounds.h"
#include "ConnectionHandler.h"
+
#include "qpid/framing/FrameHandler.h"
#include "qpid/sys/Mutex.h"
#include "qpid/sys/ShutdownHandler.h"
@@ -41,6 +42,7 @@ namespace client {
class Connector;
class ConnectionSettings;
class SessionImpl;
+class FailoverListener;
class ConnectionImpl : public Bounds,
public framing::FrameHandler,
@@ -54,7 +56,9 @@ class ConnectionImpl : public Bounds,
SessionMap sessions;
ConnectionHandler handler;
boost::scoped_ptr<Connector> connector;
+ boost::scoped_ptr<FailoverListener> failover;
framing::ProtocolVersion version;
+ uint16_t nextChannel;
sys::Mutex lock;
template <class F> void closeInternal(const F&);
@@ -72,13 +76,18 @@ class ConnectionImpl : public Bounds,
void open();
bool isOpen() const;
- void addSession(const boost::shared_ptr<SessionImpl>&);
+ boost::shared_ptr<SessionImpl> newSession(const std::string& name, uint32_t timeout, uint16_t channel=0);
+ void addSession(const boost::shared_ptr<SessionImpl>&, uint16_t channel=0);
void close();
void handle(framing::AMQFrame& frame);
void erase(uint16_t channel);
-
+ void stopFailoverListener();
+
const ConnectionSettings& getNegotiatedSettings();
+
+ std::vector<Url> getKnownBrokers();
+
};
}}