hbase-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Steve Kuo <kuosen...@yahoo.com>
Subject Please advise: best way to write a unit test for MapRed HBase case
Date Thu, 03 Dec 2009 23:10:12 GMT
I have a class that does a regular map job and a TableReduce based reduce job.  This class
works when called as the main class either from eclipse or on my pseudo cluster as long as
hbase is up and running.  I like to write a unit test for it and like advices on the best
way to proceed.

The best I came up with after googling for "hbase unit test" is a page that suggest looking
at org.apache.hadoop.hbase.TestTableMapReduce.  I was able to get this class to run after
adding additional classes in:

* org.apache.hadoop.hbase
* org.apache.hadoop.hdfs
* org.apache.hadoop.hdfs.server.datanode
* org.apache.hadoop.mapred
* org.apahce.hadoop.net
* jetty-6.1.14.jar

After all this, the test worked but it was very slow as it had to start up mini-cluster for
dfs and etc.  It seemed excessive that jetty was needed.

Please advise on whether there is a simpler way to do unit test.

Thanks in advance.



      
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message