From b979487cace818e59945d65bb37db399e777ab72 Mon Sep 17 00:00:00 2001 From: Sergey Soldatov Date: Thu, 11 Jan 2018 16:02:40 -0800 Subject: [PATCH] HBASE-19775 hbase shell doesn't handle the exceptions that are wrapped in java.io.UncheckedIOException Signed-off-by: Josh Elser Signed-off-by: Michael Stack --- hbase-shell/src/main/ruby/shell/commands.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/hbase-shell/src/main/ruby/shell/commands.rb b/hbase-shell/src/main/ruby/shell/commands.rb index 1b8de9e7f2b..990e978dde2 100644 --- a/hbase-shell/src/main/ruby/shell/commands.rb +++ b/hbase-shell/src/main/ruby/shell/commands.rb @@ -108,6 +108,7 @@ module Shell yield rescue => cause # let individual command handle exceptions first + cause = cause.getCause if cause.is_a? java.io.UncheckedIOException handle_exceptions(cause, *args) if respond_to?(:handle_exceptions) # Global HBase exception handling below if not handled by respective command above if cause.is_a?(org.apache.hadoop.hbase.TableNotFoundException)