From cea8ae69916039b55e84482b5c0703f3c62ef9c5 Mon Sep 17 00:00:00 2001 From: OS <29528966+lenboo@users.noreply.github.com> Date: Wed, 13 Oct 2021 11:36:27 +0800 Subject: [PATCH] 6471: cache process definition in master (#6511) --- .../dolphinscheduler/service/process/ProcessService.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dolphinscheduler-service/src/main/java/org/apache/dolphinscheduler/service/process/ProcessService.java b/dolphinscheduler-service/src/main/java/org/apache/dolphinscheduler/service/process/ProcessService.java index 27443fd10..2f1f632db 100644 --- a/dolphinscheduler-service/src/main/java/org/apache/dolphinscheduler/service/process/ProcessService.java +++ b/dolphinscheduler-service/src/main/java/org/apache/dolphinscheduler/service/process/ProcessService.java @@ -1237,7 +1237,7 @@ public class ProcessService { CommandType commandType = getSubCommandType(parentProcessInstance, childInstance); Map subProcessParam = JSONUtils.toMap(task.getTaskParams()); int childDefineId = Integer.parseInt(subProcessParam.get(Constants.CMD_PARAM_SUB_PROCESS_DEFINE_ID)); - ProcessDefinition processDefinition = processDefineMapper.queryByDefineId(childDefineId); + ProcessDefinition subProcessDefinition = processDefineMapper.queryByDefineId(childDefineId); Object localParams = subProcessParam.get(Constants.LOCAL_PARAMS); List allParam = JSONUtils.toList(JSONUtils.toJsonString(localParams), Property.class); @@ -1255,7 +1255,7 @@ public class ProcessService { TaskDependType.TASK_POST, parentProcessInstance.getFailureStrategy(), parentProcessInstance.getExecutorId(), - processDefinition.getCode(), + subProcessDefinition.getCode(), processParam, parentProcessInstance.getWarningType(), parentProcessInstance.getWarningGroupId(), @@ -1265,7 +1265,7 @@ public class ProcessService { parentProcessInstance.getProcessInstancePriority(), parentProcessInstance.getDryRun(), subProcessInstanceId, - parentProcessInstance.getProcessDefinitionVersion() + subProcessDefinition.getVersion() ); } -- GitLab