我通过Hue界面创建了一个Oozie工作流程。我几乎没有与此相关的问题
一个。我可以看到创建的工作流XML。但我没有看到job.properties文件。 Job.properties存储在哪里?
湾有REST API提交通过编写workflow.xml和job.properties创建的Oozie作业。对于通过HUE创建的oozie工作流程,REST API是什么?任何样本都会有帮助。
答案 0 :(得分:3)
不想提出问题然后回答。但由于我不得不在某个时间进行搜索,答案可能对某人有所帮助......
当使用Hue创建Oozie工作流时,Hue创建工作流xml并将其放置在HDFS位置。此文件可以复制并放置在HDFS中的任何位置。
要对oozie进行REST API调用以启动工作流,以及workflow.xml,需要传递config.xml。要获取要在config.xml中填充的值,我使用此方法来查找详细信息。
Submit the job via Hue.
Open the Oozie Web UI. (You can get the link from the Ambari. Click on oozie and look at the quick links at the top).
In the Oozie Web UI, the job that is executed will be shown in list view.
One of the tab is the Job Configuration.
The content of the Job Configuration will be the content in the config.xml that need to be passed along with the REST API.
示例网址为
http://IP-where-Oozie-server-runs:11000/oozie/v1/jobs?action=start
要启动的实际工作流程存在于config.xml
中 <property>
<name>oozie.wf.application.path</name>
<value>hdfs://Named-node-name:8020/location/to/workflow.xml </value>
</property>
问题仍未解决 - 是否有job.properties文件。看起来它不存在而且不是必需的。
注意:由romain更新后,job.properties不存在,并被POST正文内容替换。
答案 1 :(得分:1)
确实使用Oozie的REST API用于submitting a job。如果你看一下,你会看到通过在POST数据中提供数据来替换job.properties:
e.g。
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<property>
<name>user.name</name>
<value>bansalm</value>
</property>
....
答案 2 :(得分:0)
属性和工作流文件都在工作区文件夹
中