activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gtu...@apache.org
Subject activemq git commit: https://issues.apache.org/jira/browse/AMQ-6083 - resolve some test regressions - AMQ2149Test - fail to start with missing data file. Ensure ack map is always saved on modification
Date Fri, 11 Dec 2015 13:31:26 GMT
Repository: activemq
Updated Branches:
  refs/heads/master 8609f74db -> 31d99b6aa


https://issues.apache.org/jira/browse/AMQ-6083 - resolve some test regressions - AMQ2149Test
- fail to start with missing data file. Ensure ack map is always saved on modification


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

Branch: refs/heads/master
Commit: 31d99b6aa92aed27acfd90a4d2a278c077a47a33
Parents: 8609f74
Author: gtully <gary.tully@gmail.com>
Authored: Fri Dec 11 13:30:55 2015 +0000
Committer: gtully <gary.tully@gmail.com>
Committed: Fri Dec 11 13:30:55 2015 +0000

----------------------------------------------------------------------
 .../java/org/apache/activemq/store/kahadb/MessageDatabase.java   | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq/blob/31d99b6a/activemq-kahadb-store/src/main/java/org/apache/activemq/store/kahadb/MessageDatabase.java
----------------------------------------------------------------------
diff --git a/activemq-kahadb-store/src/main/java/org/apache/activemq/store/kahadb/MessageDatabase.java
b/activemq-kahadb-store/src/main/java/org/apache/activemq/store/kahadb/MessageDatabase.java
index 2e17a69..6a98cce 100644
--- a/activemq-kahadb-store/src/main/java/org/apache/activemq/store/kahadb/MessageDatabase.java
+++ b/activemq-kahadb-store/src/main/java/org/apache/activemq/store/kahadb/MessageDatabase.java
@@ -1739,6 +1739,7 @@ public abstract class MessageDatabase extends ServiceSupport implements
BrokerSe
                 LOG.trace("gc candidates: " + gcCandidateSet);
                 LOG.trace("ackMessageFileMap: " +  metadata.ackMessageFileMap);
             }
+            boolean ackMessageFileMapMod = false;
             Iterator<Integer> candidates = gcCandidateSet.iterator();
             while (candidates.hasNext()) {
                 Integer candidate = candidates.next();
@@ -1752,7 +1753,7 @@ public abstract class MessageDatabase extends ServiceSupport implements
BrokerSe
                         }
                     }
                     if (gcCandidateSet.contains(candidate)) {
-                        metadata.ackMessageFileMap.remove(candidate);
+                        ackMessageFileMapMod |= (metadata.ackMessageFileMap.remove(candidate)
!= null);
                     } else {
                         if (LOG.isTraceEnabled()) {
                             LOG.trace("not removing data file: " + candidate
@@ -1767,7 +1768,6 @@ public abstract class MessageDatabase extends ServiceSupport implements
BrokerSe
                     LOG.debug("Cleanup removing the data files: " + gcCandidateSet);
                 }
                 journal.removeDataFiles(gcCandidateSet);
-                boolean ackMessageFileMapMod = false;
                 for (Integer candidate : gcCandidateSet) {
                     for (Set<Integer> ackFiles : metadata.ackMessageFileMap.values())
{
                         ackMessageFileMapMod |= ackFiles.remove(candidate);


Mime
View raw message