qpid-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kp...@apache.org
Subject svn commit: r891362 - in /qpid/trunk/qpid/cpp/src/qpid/broker: RecoverableMessage.h RecoveryManagerImpl.cpp
Date Wed, 16 Dec 2009 18:22:11 GMT
Author: kpvdr
Date: Wed Dec 16 18:22:11 2009
New Revision: 891362

URL: http://svn.apache.org/viewvc?rev=891362&view=rev
Log:
Added methods to set the message redelivered flag upon recovery

Modified:
    qpid/trunk/qpid/cpp/src/qpid/broker/RecoverableMessage.h
    qpid/trunk/qpid/cpp/src/qpid/broker/RecoveryManagerImpl.cpp

Modified: qpid/trunk/qpid/cpp/src/qpid/broker/RecoverableMessage.h
URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/qpid/broker/RecoverableMessage.h?rev=891362&r1=891361&r2=891362&view=diff
==============================================================================
--- qpid/trunk/qpid/cpp/src/qpid/broker/RecoverableMessage.h (original)
+++ qpid/trunk/qpid/cpp/src/qpid/broker/RecoverableMessage.h Wed Dec 16 18:22:11 2009
@@ -37,6 +37,7 @@
 public:
     typedef boost::shared_ptr<RecoverableMessage> shared_ptr;
     virtual void setPersistenceId(uint64_t id) = 0;
+    virtual void setRedelivered() = 0;
     /**
      * Used by store to determine whether to load content on recovery
      * or let message load its own content as and when it requires it.

Modified: qpid/trunk/qpid/cpp/src/qpid/broker/RecoveryManagerImpl.cpp
URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/qpid/broker/RecoveryManagerImpl.cpp?rev=891362&r1=891361&r2=891362&view=diff
==============================================================================
--- qpid/trunk/qpid/cpp/src/qpid/broker/RecoveryManagerImpl.cpp (original)
+++ qpid/trunk/qpid/cpp/src/qpid/broker/RecoveryManagerImpl.cpp Wed Dec 16 18:22:11 2009
@@ -48,6 +48,7 @@
     RecoverableMessageImpl(const intrusive_ptr<Message>& _msg, uint64_t _stagingThreshold);

     ~RecoverableMessageImpl() {};
     void setPersistenceId(uint64_t id);
+    void setRedelivered();
     bool loadContent(uint64_t available);
     void decodeContent(framing::Buffer& buffer);
     void recover(Queue::shared_ptr queue);
@@ -187,6 +188,11 @@
     msg->setPersistenceId(id);
 }
 
+void RecoverableMessageImpl::setRedelivered()
+{
+    msg->redeliver();
+}
+
 void RecoverableQueueImpl::recover(RecoverableMessage::shared_ptr msg)
 {
     dynamic_pointer_cast<RecoverableMessageImpl>(msg)->recover(queue);



---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:commits-subscribe@qpid.apache.org


Mime
View raw message