You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@oozie.apache.org by "ASF subversion and git services (Jira)" <ji...@apache.org> on 2020/03/02 12:44:00 UTC

[jira] [Commented] (OOZIE-3589) Avoid calling copyActionData method multiple times in ReRunXCommand

    [ https://issues.apache.org/jira/browse/OOZIE-3589?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17049175#comment-17049175 ] 

ASF subversion and git services commented on OOZIE-3589:
--------------------------------------------------------

Commit fcdb729bb13beb46fb69c4cbbfa8a4f06f0c216d in oozie's branch refs/heads/master from Andras Salamon
[ https://gitbox.apache.org/repos/asf?p=oozie.git;h=fcdb729 ]

OOZIE-3589 Avoid calling copyActionData method multiple times in ReRunXCommand (zuston via asalamon74)


> Avoid calling copyActionData method multiple times in ReRunXCommand
> -------------------------------------------------------------------
>
>                 Key: OOZIE-3589
>                 URL: https://issues.apache.org/jira/browse/OOZIE-3589
>             Project: Oozie
>          Issue Type: Bug
>          Components: core
>            Reporter: Junfan Zhang
>            Assignee: Junfan Zhang
>            Priority: Major
>         Attachments: OOZIE-3589-V1.patch
>
>
> Code is [here|https://github.com/apache/oozie/blob/a40ab5361372aa73c9e4aa386a9c81bd21742aa4/core/src/main/java/org/apache/oozie/command/wf/ReRunXCommand.java#L213]. 
> I don't think you should use the {{copyActionData}} method in a {{for}} loop. Just call it externally.
> Fixed like:
> {code:java}
> for (int i = 0; i < actions.size(); i++) {
>             // Skipping to delete the sub workflow when rerun failed node option has been provided. As same
>             // action will be used to rerun the job.
>             if (!nodesToSkip.contains(actions.get(i).getName()) &&
>                     !(conf.getBoolean(OozieClient.RERUN_FAIL_NODES, false) &&
>                     SubWorkflowActionExecutor.ACTION_TYPE.equals(actions.get(i).getType()))) {
>                 deleteList.add(actions.get(i));
>                 LOG.info("Deleting Action[{0}] for re-run", actions.get(i).getId());
>             }
>         }
> copyActionData(newWfInstance, oldWfInstance);
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)