hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From st...@apache.org
Subject hbase git commit: HBASE-13058-shell unknown table message update
Date Tue, 24 Feb 2015 06:46:16 GMT
Repository: hbase
Updated Branches:
  refs/heads/branch-1 8f3fc72b9 -> 6f81a0982


HBASE-13058-shell unknown table message update

Signed-off-by: stack <stack@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/hbase/repo
Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/6f81a098
Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/6f81a098
Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/6f81a098

Branch: refs/heads/branch-1
Commit: 6f81a0982a27a316e1a776dd0986b44fa183893e
Parents: 8f3fc72
Author: Abhishek Kumar <abhishek.kr@huawei.com>
Authored: Fri Feb 20 11:04:46 2015 +0530
Committer: stack <stack@apache.org>
Committed: Mon Feb 23 22:46:08 2015 -0800

----------------------------------------------------------------------
 hbase-shell/src/main/ruby/shell/commands.rb | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hbase/blob/6f81a098/hbase-shell/src/main/ruby/shell/commands.rb
----------------------------------------------------------------------
diff --git a/hbase-shell/src/main/ruby/shell/commands.rb b/hbase-shell/src/main/ruby/shell/commands.rb
index 54fa204..bb69fd6 100644
--- a/hbase-shell/src/main/ruby/shell/commands.rb
+++ b/hbase-shell/src/main/ruby/shell/commands.rb
@@ -95,8 +95,8 @@ module Shell
         # Get the special java exception which will be handled
         cause = e.cause
         if cause.kind_of?(org.apache.hadoop.hbase.TableNotFoundException) then
-          str = java.lang.String.new("#{cause}")
-          raise "Unknown table #{str}!"
+          first_arg = args.first
+          raise "Unknown table #{first_arg}!"
         end
         if cause.kind_of?(org.apache.hadoop.hbase.client.RetriesExhaustedWithDetailsException)
then
           exceptions = cause.getCauses
@@ -105,6 +105,10 @@ module Shell
               valid_cols = table(args.first).get_all_columns.map { |c| c + '*' }
               raise "Unknown column family! Valid column names: #{valid_cols.join(", ")}"
             end
+            if exception.kind_of?(org.apache.hadoop.hbase.TableNotFoundException) then
+              first_arg = args.first
+              raise "Unknown table #{first_arg}!"
+            end
           end
         end
         if cause.kind_of?(org.apache.hadoop.hbase.TableExistsException) then


Mime
View raw message