turn cache off by default

git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@615297 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Robert Davies 2008-01-25 18:25:04 +00:00
parent b8674d4006
commit e16bcf2f48
1 changed files with 4 additions and 5 deletions

View File

@ -44,12 +44,11 @@ class QueueStorePrefetch extends AbstractPendingMessageCursor implements Message
private int size;
private boolean fillBatchDuplicates;
private boolean cacheEnabled;
private boolean useCache =false;
/**
* @param topic
* @param clientId
* @param subscriberName
* @throws IOException
* Construct it
* @param queue
*/
public QueueStorePrefetch(Queue queue) {
this.regionDestination = queue;
@ -60,7 +59,7 @@ class QueueStorePrefetch extends AbstractPendingMessageCursor implements Message
public synchronized void start() throws Exception{
if (!isStarted()) {
this.size = getStoreSize();
if (this.size==0) {
if (this.size==0&&useCache) {
cacheEnabled=true;
}
}