mirror of https://github.com/apache/activemq.git
Properly nulling out the scheduler service in MessageDatabase after it
is shutdown on a store close so that if the store is restarted the
thread will properly restart.
(cherry picked from commit 7bdcca1bda
)
This commit is contained in:
parent
6abf89f0a5
commit
cd68c42b90
|
@ -469,7 +469,12 @@ public abstract class MessageDatabase extends ServiceSupport implements BrokerSe
|
||||||
checkpointLock.writeLock().unlock();
|
checkpointLock.writeLock().unlock();
|
||||||
}
|
}
|
||||||
journal.close();
|
journal.close();
|
||||||
|
synchronized(schedulerLock) {
|
||||||
|
if (scheduler != null) {
|
||||||
ThreadPoolUtils.shutdownGraceful(scheduler, -1);
|
ThreadPoolUtils.shutdownGraceful(scheduler, -1);
|
||||||
|
scheduler = null;
|
||||||
|
}
|
||||||
|
}
|
||||||
// clear the cache and journalSize on shutdown of the store
|
// clear the cache and journalSize on shutdown of the store
|
||||||
storeCache.clear();
|
storeCache.clear();
|
||||||
journalSize.set(0);
|
journalSize.set(0);
|
||||||
|
|
Loading…
Reference in New Issue