hadoop-common-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Owen O'Malley <omal...@apache.org>
Subject Re: getting Configuration object in mapper
Date Fri, 05 Dec 2008 19:56:17 GMT

On Dec 4, 2008, at 9:19 PM, abhinit wrote:

> I have set some variable using the JobConf object.
>
> jobConf.set("Operator", operator) etc.
>
> How can I get an instance of Configuration object/ JobConf object  
> inside
> a map method so that I can retrieve these variables.

In your Mapper class, implement a method like:
  public void configure(JobConf job) { ... }

This will be called when the object is created with the job conf.

-- Owen
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message