summaryrefslogtreecommitdiff
path: root/cpp/src/qpid/broker/MessageStore.h
diff options
context:
space:
mode:
authorCarl C. Trieloff <cctrieloff@apache.org>2007-10-19 01:33:24 +0000
committerCarl C. Trieloff <cctrieloff@apache.org>2007-10-19 01:33:24 +0000
commitbfcdddb9af408b62ae4d2689611be8763df45e0c (patch)
tree8c1c57dab5138134f66090d1fe8b1c13ffa9a0e3 /cpp/src/qpid/broker/MessageStore.h
parent442a703034b4b08ac3ccc167db915356d796272b (diff)
downloadqpid-python-bfcdddb9af408b62ae4d2689611be8763df45e0c.tar.gz
- added init for dir and async options for store
- added flush for queue for async processing git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@586207 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/broker/MessageStore.h')
-rw-r--r--cpp/src/qpid/broker/MessageStore.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/cpp/src/qpid/broker/MessageStore.h b/cpp/src/qpid/broker/MessageStore.h
index 6bd661954f..c8b243ef28 100644
--- a/cpp/src/qpid/broker/MessageStore.h
+++ b/cpp/src/qpid/broker/MessageStore.h
@@ -37,6 +37,16 @@ namespace broker {
*/
class MessageStore : public TransactionalStore, public Recoverable {
public:
+
+ /**
+ * init the store, call before any other call. If not called, store
+ * is free to pick any defaults
+ *
+ * @param dir the directory to create logs/db's
+ * @param async true, enable async, false, enable sync
+ */
+ virtual void init(const std::string& dir, const bool async) = 0;
+
/**
* Record the existence of a durable queue
*/
@@ -133,6 +143,15 @@ public:
*/
virtual void dequeue(TransactionContext* ctxt, PersistableMessage& msg, const PersistableQueue& queue) = 0;
+ /**
+ * Flushes all async messages to disk for the specified queue
+ *
+ * Note: that this is async so the return of the function does
+ * not mean the opperation is complete.
+ *
+ * @param queue the name of the queue from which it is to be dequeued
+ */
+ virtual void flush(const qpid::broker::PersistableQueue& queue)=0;
/**
* Returns the number of outstanding AIO's for a given queue