activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tab...@apache.org
Subject svn commit: r1437691 - /activemq/trunk/activemq-core/src/test/java/org/apache/activemq/usecases/DurableSubscriptionOfflineTest.java
Date Wed, 23 Jan 2013 20:09:44 GMT
Author: tabish
Date: Wed Jan 23 20:09:43 2013
New Revision: 1437691

URL: http://svn.apache.org/viewvc?rev=1437691&view=rev
Log:
Add one fix from: https://issues.apache.org/jira/browse/AMQ-4268

need to ensure at least one consumer cycle to ensure the redelivery flag is set. 

Modified:
    activemq/trunk/activemq-core/src/test/java/org/apache/activemq/usecases/DurableSubscriptionOfflineTest.java

Modified: activemq/trunk/activemq-core/src/test/java/org/apache/activemq/usecases/DurableSubscriptionOfflineTest.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/usecases/DurableSubscriptionOfflineTest.java?rev=1437691&r1=1437690&r2=1437691&view=diff
==============================================================================
--- activemq/trunk/activemq-core/src/test/java/org/apache/activemq/usecases/DurableSubscriptionOfflineTest.java
(original)
+++ activemq/trunk/activemq-core/src/test/java/org/apache/activemq/usecases/DurableSubscriptionOfflineTest.java
Wed Jan 23 20:09:43 2013
@@ -1558,7 +1558,6 @@ public class DurableSubscriptionOfflineT
         }
     }
 
-
     public void testRedeliveryFlag() throws Exception {
 
         Connection con;
@@ -1625,7 +1624,7 @@ public class DurableSubscriptionOfflineT
                     con.close();
 
                     // peek all
-                    for (int j = 0; j < random.nextInt(10); j++) {
+                    for (int j = -1; j < random.nextInt(10); j++) {
                         con = createConnection(clientId);
                         session = con.createSession(false, Session.CLIENT_ACKNOWLEDGE);
                         consumer = session.createDurableSubscriber(topic, "SubsId", "filter
= 'true'", true);
@@ -1638,7 +1637,6 @@ public class DurableSubscriptionOfflineT
                         con.close();
                     }
 
-
                     // consume remaining
                     con = createConnection(clientId);
                     session = con.createSession(false, Session.CLIENT_ACKNOWLEDGE);



Mime
View raw message