activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gtu...@apache.org
Subject [1/2] activemq git commit: https://issues.apache.org/jira/browse/AMQ-6014 - topic store prefetch should take ownership like in the non persistent case - DurableSubscriberNonPersistentMessageTest regression
Date Mon, 23 Nov 2015 12:37:31 GMT
Repository: activemq
Updated Branches:
  refs/heads/master 3a3dcac18 -> 4318eba4a


https://issues.apache.org/jira/browse/AMQ-6014 - topic store prefetch should take ownership
like in the non persistent case - DurableSubscriberNonPersistentMessageTest regression


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

Branch: refs/heads/master
Commit: 4318eba4a34ad64b1dad549ba94dadd155149b4a
Parents: 48fbd31
Author: gtully <gary.tully@gmail.com>
Authored: Mon Nov 23 12:26:26 2015 +0000
Committer: gtully <gary.tully@gmail.com>
Committed: Mon Nov 23 12:27:03 2015 +0000

----------------------------------------------------------------------
 .../apache/activemq/broker/region/DurableTopicSubscription.java   | 3 ---
 .../apache/activemq/broker/region/cursors/TopicStorePrefetch.java | 1 +
 2 files changed, 1 insertion(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq/blob/4318eba4/activemq-broker/src/main/java/org/apache/activemq/broker/region/DurableTopicSubscription.java
----------------------------------------------------------------------
diff --git a/activemq-broker/src/main/java/org/apache/activemq/broker/region/DurableTopicSubscription.java
b/activemq-broker/src/main/java/org/apache/activemq/broker/region/DurableTopicSubscription.java
index 265a4a8..7c43662 100755
--- a/activemq-broker/src/main/java/org/apache/activemq/broker/region/DurableTopicSubscription.java
+++ b/activemq-broker/src/main/java/org/apache/activemq/broker/region/DurableTopicSubscription.java
@@ -228,9 +228,6 @@ public class DurableTopicSubscription extends PrefetchSubscription implements
Us
                     if (keepDurableSubsActive && pending.isTransient()) {
                         pending.addMessageFirst(node);
                         pending.rollback(node.getMessageId());
-                        // not sure why pending.addMessageFirst does not take ownership of
message reference
-                        // by incrementing
-                        node.incrementReferenceCount();
                     }
                     // createMessageDispatch increments on remove from pending for dispatch
                     node.decrementReferenceCount();

http://git-wip-us.apache.org/repos/asf/activemq/blob/4318eba4/activemq-broker/src/main/java/org/apache/activemq/broker/region/cursors/TopicStorePrefetch.java
----------------------------------------------------------------------
diff --git a/activemq-broker/src/main/java/org/apache/activemq/broker/region/cursors/TopicStorePrefetch.java
b/activemq-broker/src/main/java/org/apache/activemq/broker/region/cursors/TopicStorePrefetch.java
index c3f788f..35ec3ed 100755
--- a/activemq-broker/src/main/java/org/apache/activemq/broker/region/cursors/TopicStorePrefetch.java
+++ b/activemq-broker/src/main/java/org/apache/activemq/broker/region/cursors/TopicStorePrefetch.java
@@ -69,6 +69,7 @@ class TopicStorePrefetch extends AbstractStoreCursor {
     public synchronized void addMessageFirst(MessageReference node) throws Exception {
         batchList.addMessageFirst(node);
         size++;
+        node.incrementReferenceCount();
         //this.messageSize.addSize(node.getMessage().getSize());
     }
 


Mime
View raw message