title: Hbase CopyTable inside Java
body: <p>I want to copy one Hbase table to another location with good performance.</p>
  
  <p>I would like to reuse the code from CopyTable.java from <a href="https://github.com/apache/hbase/blob/master/hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/CopyTable.java" rel="nofollow noreferrer" title="CopyTable.java">Hbase-server github page</a></p>
  
  <p>I've been looking the doccumentation from hbase but it didn't help me much <a href="http://hbase.apache.org/apidocs/org/apache/hadoop/hbase/mapreduce/CopyTable.html" rel="nofollow noreferrer">http://hbase.apache.org/apidocs/org/apache/hadoop/hbase/mapreduce/CopyTable.html</a></p>
  
  <p>After looking in this post of stackoverflow: <a href="https://stackoverflow.com/questions/2550310/can-a-main-method-of-class-be-invoked-in-another-class-in-java">Can a main() method of class be invoked in another class in java</a></p>
  
  <p>I think I can directly call it using its main class. </p>
  
  <p>Question: Do you think anyway better to get this copy done rather than using CopyTable from hbase-server ? Do you see any inconvenience using this CopyTable ?</p>