0

Im facing an issue while running a MapReduce program using Hadoop 2 (YARN) and Pig. I'm able to read data from Cassandra using Pig script, however when running MapReduce, it is throwing the exception as given below:

Exception in thread "main" java.lang.IncompatibleClassChangeError: Found interface org.apache.hadoop.mapreduce.JobContext, but class was expected
    at org.apache.cassandra.hadoop.ColumnFamilyOutputFormat.checkOutputSpecs(ColumnFamilyOutputFormat.java:80)
    at org.apache.pig.newplan.logical.rules.InputOutputFileValidator$InputOutputFileVisitor.visit(InputOutputFileValidator.java:80)
    at org.apache.pig.newplan.logical.relational.LOStore.accept(LOStore.java:66)   
4

1 回答 1

0

Pig 的二进制发行版是针对 Hadoop 1.x 编译的。您需要针对 2.x(在我的情况下为 2.2)重新编译它才能使其工作。尝试这个:

ant clean jar-withouthadoop -Dhadoopversion=23

来源

于 2014-01-27T15:10:00.710 回答