Skip to content

Commit

Permalink
[Chore] python gateway unable to execute workflow (#16969)
Browse files Browse the repository at this point in the history
  • Loading branch information
zhongjiajie authored Jan 22, 2025
1 parent 2ae4402 commit 352b47b
Showing 1 changed file with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,11 @@
import org.apache.dolphinscheduler.api.service.UsersService;
import org.apache.dolphinscheduler.api.service.WorkflowDefinitionService;
import org.apache.dolphinscheduler.common.constants.Constants;
import org.apache.dolphinscheduler.common.enums.CommandType;
import org.apache.dolphinscheduler.common.enums.ComplementDependentMode;
import org.apache.dolphinscheduler.common.enums.ExecutionOrder;
import org.apache.dolphinscheduler.common.enums.FailureStrategy;
import org.apache.dolphinscheduler.common.enums.Flag;
import org.apache.dolphinscheduler.common.enums.Priority;
import org.apache.dolphinscheduler.common.enums.ReleaseState;
import org.apache.dolphinscheduler.common.enums.RunMode;
Expand Down Expand Up @@ -370,11 +372,9 @@ private void createOrUpdateSchedule(User user,
public void execWorkflowInstance(String userName,
String projectName,
String workflowName,
String cronTime,
String workerGroup,
String warningType,
Integer warningGroupId,
Integer timeout) {
Integer warningGroupId) {
User user = usersService.queryUser(userName);
Project project = projectMapper.queryByName(projectName);
WorkflowDefinition workflowDefinition =
Expand All @@ -389,6 +389,10 @@ public void execWorkflowInstance(String userName,
.workerGroup(workerGroup)
.warningType(WarningType.of(warningType))
.warningGroupId(warningGroupId)
.execType(CommandType.START_PROCESS)
.taskDependType(TaskDependType.TASK_POST)
.dryRun(Flag.NO)
.testFlag(Flag.NO)
.build();
executorService.triggerWorkflowDefinition(workflowTriggerRequest);
}
Expand Down

0 comments on commit 352b47b

Please sign in to comment.