You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dolphinscheduler.apache.org by GitBox <gi...@apache.org> on 2022/02/15 03:48:08 UTC

[GitHub] [dolphinscheduler] caishunfeng commented on a change in pull request #8387: [Fix-8337][Master] Process instance can not be kill when task is failure and can be retry

caishunfeng commented on a change in pull request #8387:
URL: https://github.com/apache/dolphinscheduler/pull/8387#discussion_r806422408



##########
File path: dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteThread.java
##########
@@ -1437,14 +1444,10 @@ private ExecutionStatus processReadyPause() {
     private ExecutionStatus getProcessInstanceState(ProcessInstance instance) {
         ExecutionStatus state = instance.getState();
 
-        if (activeTaskProcessorMaps.size() > 0 || hasRetryTaskInStandBy()) {
+        if ((activeTaskProcessorMaps.size() > 0 || hasRetryTaskInStandBy()) && state != ExecutionStatus.READY_STOP) {

Review comment:
       Is it better to put the process instance state check before? 

##########
File path: dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/runner/WorkflowExecuteThread.java
##########
@@ -1615,6 +1645,9 @@ private void killAllTasks() {
             }
             TaskInstance taskInstance = processService.findTaskInstanceById(taskInstanceId);
             if (taskInstance == null || taskInstance.getState().typeIsFinished()) {
+                if (readyToSubmitTaskQueue.size() > 0) {

Review comment:
       Why to clear submit task queue when some taskInstance is null or finish?




-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org