Skip to content

Commit

Permalink
HBASE-25166 MobFileCompactionChore is closing the master's shared clu…
Browse files Browse the repository at this point in the history
…ster connection (apache#2514) (apache#4826)

Co-authored-by: Ankit Singhal <ankit@apache.org>
Signed-off-by: Xiaolin Ha <haxiaolin@apache.org>
(cherry picked from commit 66873ca)
  • Loading branch information
binlijin authored and charlesconnell committed Oct 17, 2022
1 parent 5e67c2c commit aa609d7
Showing 1 changed file with 1 addition and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@
import org.apache.hadoop.hbase.client.Admin;
import org.apache.hadoop.hbase.client.ColumnFamilyDescriptor;
import org.apache.hadoop.hbase.client.CompactionState;
import org.apache.hadoop.hbase.client.Connection;
import org.apache.hadoop.hbase.client.RegionInfo;
import org.apache.hadoop.hbase.client.TableDescriptor;
import org.apache.hadoop.hbase.client.TableState;
Expand Down Expand Up @@ -81,8 +80,7 @@ protected void chore() {

boolean reported = false;

try (Connection conn = master.getConnection(); Admin admin = conn.getAdmin();) {

try (Admin admin = master.getConnection().getAdmin()) {
TableDescriptors htds = master.getTableDescriptors();
Map<String, TableDescriptor> map = htds.getAll();
for (TableDescriptor htd : map.values()) {
Expand Down

0 comments on commit aa609d7

Please sign in to comment.