Building Java Applications that Use the MapR Streams API Library

You can compile and run a Java application that uses the required JAR file from the MapR Maven repository or from the MapR installation.

Using the JAR File from the MapR Maven Repository

  1. Add MapR's Maven repository to your pom.xml file, if it is not already added:
  2. Add a dependency to the mapr-streams project:

Using JARs from the MapR Installation

  • Use the following command to compile applications:
    javac -cp `mapr classpath` <Application jars>
  • Use the following command to run applications:
    java -cp `mapr classpath`:. <Main class jar> <commandline arguments>