Support Questions
Find answers, ask questions, and share your expertise
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

Java Program to query a Kite Dataset


Java Program to query a Kite Dataset

Rising Star


I am reading my first tutorial of kite sdk programming and have written this program (based on the grouplens movie dataset).
I have already created the dataset and loaded it with data using the kite-dataset utility. Now I am writing a java program just to query it
here is java code
package com.abhishek.HelloKite;
// hadoop
import org.apache.hadoop.util.Tool;
import org.apache.hadoop.util.ToolRunner;
import org.apache.hadoop.conf.Configured;

// kite

// avro
import org.apache.avro.generic.GenericRecord;
import org.apache.avro.generic.GenericData.Record;

 * Hello world!
public class App extends Configured implements Tool 
	public int run(String[] args) throws Exception {
		Dataset<Record> movies = Datasets.load("dataset:hive?dataset=movies", Record.class);
		DatasetReader<Record> reader = null;
		try {
			reader = movies.newReader();
			for(GenericRecord movie : movies.newReader()) {
		} finally {
			if (reader != null) reader.close();
		return 0;		
	public static void main(String[] args) throws Exception {
		int rc = App(), args);


Here is my pom.xml
<project xmlns="" xmlns:xsi=""






			<scope>compile</scope> <!-- provide Hadoop dependencies -->
			<scope>compile</scope> <!-- provide Hive dependencies -->




But when I try to build a final jar file (which I will copy to my hadoop cluster and try to execute). I get this error
[INFO] Scanning for projects...
[INFO] Using the builder org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder with a thread count of 1
[INFO] ------------------------------------------------------------------------
[INFO] Building HelloKite 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] --- kite-maven-plugin:0.17.1:package-app (default-cli) @ HelloKite ---
[INFO] ------------------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 4.044 s
[INFO] Finished at: 2014-12-25T16:30:03-06:00
[INFO] Final Memory: 32M/617M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.kitesdk:kite-maven-plugin:0.17.1:package-app (default-cli) on project HelloKite: The parameters 'toolClass' for goal org.kitesdk:kite-maven-plugin:0.17.1:package-app are missing or invalid -> [Help 1]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] For more information about the errors and possible solutions, please read the following articles:
What is going wrong? Can you help me in resolving this?

Re: Java Program to query a Kite Dataset

Which maven command are you running to build the jar?
Don't have an account?
Coming from Hortonworks? Activate your account here