You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@gora.apache.org by Bai Shen <ba...@gmail.com> on 2012/10/03 21:34:24 UTC

Found interface org.apache.hadoop.mapreduce.TaskAttemptContext, but class was expected

I'm using Nutch 2 on CDH4.  Nutch uses Gora to talk to HBase.  I'm getting
the following error.  Any suggestions on how to fix this?

Thanks.

12/10/03 15:33:59 WARN mapred.LocalJobRunner: job_local_0001
java.lang.IncompatibleClassChangeError: Found interface
org.apache.hadoop.mapreduce.TaskAttemptContext, but class was expected
        at
org.apache.gora.mapreduce.GoraOutputFormat.getRecordWriter(GoraOutputFormat.java:83)
        at
org.apache.hadoop.mapred.MapTask$NewDirectOutputCollector.<init>(MapTask.java:523)
        at org.apache.hadoop.mapred.MapTask.runNewMapper(MapTask.java:626)
        at org.apache.hadoop.mapred.MapTask.run(MapTask.java:325)
        at
org.apache.hadoop.mapred.LocalJobRunner$Job.run(LocalJobRunner.java:263)

Re: Found interface org.apache.hadoop.mapreduce.TaskAttemptContext, but class was expected

Posted by Henry Saputra <he...@gmail.com>.
Including the @dev list to get extended help.

- Henry

On Wed, Oct 3, 2012 at 12:34 PM, Bai Shen <ba...@gmail.com> wrote:
> I'm using Nutch 2 on CDH4.  Nutch uses Gora to talk to HBase.  I'm getting
> the following error.  Any suggestions on how to fix this?
>
> Thanks.
>
> 12/10/03 15:33:59 WARN mapred.LocalJobRunner: job_local_0001
> java.lang.IncompatibleClassChangeError: Found interface
> org.apache.hadoop.mapreduce.TaskAttemptContext, but class was expected
>         at
> org.apache.gora.mapreduce.GoraOutputFormat.getRecordWriter(GoraOutputFormat.java:83)
>         at
> org.apache.hadoop.mapred.MapTask$NewDirectOutputCollector.<init>(MapTask.java:523)
>         at org.apache.hadoop.mapred.MapTask.runNewMapper(MapTask.java:626)
>         at org.apache.hadoop.mapred.MapTask.run(MapTask.java:325)
>         at
> org.apache.hadoop.mapred.LocalJobRunner$Job.run(LocalJobRunner.java:263)
>

Re: Found interface org.apache.hadoop.mapreduce.TaskAttemptContext, but class was expected

Posted by Henry Saputra <he...@gmail.com>.
Including the @dev list to get extended help.

- Henry

On Wed, Oct 3, 2012 at 12:34 PM, Bai Shen <ba...@gmail.com> wrote:
> I'm using Nutch 2 on CDH4.  Nutch uses Gora to talk to HBase.  I'm getting
> the following error.  Any suggestions on how to fix this?
>
> Thanks.
>
> 12/10/03 15:33:59 WARN mapred.LocalJobRunner: job_local_0001
> java.lang.IncompatibleClassChangeError: Found interface
> org.apache.hadoop.mapreduce.TaskAttemptContext, but class was expected
>         at
> org.apache.gora.mapreduce.GoraOutputFormat.getRecordWriter(GoraOutputFormat.java:83)
>         at
> org.apache.hadoop.mapred.MapTask$NewDirectOutputCollector.<init>(MapTask.java:523)
>         at org.apache.hadoop.mapred.MapTask.runNewMapper(MapTask.java:626)
>         at org.apache.hadoop.mapred.MapTask.run(MapTask.java:325)
>         at
> org.apache.hadoop.mapred.LocalJobRunner$Job.run(LocalJobRunner.java:263)
>

Re: Found interface org.apache.hadoop.mapreduce.TaskAttemptContext, but class was expected

Posted by Lewis John Mcgibbney <le...@gmail.com>.
Hi,

