Remove the need to check if the store is empty when checking to enable cache

git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@958330 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Robert Davies 2010-06-27 06:07:02 +00:00
parent dd48ebea00
commit d1b5029dc6
1 changed files with 1 additions and 1 deletions

View File

@ -208,7 +208,7 @@ public abstract class AbstractStoreCursor extends AbstractPendingMessageCursor i
if (last != null) { if (last != null) {
last.decrementReferenceCount(); last.decrementReferenceCount();
} }
if (size==0 && isStarted() && useCache && hasSpace() && isStoreEmpty()) { if (size==0 && isStarted() && useCache && hasSpace() ) {
if (LOG.isDebugEnabled()) { if (LOG.isDebugEnabled()) {
LOG.debug(regionDestination.getActiveMQDestination().getPhysicalName() + " enabling cache on last remove"); LOG.debug(regionDestination.getActiveMQDestination().getPhysicalName() + " enabling cache on last remove");
} }