[
https://issues.apache.org/jira/browse/OOZIE-1810?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Azrael updated OOZIE-1810:
--------------------------
Attachment: OOZIE-1810.patch
CommandException is for the print error message, It does not handle the
exception condition. I think we need ActionExcutorException for XCommand.call()
and handle it as ErrorType
{code}
try {
new SignalXCommand(jobId, actionId).call(getEntityKey());
} catch (ActionExecutorException ex) {
switch (ex.getErrorType()) {
case FAILED:
wfAction.setErrorInfo(ex.getErrorCode().toString(),
ex.getMessage());
wfAction.setEndTime(null);
failJob(context);
break;
default:
}
...
}
{code}
> Workflow cannot get into Failed state when kill control node cannot resolve
> variable in message
> ------------------------------------------------------------------------------------------------
>
> Key: OOZIE-1810
> URL: https://issues.apache.org/jira/browse/OOZIE-1810
> Project: Oozie
> Issue Type: Bug
> Reporter: Bing Jiang
> Assignee: Azrael
> Attachments: OOZIE-1810.patch
>
>
> ====workflow.xml======
> <workflow-app name='test-kill-wf' xmlns="uri:oozie:workflow:0.3">
> <start to='fail'/>
> <kill name="fail">
> <message>${TryError} error
> message[${wf:errorMessage(wf:lastErrorNode())}]</message>
> </kill>
> <end name="end"/>
> </workflow-app>
> There is no definition about ${TryError} in job.properties.
> Workflow job are stuck at RUNNING state, and it is always trying to resolve
> the variable [TryError] in kill action's message.
> ======Exception from oozie log ========
> ACTION[****-*************-oozie-wrkf-W@fail] XException,
> org.apache.oozie.command.CommandException: E0729: Kill node message [fail]
> at
> org.apache.oozie.command.wf.SignalXCommand.execute(SignalXCommand.java:292)
> at
> org.apache.oozie.command.wf.SignalXCommand.execute(SignalXCommand.java:66)
> at org.apache.oozie.command.XCommand.call(XCommand.java:280)
> at
> org.apache.oozie.service.CallableQueueService$CallableWrapper.run(CallableQueueService.java:175)
> at
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
> at java.lang.Thread.run(Thread.java:722)
> Caused by: javax.servlet.jsp.el.ELException: variable [TryError] cannot be
> resolved
> at
> org.apache.oozie.util.ELEvaluator$Context.resolveVariable(ELEvaluator.java:106)
> at org.apache.commons.el.NamedValue.evaluate(NamedValue.java:124)
> at
> org.apache.commons.el.ExpressionString.evaluate(ExpressionString.java:114)
> at
> org.apache.commons.el.ExpressionEvaluatorImpl.evaluate(ExpressionEvaluatorImpl.java:274)
> at
> org.apache.commons.el.ExpressionEvaluatorImpl.evaluate(ExpressionEvaluatorImpl.java:190)
> at org.apache.oozie.util.ELEvaluator.evaluate(ELEvaluator.java:203)
> at
> org.apache.oozie.command.wf.SignalXCommand.execute(SignalXCommand.java:277)
> ... 6 more
> ===================
> when it runs into the resolve error upon control nodes' message, oozie
> action should enter into Failed state as soon as possible.
--
This message was sent by Atlassian JIRA
(v6.2#6252)