addActionCron(wfAction.getType(), cron);
wfAction.resetPending();
wfAction.setStatus(WorkflowActionBean.Status.KILLED);
jpaService.execute(new WorkflowActionUpdateJPAExecutor(wfAction));
jpaService.execute(new WorkflowJobUpdateJPAExecutor(wfJob));
// Add SLA status event (KILLED) for WF_ACTION
SLADbXOperations.writeStausEvent(wfAction.getSlaXml(), wfAction.getId(), Status.KILLED,
SlaAppType.WORKFLOW_ACTION);
queue(new NotificationXCommand(wfJob, wfAction));
}
catch (ActionExecutorException ex) {
wfAction.resetPending();
wfAction.setStatus(WorkflowActionBean.Status.FAILED);
wfAction.setErrorInfo(ex.getErrorCode().toString(),
"KILL COMMAND FAILED - exception while executing job kill");
wfJob.setStatus(WorkflowJobBean.Status.KILLED);
try {
jpaService.execute(new WorkflowActionUpdateJPAExecutor(wfAction));
jpaService.execute(new WorkflowJobUpdateJPAExecutor(wfJob));
}
catch (JPAExecutorException je) {
throw new CommandException(je);
}