title: setNumMapTasks(int) is undefined for the job type - Hadoop MapReduce
body: <p>I am not able to add "job.setNumMapTasks(int)" to the driver for my MapReduce program.  When I try to add it, I get a compile error stating, "setNumMapTasks(int) is undefined for the job type".  However, I am able to add the reducer equivalent, "job.setNumReduceTasks(int)".  It would seem to me that if I can add one, I should be able to add the other.  Below is my driver.  Any suggestions are very welcome.</p>
  
  <pre><code>public int run(String[] args) throws Exception {
      Configuration conf = getConf();      
      Job job = new Job(conf, "PiCalc");        
      job.setJarByClass(PiCalc.class);            
      Path in = new Path(args[0]);
      Path out = new Path(args[1]);
      FileInputFormat.setInputPaths(job, in);
      FileOutputFormat.setOutputPath(job, out);
      job.setJobName("PiCalc"); 
      job.setNumMapTasks(20);
      job.setNumReduceTasks(10);
      job.setMapperClass(MapClass.class);
      job.setReducerClass(Reduce.class);   
      job.setInputFormatClass(KeyValueTextInputFormat.class);
      job.setOutputFormatClass(TextOutputFormat.class);
      job.setOutputKeyClass(IntWritable.class);
      job.setOutputValueClass(IntWritable.class);
      System.exit(job.waitForCompletion(true)?0:1);
      return 0;
  }  
  </code></pre>