Uploaded image for project: 'Crunch (Retired)'
  1. Crunch (Retired)
  2. CRUNCH-295

java.lang.IncompatibleClassChangeError: Found class org.apache.hadoop.mapreduce.TaskInputOutputContext, but interface was expected in crunch 0.8.0

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 0.8.0
    • Fix Version/s: 0.9.0, 0.8.2
    • Component/s: Core
    • Labels:
      None

      Description

      Crunch 0.8.0 does not work for me, while crunch 0.7.0 did.
      To be more precise: when I compile crunch 0.8.0 from the git tag, it does work, but the jars downloaded from Maven Central don't.
      I compared both jars (mine vs downloaded) and they are indeed different.
      you can see (for instance in CrunchTaskContext):

      invokevirtual #4; //Method org/apache/hadoop/mapreduce...
      vs
      invokeinterface #4, 1; //InterfaceMethod org/apache/hadoop/mapreduce...

      Which means that crunch 0.8.0 is compiled with an interface iso an abstract class.
      the hadoop-1 profile shows a dependency to hadoop 1.1.2 which contains a class iso an interface.

      What we think happened is this:
      1) compile crunch with hadoop-2 profile:
      2) on same machine also compile crunch with hadoop-1 profile, but without clean option.
      because of the missing clean, maven won't recompile unchanged classes. which would explain how you end up with crunch 0.8.0 being compiled against hadoop-2 instead of hadoop-1

        Attachments

          Activity

            People

            • Assignee:
              jwills Josh Wills
              Reporter:
              desmit Stefan De Smit
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: