diff --git src/main/java/org/apache/hadoop/hbase/mapreduce/TableOutputFormat.java src/main/java/org/apache/hadoop/hbase/mapreduce/TableOutputFormat.java index a9e5a0c..5318a6e 100644 --- src/main/java/org/apache/hadoop/hbase/mapreduce/TableOutputFormat.java +++ src/main/java/org/apache/hadoop/hbase/mapreduce/TableOutputFormat.java @@ -178,6 +178,9 @@ implements Configurable { public void setConf(Configuration otherConf) { this.conf = HBaseConfiguration.create(otherConf); String tableName = this.conf.get(OUTPUT_TABLE); + if(tableName == null) { + throw new IllegalArgumentException("Must specify table name"); + } String address = this.conf.get(QUORUM_ADDRESS); String serverClass = this.conf.get(REGION_SERVER_CLASS); String serverImpl = this.conf.get(REGION_SERVER_IMPL); @@ -194,6 +197,7 @@ implements Configurable { LOG.info("Created table instance for " + tableName); } catch(IOException e) { LOG.error(e); + throw new RuntimeException(e); } } }