ErikHabanero
ErikHabanero

Reputation: 365

How do I name sub-workflow actions in parent workflow?

I have created an Oozie workflow that consists of multiple sub-workflow actions. When the workflow is executed and I look at it in HUE and in the graph tab all the actions are named subworkflow and therefor no way to distinguish between them other than clicking on the sub-workflow action that takes you to a new page but this is obviously very inefficient.

How can I explicitly name each sub-workflow action so that I can see the name in the graph instead of just the generic name subworkflow?

Please see attached screenshot. workflow screendump example

I'm running Oozie version 4.1.0-cdh5.10.0 & HUE 3

Upvotes: 2

Views: 201

Answers (2)

maxime G
maxime G

Reputation: 1771

without HUE, using xml workflow, you can pass workflow name from your parent workflow.

main workflow:

...
     <action name="start_child1_wf">
            <sub-workflow>
                <app-path>${oozieWfpathchild1}</app-path>
                <propagate-configuration/>
                <configuration>
                    <property>
                        <name>wfName</name>
                        <value>SUB_WF_NAME_HERE</value>
                    </property>
                </configuration>
            </sub-workflow>
            <ok to="end_all_workflow"/>
            <error to="end_all_workflow"/>
        </action>
    ...

child sub workflow:

<workflow-app xmlns="uri:oozie:workflow:0.5" name="${wfName}">
    <global>
...

In this way you define a new wfName for the sub wf.

Upvotes: 1

You can edit the workfolw name as below,

enter image description here

Or edit the json file with name: "/subworkflow"/

Upvotes: -1

Related Questions