Skip to content

Commit 553202d

Browse files
author
苏义超
committed
update comment
1 parent e9a8993 commit 553202d

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

dolphinscheduler-master/src/main/java/org/apache/dolphinscheduler/server/master/engine/WorkflowEventBusFireWorker.java

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -131,17 +131,19 @@ private void doFireSingleWorkflowEventBus(final IWorkflowExecutionRunnable workf
131131
ThreadUtils.sleep(5_000);
132132
return;
133133
}
134+
135+
// If task initializeTaskExecutionContext before dispatch is failed
136+
// construct and publish a dedicated TaskFatalLifecycleEvent
137+
// so that the event will be handled by TaskFatalLifecycleEventHandler
134138
if (ExceptionUtils.isTaskExecutionContextCreateException(ex)) {
135-
// If task initializeTaskExecutionContext before dispatch is failed
136-
// construct and publish a dedicated TaskFatalLifecycleEvent
137-
// so that the event will be handled by TaskFatalLifecycleEventHandler
138139
AbstractTaskLifecycleEvent taskLifecycleEvent = (AbstractTaskLifecycleEvent) lifecycleEvent;
139140
final TaskFatalLifecycleEvent taskFatalEvent = TaskFatalLifecycleEvent.builder()
140141
.taskExecutionRunnable(taskLifecycleEvent.getTaskExecutionRunnable())
141142
.endTime(new Date())
142143
.build();
143144
workflowEventBus.publish(taskFatalEvent);
144145
}
146+
145147
workflowEventBus.getWorkflowEventBusSummary().decreaseFireSuccessEventCount();
146148
workflowEventBus.getWorkflowEventBusSummary().increaseFireFailedEventCount();
147149
throw new WorkflowEventFireException(lifecycleEvent, ex);

0 commit comments

Comments
 (0)