HBASE-25016 addendum: should also close the Table which is returned by calling getMetaHTable
Closes #2393 Signed-off-by: Viraj Jasani <vjasani@apache.org>
This commit is contained in:
parent
67233dcb42
commit
79eee6affc
|
@ -365,7 +365,8 @@ public class MetaTableAccessor {
|
|||
new SubstringComparator(regionEncodedName));
|
||||
Scan scan = getMetaScan(connection, 1);
|
||||
scan.setFilter(rowFilter);
|
||||
try (ResultScanner resultScanner = getMetaHTable(connection).getScanner(scan)) {
|
||||
try (Table table = getMetaHTable(connection);
|
||||
ResultScanner resultScanner = table.getScanner(scan)) {
|
||||
return resultScanner.next();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue