Adding the HBase or Hadoop configuration files

Learn how to add the HBase or Hadoop configuration files to the classpath.

As Phoenix is built on top of the HBase client, it needs the HBase configuration files for the right operation. For some configurations, it may also need other Hadoop or HDFS configuration files like core-site.xml.

  1. Download the hbase-site.xml from the cluster, and copy it to a directory on the classpath.
    The hbase-site.xml usually resides in /etc/hbase/conf on the client side.
  2. Pack hbase-site.xml into the root directory of a JAR file, and add that to the classpath.
    If hbase-site.xml changes on the cluster, ensure to copy the latest one to the application classpath.

    For some development clusters, that use the default configuration, Phoenix might work without this; however, ensure that the hbase-site.xml on the classpath is correct.