diff --git a/activemq-core/src/main/java/org/apache/activemq/broker/region/Queue.java b/activemq-core/src/main/java/org/apache/activemq/broker/region/Queue.java index 7f39fafeaa..b0418dda75 100755 --- a/activemq-core/src/main/java/org/apache/activemq/broker/region/Queue.java +++ b/activemq-core/src/main/java/org/apache/activemq/broker/region/Queue.java @@ -276,10 +276,17 @@ public class Queue extends BaseDestination implements Task, UsageListener { messages.setMemoryUsageHighWaterMark(getCursorMemoryHighWaterMark()); if (messages.isRecoveryRequired()) { store.recover(new MessageRecoveryListener() { + double totalMessageCount = store.getMessageCount(); + int recoveredMessageCount = 0; public boolean recoverMessage(Message message) { // Message could have expired while it was being // loaded.. + if ((++recoveredMessageCount % 50000) == 0) { + LOG.info("cursor for " + getActiveMQDestination().getQualifiedName() + " has recovered " + + recoveredMessageCount + " messages. " + + (int)(recoveredMessageCount*100/totalMessageCount) + "% complete"); + } if (message.isExpired()) { if (broker.isExpired(message)) { messageExpired(createConnectionContext(), createMessageReference(message));