|
|
|
@ -135,7 +135,7 @@ import com.google.common.collect.Sets;
|
|
|
|
|
* Workflow execute task, used to execute a workflow instance. |
|
|
|
|
*/ |
|
|
|
|
@Slf4j |
|
|
|
|
public class WorkflowExecuteRunnable implements Callable<WorkflowSubmitStatue> { |
|
|
|
|
public class WorkflowExecuteRunnable implements Callable<WorkflowSubmitStatus> { |
|
|
|
|
|
|
|
|
|
private final ProcessService processService; |
|
|
|
|
|
|
|
|
@ -720,11 +720,11 @@ public class WorkflowExecuteRunnable implements Callable<WorkflowSubmitStatue> {
|
|
|
|
|
* ProcessInstance start entrypoint. |
|
|
|
|
*/ |
|
|
|
|
@Override |
|
|
|
|
public WorkflowSubmitStatue call() { |
|
|
|
|
public WorkflowSubmitStatus call() { |
|
|
|
|
if (isStart()) { |
|
|
|
|
// This case should not been happened
|
|
|
|
|
log.warn("[WorkflowInstance-{}] The workflow has already been started", processInstance.getId()); |
|
|
|
|
return WorkflowSubmitStatue.DUPLICATED_SUBMITTED; |
|
|
|
|
return WorkflowSubmitStatus.DUPLICATED_SUBMITTED; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
try { |
|
|
|
@ -744,10 +744,10 @@ public class WorkflowExecuteRunnable implements Callable<WorkflowSubmitStatue> {
|
|
|
|
|
workflowRunnableStatus = WorkflowRunnableStatus.STARTED; |
|
|
|
|
log.info("workflowStatue changed to :{}", workflowRunnableStatus); |
|
|
|
|
} |
|
|
|
|
return WorkflowSubmitStatue.SUCCESS; |
|
|
|
|
return WorkflowSubmitStatus.SUCCESS; |
|
|
|
|
} catch (Exception e) { |
|
|
|
|
log.error("Start workflow error", e); |
|
|
|
|
return WorkflowSubmitStatue.FAILED; |
|
|
|
|
return WorkflowSubmitStatus.FAILED; |
|
|
|
|
} finally { |
|
|
|
|
LogUtils.removeWorkflowInstanceIdMDC(); |
|
|
|
|
} |
|
|
|
|