Repository: activemq
Updated Branches:
  refs/heads/trunk 80a4fb7cb -> bc3587cfc


more realistic test with short lived groups rather than single entry


Project: http://git-wip-us.apache.org/repos/asf/activemq/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq/commit/919099b4
Tree: http://git-wip-us.apache.org/repos/asf/activemq/tree/919099b4
Diff: http://git-wip-us.apache.org/repos/asf/activemq/diff/919099b4

Branch: refs/heads/trunk
Commit: 919099b419c2d2e355883c6d01df6a9854735d6d
Parents: db65c2e
Author: gtully <gary.tu...@gmail.com>
Authored: Mon Dec 8 13:57:32 2014 +0000
Committer: gtully <gary.tu...@gmail.com>
Committed: Mon Dec 8 14:00:42 2014 +0000

----------------------------------------------------------------------
 .../usecases/MessageGroupReconnectDistributionTest.java       | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq/blob/919099b4/activemq-unit-tests/src/test/java/org/apache/activemq/usecases/MessageGroupReconnectDistributionTest.java
----------------------------------------------------------------------
diff --git 
a/activemq-unit-tests/src/test/java/org/apache/activemq/usecases/MessageGroupReconnectDistributionTest.java
 
b/activemq-unit-tests/src/test/java/org/apache/activemq/usecases/MessageGroupReconnectDistributionTest.java
index 660b568..1fd7e07 100644
--- 
a/activemq-unit-tests/src/test/java/org/apache/activemq/usecases/MessageGroupReconnectDistributionTest.java
+++ 
b/activemq-unit-tests/src/test/java/org/apache/activemq/usecases/MessageGroupReconnectDistributionTest.java
@@ -177,9 +177,14 @@ public class MessageGroupReconnectDistributionTest {
     }
 
     private void produceMessages(int numMessages) throws JMSException {
+        int groupID=0;
         for (int i = 0; i < numMessages; i++) {
+            // groups of 10
+            if (i>0 && i%10==0) {
+                groupID++;
+            }
             TextMessage msga = session.createTextMessage("hello " + i);
-            msga.setStringProperty("JMSXGroupID", msga.getText());
+            msga.setStringProperty("JMSXGroupID", "Group-"+groupID);
             producer.send(msga);
         }
     }

Reply via email to