From 96601fef4c0d293ac33c388d9d99f1c7ac501c85 Mon Sep 17 00:00:00 2001 From: jackfanwan <61672564+jackfanwan@users.noreply.github.com> Date: Wed, 18 Jan 2023 20:08:28 +0800 Subject: [PATCH] fix when the task details are not modified, the predecessor node cannot be modified (#13422) * fix when the task details are not modified, the predecessor node cannot be modified * deleted useless code Co-authored-by: fanwanlong --- .../api/service/impl/TaskDefinitionServiceImpl.java | 7 ------- 1 file changed, 7 deletions(-) diff --git a/dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/service/impl/TaskDefinitionServiceImpl.java b/dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/service/impl/TaskDefinitionServiceImpl.java index 420dbd9c60..fc2c274187 100644 --- a/dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/service/impl/TaskDefinitionServiceImpl.java +++ b/dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/service/impl/TaskDefinitionServiceImpl.java @@ -573,9 +573,6 @@ public class TaskDefinitionServiceImpl extends BaseServiceImpl implements TaskDe Map result = new HashMap<>(); TaskDefinitionLog taskDefinitionToUpdate = updateTask(loginUser, projectCode, taskCode, taskDefinitionJsonObj, result); - if (result.get(Constants.STATUS) != Status.SUCCESS && taskDefinitionToUpdate == null) { - return result; - } List upstreamTaskRelations = processTaskRelationMapper.queryUpstreamByCode(projectCode, taskCode); Set upstreamCodeSet = @@ -588,10 +585,6 @@ public class TaskDefinitionServiceImpl extends BaseServiceImpl implements TaskDe if (CollectionUtils.isEqualCollection(upstreamCodeSet, upstreamTaskCodes) && taskDefinitionToUpdate == null) { putMsg(result, Status.SUCCESS); return result; - } else { - if (taskDefinitionToUpdate == null) { - taskDefinitionToUpdate = JSONUtils.parseObject(taskDefinitionJsonObj, TaskDefinitionLog.class); - } } Map queryUpStreamTaskCodeMap; if (CollectionUtils.isNotEmpty(upstreamTaskCodes)) {