This is an automated email from the ASF dual-hosted git repository.

zhongjiajie pushed a commit to branch 3.0.6-prepare
in repository https://gitbox.apache.org/repos/asf/dolphinscheduler.git


The following commit(s) were added to refs/heads/3.0.6-prepare by this push:
     new a626b4ccce [fix-#14086]The subprocess type node is always in the ready 
stop state (#14087)
a626b4ccce is described below

commit a626b4cccec0173a1e242e9607c843378701544b
Author: fuchanghai <[email protected]>
AuthorDate: Thu May 18 11:13:51 2023 +0800

    [fix-#14086]The subprocess type node is always in the ready stop state 
(#14087)
---
 .../dolphinscheduler/server/master/runner/task/SubTaskProcessor.java  | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git 
a/dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/task/SubTaskProcessor.java
 
b/dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/task/SubTaskProcessor.java
index 6c27adae57..2f0b23c4cb 100644
--- 
a/dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/task/SubTaskProcessor.java
+++ 
b/dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/task/SubTaskProcessor.java
@@ -163,7 +163,7 @@ public class SubTaskProcessor extends BaseTaskProcessor {
 
     private boolean pauseSubWorkFlow() {
         ProcessInstance subProcessInstance = 
processService.findSubProcessInstance(processInstance.getId(), 
taskInstance.getId());
-        if (subProcessInstance == null || 
taskInstance.getState().typeIsFinished()) {
+        if (subProcessInstance == null || 
taskInstance.getState().typeIsFinished() || 
subProcessInstance.getState().typeIsFinished()) {
             return false;
         }
         subProcessInstance.setState(ExecutionStatus.READY_PAUSE);
@@ -198,7 +198,7 @@ public class SubTaskProcessor extends BaseTaskProcessor {
     @Override
     protected boolean killTask() {
         ProcessInstance subProcessInstance = 
processService.findSubProcessInstance(processInstance.getId(), 
taskInstance.getId());
-        if (subProcessInstance == null || 
taskInstance.getState().typeIsFinished()) {
+        if (subProcessInstance == null || 
taskInstance.getState().typeIsFinished() || 
subProcessInstance.getState().typeIsFinished()) {
             return false;
         }
         subProcessInstance.setState(ExecutionStatus.READY_STOP);

Reply via email to