summaryrefslogtreecommitdiff
path: root/cpp/src/qpid/broker/QueueFactory.cpp
diff options
context:
space:
mode:
authorGordon Sim <gsim@apache.org>2013-07-13 09:15:49 +0000
committerGordon Sim <gsim@apache.org>2013-07-13 09:15:49 +0000
commit6213eb2304bb3d9209f29d2573514b9c11f3ab91 (patch)
treed77d38a64bccaac2cb7e12796f2e30c8696599e5 /cpp/src/qpid/broker/QueueFactory.cpp
parentbd0b54fbd4d007e3da6f9fc9284ce3fedd27d98b (diff)
downloadqpid-python-6213eb2304bb3d9209f29d2573514b9c11f3ab91.tar.gz
QPID-3247: add policy for self-struct subscription queue
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1502766 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/broker/QueueFactory.cpp')
-rw-r--r--cpp/src/qpid/broker/QueueFactory.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/cpp/src/qpid/broker/QueueFactory.cpp b/cpp/src/qpid/broker/QueueFactory.cpp
index 67499c9985..807026ef0d 100644
--- a/cpp/src/qpid/broker/QueueFactory.cpp
+++ b/cpp/src/qpid/broker/QueueFactory.cpp
@@ -33,6 +33,7 @@
#include "qpid/broker/PagedQueue.h"
#include "qpid/broker/PriorityQueue.h"
#include "qpid/broker/QueueFlowLimit.h"
+#include "qpid/broker/SelfDestructQueue.h"
#include "qpid/broker/ThresholdAlerts.h"
#include "qpid/broker/FifoDistributor.h"
#include "qpid/log/Statement.h"
@@ -53,6 +54,8 @@ boost::shared_ptr<Queue> QueueFactory::create(const std::string& name, const Que
boost::shared_ptr<Queue> queue;
if (settings.dropMessagesAtLimit) {
queue = boost::shared_ptr<Queue>(new LossyQueue(name, settings, settings.durable ? store : 0, parent, broker));
+ } else if (settings.selfDestructAtLimit) {
+ queue = boost::shared_ptr<Queue>(new SelfDestructQueue(name, settings, settings.durable ? store : 0, parent, broker));
} else if (settings.lvqKey.size()) {
std::auto_ptr<MessageMap> map(new MessageMap(settings.lvqKey));
queue = boost::shared_ptr<Queue>(new Lvq(name, map, settings, settings.durable ? store : 0, parent, broker));