From dd321c4a356a917901025bd916abdf60a83d1560 Mon Sep 17 00:00:00 2001 From: tedyu Date: Thu, 4 May 2017 08:28:02 -0700 Subject: [PATCH] HBASE-17991 Add more details about compaction queue on /dump (Guangxu Cheng) --- .../apache/hadoop/hbase/regionserver/CompactSplitThread.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/CompactSplitThread.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/CompactSplitThread.java index 6f95a098c7e..71a8803a98b 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/CompactSplitThread.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/CompactSplitThread.java @@ -460,6 +460,7 @@ public class CompactSplitThread implements CompactionRequestor, PropagatingConfi private int queuedPriority; private ThreadPoolExecutor parent; private User user; + private long time; public CompactionRunner(Store store, Region region, CompactionContext compaction, ThreadPoolExecutor parent, User user) { @@ -471,12 +472,14 @@ public class CompactSplitThread implements CompactionRequestor, PropagatingConfi ? store.getCompactPriority() : compaction.getRequest().getPriority(); this.parent = parent; this.user = user; + this.time = System.currentTimeMillis(); } @Override public String toString() { return (this.compaction != null) ? ("Request = " + compaction.getRequest()) - : ("Store = " + store.toString() + ", pri = " + queuedPriority); + : ("regionName = " + region.toString() + ", storeName = " + store.toString() + + ", priority = " + queuedPriority + ", time = " + time); } private void doCompaction(User user) {