Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can I submit an oozie job with multiple configuration files?

From the Oozie CLI I want to do something like this:

oozie job -oozie http://host:port/oozie -config jobConfig.properties, baseConfig.properties -submit

I have a lot of different jobs I'm running where a portion of the .properties file is identical. I'd like to be able to move that duplicated portion into a single baseConfig.properties file, and combine this with the job-specific part when I submit the job.

like image 985
Tim Goodman Avatar asked Dec 19 '12 19:12

Tim Goodman


1 Answers

If the number of overridden properties is small, you can just reference the base config file, and then use the -Dprop1=value notation for each property you want to customize.

Otherwise i think you have two (possibly three) alternatives (as you can't pass multiple config options to the current OOZIE client):

  1. Create a script that concatenates the base and job specific property files together, and the run oozie with the name of the merged file
  2. Using the source from OozieCLI as a starting point, write an extension class that can handle a CSV value for the -config option, or can handle multiple -config argument instances
  3. Are you able to move the common attributes into static jobXml files for each action, then you would only need a single config file for the actual differences between the job runs.
like image 97
Chris White Avatar answered Sep 22 '22 16:09

Chris White