Hadoop Map/Reduce
  1. Hadoop Map/Reduce
  2. MAPREDUCE-806

WordCount example does not compile given the current instructions

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Trivial Trivial
    • Resolution: Unresolved
    • Affects Version/s: 0.20.1
    • Fix Version/s: None
    • Component/s: examples
    • Labels:
      None
    • Environment:

      linux

    • Tags:
      example wordcount

      Description

      http://hadoop.apache.org/common/docs/r0.20.0/mapred_tutorial.html#Example%3A+WordCount+v1.0

      In this example, the classpath is missing commons-cli-2.0-SNAPSHOT.jar

      If we compile according to the instructions:

      $ javac -classpath /hadoop/core/hadoop-0.20.0-core.jar -d ioperf_classes/ src/WordCount.java
      src/WordCount.java:54: cannot access org.apache.commons.cli.Options
      class file for org.apache.commons.cli.Options not found
      String[] otherArgs = new GenericOptionsParser(conf, args).getRemainingArgs();

      The correct compilation should be

      $ javac -classpath /hadoop/core/hadoop-0.20.0-core.jar:/hadoop/core/lib/commons-cli-2.0-SNAPSHOT.jar -d ioperf_classes/ src/WordCount.java

        Activity

        No work has yet been logged on this issue.

          People

          • Assignee:
            Unassigned
            Reporter:
            Hector Yuen
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:

              Development