diff --git a/activemq-kahadb-store/src/main/java/org/apache/activemq/store/kahadb/KahaDBStore.java b/activemq-kahadb-store/src/main/java/org/apache/activemq/store/kahadb/KahaDBStore.java index cc65bf6e20..5a723c9acc 100644 --- a/activemq-kahadb-store/src/main/java/org/apache/activemq/store/kahadb/KahaDBStore.java +++ b/activemq-kahadb-store/src/main/java/org/apache/activemq/store/kahadb/KahaDBStore.java @@ -936,17 +936,17 @@ public class KahaDBStore extends MessageDatabase implements PersistenceAdapter, } else { indexLock.writeLock().lock(); try { - return pageFile.tx().execute(new Transaction.CallableClosure() { + return pageFile.tx().execute(new Transaction.CallableClosure() { @Override - public Integer execute(Transaction tx) throws IOException { + public Long execute(Transaction tx) throws IOException { StoredDestination sd = getStoredDestination(dest, tx); LastAck cursorPos = getLastAck(tx, sd, subscriptionKey); if (cursorPos == null) { // The subscription might not exist. - return 0; + return 0l; } - return (int) getStoredMessageSize(tx, sd, subscriptionKey); + return getStoredMessageSize(tx, sd, subscriptionKey); } }); } finally { @@ -955,7 +955,6 @@ public class KahaDBStore extends MessageDatabase implements PersistenceAdapter, } } - protected void recoverMessageStoreSubMetrics() throws IOException { if (isEnableSubscriptionStatistics()) {