HBASE-4167 Potential leak of HTable instances when using HTablePool with
PoolType.ThreadLocal (Karthick Sankarachary) git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1160437 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
ecd5fcf0d4
commit
d0de098625
|
@ -206,6 +206,8 @@ Release 0.91.0 - Unreleased
|
|||
HBASE-4008 Problem while stopping HBase (Akash Ashok)
|
||||
HBASE-4065 TableOutputFormat ignores failure to create table instance
|
||||
(Brock Noland)
|
||||
HBASE-4167 Potential leak of HTable instances when using HTablePool with
|
||||
PoolType.ThreadLocal (Karthick Sankarachary)
|
||||
|
||||
IMPROVEMENTS
|
||||
HBASE-3290 Max Compaction Size (Nicolas Spiegelberg via Stack)
|
||||
|
|
|
@ -259,6 +259,7 @@ public class HTablePool implements Closeable {
|
|||
String tableName = Bytes.toString(table.getTableName());
|
||||
if (tables.size(tableName) >= maxSize) {
|
||||
// release table instance since we're not reusing it
|
||||
this.tables.remove(tableName, table);
|
||||
this.tableFactory.releaseHTableInterface(table);
|
||||
return;
|
||||
}
|
||||
|
@ -309,6 +310,7 @@ public class HTablePool implements Closeable {
|
|||
for (String tableName : tables.keySet()) {
|
||||
closeTablePool(tableName);
|
||||
}
|
||||
this.tables.clear();
|
||||
}
|
||||
|
||||
int getCurrentPoolSize(String tableName) {
|
||||
|
|
Loading…
Reference in New Issue