diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HTable.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HTable.java index c56132c..2f71a25 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HTable.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HTable.java @@ -163,6 +163,9 @@ public class HTable implements Table { if (connection == null || connection.isClosed()) { throw new IllegalArgumentException("Connection is null or closed."); } + if (tableName == null) { + throw new IllegalArgumentException("Given table name should not be null"); + } this.tableName = tableName; this.cleanupConnectionOnClose = false; this.connection = connection;