如何使用简单的输入事件设置 Oozie 协调器?
How to set up Oozie coordinator with a simple input event?
如何设置可以存在或不存在的 Oozie 协调器输入事件?请填写 ???对于以下内容:
<coordinator-app name="${jobName}" frequency="${coord:days(1)}" start="${startTime}" end="${endTime}" timezone="${timezone}" xmlns="uri:oozie:coordinator:0.2">
<controls>
<timeout>-1</timeout>
<concurrency>30</concurrency>
<execution>FIFO</execution>
</controls>
<datasets>
<dataset name="myData" frequency="???" initial-instance="???" timezone="UTC">
<uri-template>/time-independent/path/that/may/or/maynot/be/there</uri-template>
</dataset>
</datasets>
<input-events>
<data-in name="myInput" dataset="myData">
<instance>???</instance>
</data-in>
</input-events>
<action>
<workflow>
<app-path>${myAppPath}</app-path>
<configuration>
<property>
<name>myInput</name>
<value>${coord:dataIn('myInput')}</value>
</property>
</configuration>
</workflow>
</action>
</coordinator-app>
谢谢,
阿尔瓦罗
数据集频率值将为 ${coord:days(1)},因为您希望将其安排在每天。
starttime 将是您要开始作业时的值。例如。 2017-01-22T12:00Z.
因此,更新后的协调器 xml 将是这样的:
<coordinator-app name="${jobName}" frequency="${coord:days(1)}" start="${startTime}" end="${endTime}" timezone="${timezone}"
xmlns="uri:oozie:coordinator:0.2">
<controls>
<timeout>-1</timeout>
<concurrency>30</concurrency>
<execution>FIFO</execution>
</controls>
<datasets>
<dataset name="myData" frequency="${coord:days(1)}" initial-instance="${startTime}" timezone="UTC">
<uri-template>/time-independent/path/that/may/or/maynot/be/there</uri-template>
</dataset>
</datasets>
<input-events>
<data-in name="myInput" dataset="myData">
<instance>${startTime}</instance>
</data-in>
</input-events>
<action>
<workflow>
<app-path>${myAppPath}</app-path>
<configuration>
<property>
<name>myInput</name>
<value>${coord:dataIn('myInput')}</value>
</property>
</configuration>
</workflow>
</action>
</coordinator-app>
是否可以定义可选的输入事件。
例如:
我定义了 4 个输入事件 .. A , B , C 和 D
看起来我们必须使用所有数据集
如何设置可以存在或不存在的 Oozie 协调器输入事件?请填写 ???对于以下内容:
<coordinator-app name="${jobName}" frequency="${coord:days(1)}" start="${startTime}" end="${endTime}" timezone="${timezone}" xmlns="uri:oozie:coordinator:0.2">
<controls>
<timeout>-1</timeout>
<concurrency>30</concurrency>
<execution>FIFO</execution>
</controls>
<datasets>
<dataset name="myData" frequency="???" initial-instance="???" timezone="UTC">
<uri-template>/time-independent/path/that/may/or/maynot/be/there</uri-template>
</dataset>
</datasets>
<input-events>
<data-in name="myInput" dataset="myData">
<instance>???</instance>
</data-in>
</input-events>
<action>
<workflow>
<app-path>${myAppPath}</app-path>
<configuration>
<property>
<name>myInput</name>
<value>${coord:dataIn('myInput')}</value>
</property>
</configuration>
</workflow>
</action>
</coordinator-app>
谢谢, 阿尔瓦罗
数据集频率值将为 ${coord:days(1)},因为您希望将其安排在每天。
starttime 将是您要开始作业时的值。例如。 2017-01-22T12:00Z.
因此,更新后的协调器 xml 将是这样的:
<coordinator-app name="${jobName}" frequency="${coord:days(1)}" start="${startTime}" end="${endTime}" timezone="${timezone}"
xmlns="uri:oozie:coordinator:0.2">
<controls>
<timeout>-1</timeout>
<concurrency>30</concurrency>
<execution>FIFO</execution>
</controls>
<datasets>
<dataset name="myData" frequency="${coord:days(1)}" initial-instance="${startTime}" timezone="UTC">
<uri-template>/time-independent/path/that/may/or/maynot/be/there</uri-template>
</dataset>
</datasets>
<input-events>
<data-in name="myInput" dataset="myData">
<instance>${startTime}</instance>
</data-in>
</input-events>
<action>
<workflow>
<app-path>${myAppPath}</app-path>
<configuration>
<property>
<name>myInput</name>
<value>${coord:dataIn('myInput')}</value>
</property>
</configuration>
</workflow>
</action>
</coordinator-app>
是否可以定义可选的输入事件。
例如: 我定义了 4 个输入事件 .. A , B , C 和 D
看起来我们必须使用所有数据集