| <!-- |
| Licensed to the Apache Software Foundation (ASF) under one |
| or more contributor license agreements. See the NOTICE file |
| distributed with this work for additional information |
| regarding copyright ownership. The ASF licenses this file |
| to you under the Apache License, Version 2.0 (the |
| "License"); you may not use this file except in compliance |
| with the License. You may obtain a copy of the License at |
| |
| http://www.apache.org/licenses/LICENSE-2.0 |
| |
| Unless required by applicable law or agreed to in writing, software |
| distributed under the License is distributed on an "AS IS" BASIS, |
| WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| See the License for the specific language governing permissions and |
| limitations under the License. |
| --> |
| <workflow-app xmlns="uri:oozie:workflow:0.4" name="test-wf"> |
| <global> |
| <job-tracker>foo</job-tracker> |
| <name-node>bar</name-node> |
| <job-xml>/spam1</job-xml> |
| <job-xml>/spam2</job-xml> |
| <job-xml>/tmp</job-xml> |
| <configuration> |
| <property> |
| <name>a</name> |
| <value>A</value> |
| </property> |
| <property> |
| <name>b</name> |
| <value>B</value> |
| </property> |
| </configuration> |
| </global> |
| |
| <start to="a"/> |
| <decision name="a"> |
| <switch> |
| <case to="b">true</case> |
| <case to="c">false</case> |
| <default to="c"/> |
| </switch> |
| </decision> |
| <kill name="b"> |
| <message>kill</message> |
| </kill> |
| |
| <fork name="c"> |
| <path start="d"/> |
| <path start="e"/> |
| </fork> |
| |
| <action name="d"> |
| <map-reduce> |
| <prepare> |
| <delete path="/tmp"/> |
| <mkdir path="/tmp"/> |
| </prepare> |
| <streaming> |
| <mapper>/mycat.sh</mapper> |
| <reducer>/mywc.sh</reducer> |
| </streaming> |
| <job-xml>/tmp</job-xml> |
| <file>/tmp</file> |
| <archive>/tmp</archive> |
| </map-reduce> |
| <ok to="f"/> |
| <error to="b"/> |
| </action> |
| |
| <action name="e"> |
| <pig> |
| <prepare> |
| <delete path="/tmp"/> |
| <mkdir path="/tmp"/> |
| </prepare> |
| <configuration> |
| <property> |
| <name>a</name> |
| <value>A2</value> |
| </property> |
| <property> |
| <name>b</name> |
| <value>B</value> |
| </property> |
| </configuration> |
| <script>/tmp</script> |
| <param>x</param> |
| <file>/tmp</file> |
| <file>/tmp</file> |
| </pig> |
| <ok to="f"/> |
| <error to="b"/> |
| </action> |
| |
| <join name="f" to="g"/> |
| |
| <action name="g"> |
| <fs> |
| <mkdir path='/tmp'/> |
| <chmod path='/tmp' permissions='-rwxrw-rw-' dir-files='false'/> |
| <move source='/tmp' target='/tmp2'/> |
| <delete path='/tmp2'/> |
| <mkdir path='/tmp3'/> |
| <delete path='/tmp3'/> |
| </fs> |
| <ok to="z"/> |
| <error to="b"/> |
| </action> |
| |
| <end name="z"/> |
| </workflow-app> |