title: Meaning of context.getconfiguration in hadoop
body: <p>I have this doubt in code of searching by argument.</p>
  
  <p>what is the meaning of  <code>context.getConfiguration().get("Uid2Search");</code></p>
  
  <pre><code>package SearchTxnByArg;
  
  // This is the Mapper Program for SearchTxnByArg
  import java.io.IOException;
  import org.apache.hadoop.io.LongWritable;
  import org.apache.hadoop.io.NullWritable;
  import org.apache.hadoop.io.Text;
  import org.apache.hadoop.mapreduce.Mapper;
  
  public class MyMap extends Mapper&lt;LongWritable, Text, NullWritable, Text&gt;{
  
          public void map(LongWritable key, Text value, Context context) throws IOException, InterruptedException {
  
              String Txn = value.toString();
              String TxnParts[] = Txn.split(",");
              String Uid = TxnParts[2];
              String Uid2Search = context.getConfiguration().get("Uid2Search");
              if(Uid.equals(Uid2Search))
              {
                  context.write(null, value); 
              }           
          }
      }
  </code></pre>
  
  <p>Driver Program</p>
  
  <pre><code>package SearchTxnByArg;
  
  import org.apache.hadoop.conf.Configuration;
  import org.apache.hadoop.fs.Path;
  import org.apache.hadoop.io.NullWritable;
  import org.apache.hadoop.io.Text;
  import org.apache.hadoop.mapreduce.Job;
  import org.apache.hadoop.mapreduce.lib.input.FileInputFormat;
  import org.apache.hadoop.mapreduce.lib.output.FileOutputFormat;
  
  public class MyDriver {
      public static void main(String[] args) throws Exception {
          Configuration conf = new Configuration();
          conf.set("Uid2Search", args[0]);        
          Job job = new Job(conf, "Map Reduce Search Txn by Arg");
          job.setJarByClass(MyDriver.class);
          job.setMapperClass(MyMap.class);
          job.setMapOutputKeyClass(NullWritable.class);
          job.setMapOutputValueClass(Text.class);
          job.setNumReduceTasks(0);
          FileInputFormat.addInputPath(job, new Path(args[1]));
          FileOutputFormat.setOutputPath(job, new Path(args[2]));
          System.exit(job.waitForCompletion(true) ? 0 : 1);
      }
  
  }
  </code></pre>