You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dolphinscheduler.apache.org by ji...@apache.org on 2021/10/13 03:36:35 UTC

[dolphinscheduler] branch dev updated: 6471: cache process definition in master (#6511)

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

jinyleechina pushed a commit to branch dev
in repository https://gitbox.apache.org/repos/asf/dolphinscheduler.git


The following commit(s) were added to refs/heads/dev by this push:
     new cea8ae6   6471: cache process definition in master (#6511)
cea8ae6 is described below

commit cea8ae69916039b55e84482b5c0703f3c62ef9c5
Author: OS <29...@users.noreply.github.com>
AuthorDate: Wed Oct 13 11:36:27 2021 +0800

     6471: cache process definition in master (#6511)
---
 .../org/apache/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 27443fd..2f1f632 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<String, String> 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<Property> 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()
         );
     }