SbloodyS commented on code in PR #16790:
URL:
https://github.com/apache/dolphinscheduler/pull/16790#discussion_r1855871770
##########
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/engine/executor/plugin/dynamic/DynamicLogicTask.java:
##########
@@ -100,28 +102,27 @@ public DynamicLogicTask(TaskExecutionContext
taskExecutionContext,
this.taskInstance =
taskInstanceDao.queryById(taskExecutionContext.getTaskInstanceId());
}
- @Override
- public AsyncTaskExecuteFunction getAsyncTaskExecuteFunction() throws
MasterTaskExecuteException {
- List<Map<String, String>> parameterGroup = generateParameterGroup();
-
- if (parameterGroup.size() >
taskParameters.getMaxNumOfSubWorkflowInstances()) {
- log.warn("the number of sub process instances [{}] exceeds the
maximum limit [{}]", parameterGroup.size(),
- taskParameters.getMaxNumOfSubWorkflowInstances());
- parameterGroup = parameterGroup.subList(0,
taskParameters.getMaxNumOfSubWorkflowInstances());
- }
-
- // if already exists sub process instance, do not generate again
- List<WorkflowInstance> existsSubWorkflowInstanceList =
-
subWorkflowService.getAllDynamicSubWorkflow(workflowInstance.getId(),
taskInstance.getTaskCode());
- if (CollectionUtils.isEmpty(existsSubWorkflowInstanceList)) {
- generateSubWorkflowInstance(parameterGroup);
- } else {
- resetProcessInstanceStatus(existsSubWorkflowInstanceList);
- }
- return new DynamicAsyncTaskExecuteFunction(taskExecutionContext,
workflowInstance, taskInstance, this,
- commandMapper,
- subWorkflowService, taskParameters.getDegreeOfParallelism());
- }
+ // public AsyncTaskExecuteFunction getAsyncTaskExecuteFunction() throws
MasterTaskExecuteException {
+ // List<Map<String, String>> parameterGroup = generateParameterGroup();
+ //
+ // if (parameterGroup.size() >
dynamicParameters.getMaxNumOfSubWorkflowInstances()) {
+ // log.warn("the number of sub process instances [{}] exceeds the maximum
limit [{}]", parameterGroup.size(),
+ // dynamicParameters.getMaxNumOfSubWorkflowInstances());
+ // parameterGroup = parameterGroup.subList(0,
dynamicParameters.getMaxNumOfSubWorkflowInstances());
+ // }
+ //
+ // // if already exists sub process instance, do not generate again
+ // List<WorkflowInstance> existsSubWorkflowInstanceList =
+ // subWorkflowService.getAllDynamicSubWorkflow(workflowInstance.getId(),
taskInstance.getTaskCode());
+ // if (CollectionUtils.isEmpty(existsSubWorkflowInstanceList)) {
+ // generateSubWorkflowInstance(parameterGroup);
+ // } else {
+ // resetProcessInstanceStatus(existsSubWorkflowInstanceList);
+ // }
+ // return new DynamicAsyncTaskExecuteFunction(taskExecutionContext,
workflowInstance, taskInstance, this,
+ // commandMapper,
+ // subWorkflowService, dynamicParameters.getDegreeOfParallelism());
+ // }
Review Comment:
Ok.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]