You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by bi...@apache.org on 2022/10/13 14:06:47 UTC
[hbase] branch branch-2 updated: HBASE-25166 MobFileCompactionChore is closing the master's shared cluster connection (#2514) (#4825)
This is an automated email from the ASF dual-hosted git repository.
binlijin pushed a commit to branch branch-2
in repository https://gitbox.apache.org/repos/asf/hbase.git
The following commit(s) were added to refs/heads/branch-2 by this push:
new 861938fe267 HBASE-25166 MobFileCompactionChore is closing the master's shared cluster connection (#2514) (#4825)
861938fe267 is described below
commit 861938fe267f2f96b90753ecbb31056cb4fe8eec
Author: binlijin <bi...@gmail.com>
AuthorDate: Thu Oct 13 22:06:35 2022 +0800
HBASE-25166 MobFileCompactionChore is closing the master's shared cluster connection (#2514) (#4825)
Co-authored-by: Ankit Singhal <an...@apache.org>
Signed-off-by: Xiaolin Ha <ha...@apache.org>
---
.../main/java/org/apache/hadoop/hbase/mob/MobFileCompactionChore.java | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/mob/MobFileCompactionChore.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/mob/MobFileCompactionChore.java
index 852186a6f98..385b77e0107 100644
--- a/hbase-server/src/main/java/org/apache/hadoop/hbase/mob/MobFileCompactionChore.java
+++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/mob/MobFileCompactionChore.java
@@ -31,7 +31,6 @@ import org.apache.hadoop.hbase.TableName;
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;
@@ -81,8 +80,7 @@ public class MobFileCompactionChore extends ScheduledChore {
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()) {