Stopping the persistence scheduler in MapDBPersistentStore when it is closed. Adding a test to make sure all threads get stopped when the broker is stopped.

This commit is contained in:
Victor Kazakov
2015-09-25 11:39:24 -07:00
parent 33bc23b4e1
commit a9404bdf31
2 changed files with 61 additions and 0 deletions
@@ -312,6 +312,8 @@ public class MapDBPersistentStore implements IMessagesStore, ISessionsStore {
LOG.debug("persisted subscriptions {}", m_persistentSubscriptions);
this.m_db.close();
LOG.debug("closed disk storage");
this.m_scheduler.shutdown();
LOG.debug("Persistence commit scheduler is shutdown");
}
/*-------- QoS 2 storage management --------------*/