zhongjiajie commented on code in PR #14343:
URL:
https://github.com/apache/dolphinscheduler/pull/14343#discussion_r1255083627
##########
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/task/SubTaskProcessor.java:
##########
@@ -129,14 +129,29 @@ private void updateTaskState() {
subProcessInstance.getId(),
subProcessInstance.getState());
if (subProcessInstance != null &&
subProcessInstance.getState().isFinished()) {
- // todo: check the status and transform
-
taskInstance.setState(TaskExecutionStatus.of(subProcessInstance.getState().getCode()));
+
taskInstance.setState(subProcessFinishedStateTransform(subProcessInstance.getState()));
taskInstance.setEndTime(new Date());
dealFinish();
processService.saveTaskInstance(taskInstance);
}
}
+ private TaskExecutionStatus
subProcessFinishedStateTransform(WorkflowExecutionStatus state) {
+ if (state.isSuccess()) {
+ return TaskExecutionStatus.SUCCESS;
+ } else if (state.isFailure()) {
+ return TaskExecutionStatus.FAILURE;
+ } else if (state.isStop()) {
+ return TaskExecutionStatus.KILL;
Review Comment:
why we workflow stop is kill?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]