lucienfregosi
lucienfregosi

Reputation: 51

How to Pass argument to Oozie

My use case is the following, I am building an Oozie Pipeline and i need to pass it an argument.

Indeed my spark job must receive a string date as an argument and it would be great to pass the argument to the Oozie Workflow in order to use it in the Spark Submit. Anyone got any idea ? I didn't find the answer on Google

Thanks

Upvotes: 1

Views: 2982

Answers (1)

Vitalii Kotliarenko
Vitalii Kotliarenko

Reputation: 2967

  1. Create workflow.xml that references some variable inputDate

  2. Create file job.properties that defines default value for inputDate

  3. Run your job using CLI, overriding default value when is needed:
    oozie job -run -config job.properties -DinputDate=2017-08-19

Upvotes: 1

Related Questions