summaryrefslogtreecommitdiff
path: root/src/main
diff options
context:
space:
mode:
Diffstat (limited to 'src/main')
-rw-r--r--src/main/java/com/amazon/carbonado/spi/AbstractRepository.java2
-rw-r--r--src/main/java/com/amazon/carbonado/util/AbstractPool.java4
2 files changed, 6 insertions, 0 deletions
diff --git a/src/main/java/com/amazon/carbonado/spi/AbstractRepository.java b/src/main/java/com/amazon/carbonado/spi/AbstractRepository.java
index c37f2c4..8a9a0cc 100644
--- a/src/main/java/com/amazon/carbonado/spi/AbstractRepository.java
+++ b/src/main/java/com/amazon/carbonado/spi/AbstractRepository.java
@@ -321,6 +321,8 @@ public abstract class AbstractRepository<Txn>
doShutdown(repository, suspendThreads);
} finally {
repository.mHasShutdown = true;
+ repository.mStoragePool.clear();
+ repository.mSequencePool.clear();
mRepository.clear();
repository.info("Closed repository \"" + repository.getName() + '"');
}
diff --git a/src/main/java/com/amazon/carbonado/util/AbstractPool.java b/src/main/java/com/amazon/carbonado/util/AbstractPool.java
index e14c387..d8bcc4e 100644
--- a/src/main/java/com/amazon/carbonado/util/AbstractPool.java
+++ b/src/main/java/com/amazon/carbonado/util/AbstractPool.java
@@ -88,6 +88,10 @@ public abstract class AbstractPool<K, V, E extends Exception> {
return mValues.values();
}
+ public void clear() {
+ mValues.clear();
+ }
+
/**
* Return a new value instance.
*/