It's becoming clear th6at there are compatibility issues behind CDH4
and the current Nutch 2.x/Gora/XYZ stack.

There are various Jira tickets open to address this, however we *are
most likely* talking about another upgrade of our Hadoop dependencies
within Gora. This is not something which should be taken lightly
either as backward compatibility (has been and) is an issue here also.

Having said this we would very much welcome any contribution to keep
Gora bang up-to-date with the likes of CDH4 if possible.

Lewis

On Thu, Oct 4, 2012 at 6:39 AM, Ashwanth Kumar <as...@indix.com> wrote:
> Seems like you are using the Gora built against Apache Hadoop distribution,
> on CDH4. Try compiling them against CDH4 or try using CDH3
>
> Since the Class on 1.x was converted to interface on 2.x of Hadoop and CDH4
> has back ported them.
>
>
> On Thu, Oct 4, 2012 at 1:04 AM, Bai Shen <ba...@gmail.com> wrote:
>>
>> I'm using Nutch 2 on CDH4.  Nutch uses Gora to talk to HBase.  I'm getting
>> the following error.  Any suggestions on how to fix this?
>>
>> Thanks.
>>
>> 12/10/03 15:33:59 WARN mapred.LocalJobRunner: job_local_0001
>> java.lang.IncompatibleClassChangeError: Found interface
>> org.apache.hadoop.mapreduce.TaskAttemptContext, but class was expected
>>         at
>> org.apache.gora.mapreduce.GoraOutputFormat.getRecordWriter(GoraOutputFormat.java:83)
>>         at
>> org.apache.hadoop.mapred.MapTask$NewDirectOutputCollector.<init>(MapTask.java:523)
>>         at org.apache.hadoop.mapred.MapTask.runNewMapper(MapTask.java:626)
>>         at org.apache.hadoop.mapred.MapTask.run(MapTask.java:325)
>>         at
>> org.apache.hadoop.mapred.LocalJobRunner$Job.run(LocalJobRunner.java:263)
>>
>
>
>
> --
> -- Ashwanth Kumar
>



-- 
Lewis

Re: Found interface org.apache.hadoop.mapreduce.TaskAttemptContext, but class was expected

Posted by Ashwanth Kumar <as...@indix.com>.
Seems like you are using the Gora built against Apache Hadoop distribution,
on CDH4. Try compiling them against CDH4 or try using CDH3

Since the Class on
1.x<http://hadoop.apache.org/docs/r1.0.1/api/org/apache/hadoop/mapreduce/TaskAttemptContext.html>was
converted to interface
on 2.x<http://hadoop.apache.org/docs/current/api/org/apache/hadoop/mapreduce/TaskAttemptContext.html>of
Hadoop and CDH4
has back ported<http://archive.cloudera.com/cdh4/cdh/4/hadoop/api/org/apache/hadoop/mapreduce/TaskAttemptContext.html>them.

On Thu, Oct 4, 2012 at 1:04 AM, Bai Shen <ba...@gmail.com> wrote:

> I'm using Nutch 2 on CDH4.  Nutch uses Gora to talk to HBase.  I'm getting
> the following error.  Any suggestions on how to fix this?
>
> Thanks.
>
> 12/10/03 15:33:59 WARN mapred.LocalJobRunner: job_local_0001
> java.lang.IncompatibleClassChangeError: Found interface
> org.apache.hadoop.mapreduce.TaskAttemptContext, but class was expected
>         at
> org.apache.gora.mapreduce.GoraOutputFormat.getRecordWriter(GoraOutputFormat.java:83)
>         at
> org.apache.hadoop.mapred.MapTask$NewDirectOutputCollector.<init>(MapTask.java:523)
>         at org.apache.hadoop.mapred.MapTask.runNewMapper(MapTask.java:626)
>         at org.apache.hadoop.mapred.MapTask.run(MapTask.java:325)
>         at
> org.apache.hadoop.mapred.LocalJobRunner$Job.run(LocalJobRunner.java:263)
>
>


-- 
-- Ashwanth Kumar