Thanks, I did it, it works. I looked for a way to solve this problem using
configuration, without coding.

2016-04-26 16:18 GMT+02:00 satish saley <[email protected]>:

> You need to add oozie.action.conf.xml to job configuration
> of scalding/spark/mr job.
>
> The action configuration is written by Oozie to a file location mentioned
> in
>
> the system property "oozie.action.conf.xml"
>
> https://cwiki.apache.org/confluence/display/OOZIE/Java%20Cookbook
>
> JobConf jobConf = new JobConf(true);
> String actionXml = System.getProperty("oozie.action.conf.xml");
> jobConf.addResource(new Path("file:///", actionXml));
>
> If you use the above configuration for the job you are launching it should
> carry over the mapreduce.cache.files setting which puts the jars in the
> classpath.
>
> For other actions (pig, hive, mapreduce, etc) the conf is passed by Oozie.
> Since java action only has a main method, you will have to load the action
> config yourself.
>
>
> Sent from Yahoo Mail for iPhone <https://yho.com/footer0>
>
>
> On Tuesday, April 26, 2016, 1:58 AM, Serega Sheypak <
> [email protected]> wrote:
>
> Hi, I'm using oozie java action to start scalding/spark/mr job. Oozie java
> action launcher has correct classpath here:
> oozie.action.conf.xml
>
> actionConf.addResource(new Path("file:///",
> System.getProperty("oozie.action.conf.xml")));
>
> Is there any way to pass that conf to spawned job? Right now started
> job doesn't inherit classpath from oozie launcher and looses all
> dependent jar, since only oozie action sees them.
>
>

Reply via email to