njnu-seafish commented on code in PR #18063:
URL:
https://github.com/apache/dolphinscheduler/pull/18063#discussion_r2963786031
##########
dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/engine/workflow/lifecycle/handler/WorkflowStartLifecycleEventHandler.java:
##########
@@ -38,11 +40,24 @@ public void handle(final IWorkflowStateAction
workflowStateAction,
final IWorkflowExecutionRunnable
workflowExecutionRunnable,
final WorkflowStartLifecycleEvent workflowStartEvent) {
+ workflowTimeoutMonitor(workflowExecutionRunnable);
workflowStateAction.onStartEvent(workflowExecutionRunnable,
workflowStartEvent);
}
@Override
public ILifecycleEventType matchEventType() {
return WorkflowLifecycleEventType.START;
}
+
+ private void workflowTimeoutMonitor(final IWorkflowExecutionRunnable
workflowExecutionRunnable) {
+ final WorkflowInstance workflowInstance =
workflowExecutionRunnable.getWorkflowInstance();
+ if (workflowInstance.getTimeout() <= 0) {
+ log.debug("The workflow {} timeout {} is invalided, so the timeout
monitor will not be started.",
Review Comment:
okok
--
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]