Author: aconway
Date: Fri Oct 19 20:00:55 2012
New Revision: 1400258

URL: http://svn.apache.org/viewvc?rev=1400258&view=rev
Log:
Bug 868360 - QPID-4379: HA does not properly handle expired messages.

The trunk is not affected by this bug, so this commit is just to add the
regression test that proves it.

Modified:
    qpid/trunk/qpid/cpp/src/tests/ha_tests.py

Modified: qpid/trunk/qpid/cpp/src/tests/ha_tests.py
URL: 
http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/tests/ha_tests.py?rev=1400258&r1=1400257&r2=1400258&view=diff
==============================================================================
--- qpid/trunk/qpid/cpp/src/tests/ha_tests.py (original)
+++ qpid/trunk/qpid/cpp/src/tests/ha_tests.py Fri Oct 19 20:00:55 2012
@@ -745,6 +745,7 @@ acl deny all all
         cluster[1].wait_queue("q")    # Not timed out yet
         cluster[1].wait_no_queue("q") # Wait for timeout
 
+<<<<<<< HEAD
     def test_alt_exchange_dup(self):
         """QPID-4349: if a queue has an alterante exchange and is deleted the
         messages appear twice on the alternate, they are rerouted once by the
@@ -763,6 +764,20 @@ acl deny all all
         s.sender("q;{delete:always}").close()
         cluster[1].assert_browse_backup("altq", messages)
 
+||||||| parent of c584515... Bug 868360 - QPID-4379: HA does not properly 
handle expired messages.
+=======
+    def test_expired(self):
+        """Regression test for QPID-4379: HA does not properly handle expired 
messages"""
+        # Race between messages expiring and HA replicating consumer.
+        cluster = HaCluster(self, 2)
+        s = cluster[0].connect().session().sender("q;{create:always}", 
capacity=2)
+        def send_ttl_messages():
+            for i in xrange(100): s.send(Message(str(i), ttl=0.001), timeout=1)
+        send_ttl_messages()
+        cluster.start()
+        send_ttl_messages()
+
+>>>>>>> c584515... Bug 868360 - QPID-4379: HA does not properly handle expired 
messages.
 def fairshare(msgs, limit, levels):
     """
     Generator to return prioritised messages in expected order for a given 
fairshare limit



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to