hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From te...@apache.org
Subject svn commit: r1523031 - in /hbase/trunk: hbase-client/src/main/java/org/apache/hadoop/hbase/client/HBaseAdmin.java hbase-server/src/main/ruby/shell/commands.rb
Date Fri, 13 Sep 2013 17:45:52 GMT
Author: tedyu
Date: Fri Sep 13 17:45:51 2013
New Revision: 1523031

URL: http://svn.apache.org/r1523031
Log:
HBASE-9211 "ERROR: undefined method `message' for nil:NilClass" in the shell on error


Modified:
    hbase/trunk/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HBaseAdmin.java
    hbase/trunk/hbase-server/src/main/ruby/shell/commands.rb

Modified: hbase/trunk/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HBaseAdmin.java
URL: http://svn.apache.org/viewvc/hbase/trunk/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HBaseAdmin.java?rev=1523031&r1=1523030&r2=1523031&view=diff
==============================================================================
--- hbase/trunk/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HBaseAdmin.java
(original)
+++ hbase/trunk/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HBaseAdmin.java
Fri Sep 13 17:45:51 2013
@@ -2880,7 +2880,7 @@ public class HBaseAdmin implements Abort
   public void cloneSnapshot(final String snapshotName, final TableName tableName)
       throws IOException, TableExistsException, RestoreSnapshotException, InterruptedException
{
     if (tableExists(tableName)) {
-      throw new TableExistsException("Table '" + tableName + " already exists");
+      throw new TableExistsException(tableName);
     }
     internalRestoreSnapshot(snapshotName, tableName);
     waitUntilTableIsEnabled(tableName);

Modified: hbase/trunk/hbase-server/src/main/ruby/shell/commands.rb
URL: http://svn.apache.org/viewvc/hbase/trunk/hbase-server/src/main/ruby/shell/commands.rb?rev=1523031&r1=1523030&r2=1523031&view=diff
==============================================================================
--- hbase/trunk/hbase-server/src/main/ruby/shell/commands.rb (original)
+++ hbase/trunk/hbase-server/src/main/ruby/shell/commands.rb Fri Sep 13 17:45:51 2013
@@ -90,8 +90,8 @@ module Shell
       rescue org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException
         valid_cols = table(args.first).get_all_columns.map { |c| c + '*' }
         raise "Unknown column family! Valid column names: #{valid_cols.join(", ")}"
-      rescue org.apache.hadoop.hbase.TableExistsException => e
-        raise "Table already exists: #{e.message}!"
+      rescue org.apache.hadoop.hbase.TableExistsException
+        raise "Table already exists: #{args.first}!"
       end
     end
   end



Mime
View raw message