You are viewing a plain text version of this content. The canonical link for it is here.
Posted to hdfs-user@hadoop.apache.org by Shailesh Samudrala <sh...@gmail.com> on 2013/08/23 19:37:14 UTC

Passing parameters to MapReduce through Oozie

Hello,

I am trying to pass parameters to my MapReduce job from Oozie MapReduce
action. Here's how I'm declaring the parameters in Oozie workflow.xml:

<property>
     <name>param1</name>
     <value>paramValue</value>
</property>


However, I'm not sure if this is the right way. Even if it is, I don't know
how to access those parameters from within my Map-Reduce job.

I tried

configuration.get("param1");

but, it doesn't work.

I would really appreciate some advise on this.

Thank you!

Regards,

Shailesh

Re: Passing parameters to MapReduce through Oozie

Posted by Harsh J <ha...@cloudera.com>.
If you use mapreduce-action, then is the configuration lookup done
within a Mapper/Reducer? If so, how are you grabbing the configuration
object? Via the overridden "configure(JobConf conf)" method?

On Fri, Aug 23, 2013 at 11:07 PM, Shailesh Samudrala
<sh...@gmail.com> wrote:
> Hello,
>
> I am trying to pass parameters to my MapReduce job from Oozie MapReduce
> action. Here's how I'm declaring the parameters in Oozie workflow.xml:
>
> <property>
>      <name>param1</name>
>      <value>paramValue</value>
> </property>
>
>
> However, I'm not sure if this is the right way. Even if it is, I don't know
> how to access those parameters from within my Map-Reduce job.
>
> I tried
>
> configuration.get("param1");
>
> but, it doesn't work.
>
> I would really appreciate some advise on this.
>
> Thank you!
>
> Regards,
>
> Shailesh



-- 
Harsh J

Re: Passing parameters to MapReduce through Oozie

Posted by Harsh J <ha...@cloudera.com>.
If you use mapreduce-action, then is the configuration lookup done
within a Mapper/Reducer? If so, how are you grabbing the configuration
object? Via the overridden "configure(JobConf conf)" method?

On Fri, Aug 23, 2013 at 11:07 PM, Shailesh Samudrala
<sh...@gmail.com> wrote:
> Hello,
>
> I am trying to pass parameters to my MapReduce job from Oozie MapReduce
> action. Here's how I'm declaring the parameters in Oozie workflow.xml:
>
> <property>
>      <name>param1</name>
>      <value>paramValue</value>
> </property>
>
>
> However, I'm not sure if this is the right way. Even if it is, I don't know
> how to access those parameters from within my Map-Reduce job.
>
> I tried
>
> configuration.get("param1");
>
> but, it doesn't work.
>
> I would really appreciate some advise on this.
>
> Thank you!
>
> Regards,
>
> Shailesh



-- 
Harsh J

Re: Passing parameters to MapReduce through Oozie

Posted by Harsh J <ha...@cloudera.com>.
If you use mapreduce-action, then is the configuration lookup done
within a Mapper/Reducer? If so, how are you grabbing the configuration
object? Via the overridden "configure(JobConf conf)" method?

On Fri, Aug 23, 2013 at 11:07 PM, Shailesh Samudrala
<sh...@gmail.com> wrote:
> Hello,
>
> I am trying to pass parameters to my MapReduce job from Oozie MapReduce
> action. Here's how I'm declaring the parameters in Oozie workflow.xml:
>
> <property>
>      <name>param1</name>
>      <value>paramValue</value>
> </property>
>
>
> However, I'm not sure if this is the right way. Even if it is, I don't know
> how to access those parameters from within my Map-Reduce job.
>
> I tried
>
> configuration.get("param1");
>
> but, it doesn't work.
>
> I would really appreciate some advise on this.
>
> Thank you!
>
> Regards,
>
> Shailesh



-- 
Harsh J

Re: Passing parameters to MapReduce through Oozie

Posted by Harsh J <ha...@cloudera.com>.
If you use mapreduce-action, then is the configuration lookup done
within a Mapper/Reducer? If so, how are you grabbing the configuration
object? Via the overridden "configure(JobConf conf)" method?

On Fri, Aug 23, 2013 at 11:07 PM, Shailesh Samudrala
<sh...@gmail.com> wrote:
> Hello,
>
> I am trying to pass parameters to my MapReduce job from Oozie MapReduce
> action. Here's how I'm declaring the parameters in Oozie workflow.xml:
>
> <property>
>      <name>param1</name>
>      <value>paramValue</value>
> </property>
>
>
> However, I'm not sure if this is the right way. Even if it is, I don't know
> how to access those parameters from within my Map-Reduce job.
>
> I tried
>
> configuration.get("param1");
>
> but, it doesn't work.
>
> I would really appreciate some advise on this.
>
> Thank you!
>
> Regards,
>
> Shailesh



-- 
Harsh J