summaryrefslogtreecommitdiff
path: root/cpp/lib/broker/SessionHandlerImpl.h
diff options
context:
space:
mode:
authorGordon Sim <gsim@apache.org>2006-12-06 12:01:40 +0000
committerGordon Sim <gsim@apache.org>2006-12-06 12:01:40 +0000
commitc017c1cd768a88c7e74076b660be36902059528a (patch)
tree027de49a21a56ef7ac3952b7230028ec9c883b90 /cpp/lib/broker/SessionHandlerImpl.h
parent905c59a988010c9db7f64ee90f9d0b6e1011f0d0 (diff)
downloadqpid-python-c017c1cd768a88c7e74076b660be36902059528a.tar.gz
Added new configuration option for staging threshold (size above which messages
will be written to disk as content arrives rather than accumulating that content in memory). Pass this through to all channels and to the store on recovery. git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@483046 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/lib/broker/SessionHandlerImpl.h')
-rw-r--r--cpp/lib/broker/SessionHandlerImpl.h12
1 files changed, 10 insertions, 2 deletions
diff --git a/cpp/lib/broker/SessionHandlerImpl.h b/cpp/lib/broker/SessionHandlerImpl.h
index 4b89dbeaa1..98c87a7806 100644
--- a/cpp/lib/broker/SessionHandlerImpl.h
+++ b/cpp/lib/broker/SessionHandlerImpl.h
@@ -60,6 +60,14 @@ struct ConnectionException : public std::exception {
const char* what() const throw() { return text.c_str(); }
};
+class Settings {
+public:
+ const u_int32_t timeout;//timeout for auto-deleted queues (in ms)
+ const u_int64_t stagingThreshold;
+
+ Settings(u_int32_t _timeout, u_int64_t _stagingThreshold) : timeout(_timeout), stagingThreshold(_stagingThreshold) {}
+};
+
class SessionHandlerImpl : public virtual qpid::sys::SessionHandler,
public virtual qpid::framing::AMQP_ServerOperations,
public virtual ConnectionToken
@@ -72,7 +80,7 @@ class SessionHandlerImpl : public virtual qpid::sys::SessionHandler,
QueueRegistry* queues;
ExchangeRegistry* const exchanges;
AutoDelete* const cleaner;
- const u_int32_t timeout;//timeout for auto-deleted queues (in ms)
+ const Settings settings;
std::auto_ptr<BasicHandler> basicHandler;
std::auto_ptr<ChannelHandler> channelHandler;
@@ -104,7 +112,7 @@ class SessionHandlerImpl : public virtual qpid::sys::SessionHandler,
public:
SessionHandlerImpl(qpid::sys::SessionContext* context, QueueRegistry* queues,
- ExchangeRegistry* exchanges, AutoDelete* cleaner, const u_int32_t timeout);
+ ExchangeRegistry* exchanges, AutoDelete* cleaner, const Settings& settings);
virtual void received(qpid::framing::AMQFrame* frame);
virtual void initiated(qpid::framing::ProtocolInitiation* header);
virtual void idleOut();