Repository: hbase Updated Branches: refs/heads/0.98 480227576 -> bdb828d96
HBASE-12200 When an RPC server handler thread dies, throw exception (Alicia Shu) Project: http://git-wip-us.apache.org/repos/asf/hbase/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/bdb828d9 Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/bdb828d9 Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/bdb828d9 Branch: refs/heads/0.98 Commit: bdb828d96cf664e2e5eecf9decfb8f4eea5dbff4 Parents: 4802275 Author: Ted Yu <[email protected]> Authored: Thu Oct 9 20:49:57 2014 +0000 Committer: Ted Yu <[email protected]> Committed: Thu Oct 9 20:49:57 2014 +0000 ---------------------------------------------------------------------- .../java/org/apache/hadoop/hbase/ipc/RpcExecutor.java | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/hbase/blob/bdb828d9/hbase-server/src/main/java/org/apache/hadoop/hbase/ipc/RpcExecutor.java ---------------------------------------------------------------------- diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/ipc/RpcExecutor.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/ipc/RpcExecutor.java index eea29ca..68dc063 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/ipc/RpcExecutor.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/ipc/RpcExecutor.java @@ -18,8 +18,6 @@ package org.apache.hadoop.hbase.ipc; -import java.io.IOException; - import java.util.ArrayList; import java.util.List; import java.util.concurrent.BlockingQueue; @@ -29,10 +27,8 @@ import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import org.apache.hadoop.hbase.classification.InterfaceAudience; import org.apache.hadoop.hbase.classification.InterfaceStability; -import org.apache.hadoop.conf.Configuration; import com.google.common.base.Strings; -import com.google.common.collect.Lists; @InterfaceAudience.Private @InterfaceStability.Evolving @@ -112,6 +108,12 @@ public abstract class RpcExecutor { try { activeHandlerCount.incrementAndGet(); task.run(); + } catch (Error e) { + LOG.error("RpcServer handler thread throws error: ", e); + throw e; + } catch (RuntimeException e) { + LOG.error("RpcServer handler thread throws exception: ", e); + throw e; } finally { activeHandlerCount.decrementAndGet(); }
