From 8c24e585e18cbb3e4879337258effeecbe56c6e1 Mon Sep 17 00:00:00 2001 From: mbertozzi Date: Tue, 18 Feb 2014 15:00:15 +0000 Subject: [PATCH] HBASE-10563 Set name for FlushHandler thread (Himanshu Vashishtha) git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1569370 13f79535-47bb-0310-9956-ffa450edef68 --- .../apache/hadoop/hbase/regionserver/MemStoreFlusher.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/MemStoreFlusher.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/MemStoreFlusher.java index a8457c696c0..5c92304fa1e 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/MemStoreFlusher.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/MemStoreFlusher.java @@ -238,6 +238,11 @@ class MemStoreFlusher implements FlushRequester { } private class FlushHandler extends HasThread { + + private FlushHandler(String name) { + super(name); + } + @Override public void run() { while (!server.isStopped()) { @@ -381,7 +386,7 @@ class MemStoreFlusher implements FlushRequester { ThreadFactory flusherThreadFactory = Threads.newDaemonThreadFactory( server.getServerName().toShortString() + "-MemStoreFlusher", eh); for (int i = 0; i < flushHandlers.length; i++) { - flushHandlers[i] = new FlushHandler(); + flushHandlers[i] = new FlushHandler("MemStoreFlusher." + i); flusherThreadFactory.newThread(flushHandlers[i]); flushHandlers[i].start(); }