mirror of
https://gitee.com/dolphinscheduler/DolphinScheduler.git
synced 2024-12-04 21:28:00 +08:00
update receiver and cc for child process
This commit is contained in:
parent
30e8b78d61
commit
32f9d17983
@ -890,6 +890,9 @@ public class ProcessDao extends AbstractBaseDao {
|
||||
cmdParam.put(CMDPARAM_COMPLEMENT_DATA_START_DATE, startTime);
|
||||
processMapStr = JSONUtils.toJson(cmdParam);
|
||||
}
|
||||
|
||||
updateSubProcessDefinitionByParent(parentProcessInstance, childDefineId);
|
||||
|
||||
Command command = new Command();
|
||||
command.setWarningType(parentProcessInstance.getWarningType());
|
||||
command.setWarningGroupId(parentProcessInstance.getWarningGroupId());
|
||||
@ -904,6 +907,16 @@ public class ProcessDao extends AbstractBaseDao {
|
||||
logger.info("sub process command created: {} ", command.toString());
|
||||
}
|
||||
|
||||
private void updateSubProcessDefinitionByParent(ProcessInstance parentProcessInstance, int childDefinitionId) {
|
||||
ProcessDefinition fatherDefinition = this.findProcessDefineById(parentProcessInstance.getProcessDefinitionId());
|
||||
ProcessDefinition childDefinition = this.findProcessDefineById(childDefinitionId);
|
||||
if(childDefinition != null && fatherDefinition != null){
|
||||
childDefinition.setReceivers(fatherDefinition.getReceivers());
|
||||
childDefinition.setReceiversCc(fatherDefinition.getReceiversCc());
|
||||
processDefineMapper.update(childDefinition);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* submit task to mysql
|
||||
* @param taskInstance
|
||||
|
Loading…
Reference in New Issue
Block a user