You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: dolphinscheduler-task-plugin/dolphinscheduler-task-api/src/main/java/org/apache/dolphinscheduler/plugin/task/api/AbstractCommandExecutor.java
+8-6
Original file line number
Diff line number
Diff line change
@@ -216,13 +216,15 @@ public void cancelApplication() throws InterruptedException {
216
216
return;
217
217
}
218
218
219
-
// soft kill
220
-
log.info("Begin to kill process process, pid is : {}", taskRequest.getProcessId());
221
-
process.destroy();
222
-
if (!process.waitFor(5, TimeUnit.SECONDS)) {
223
-
process.destroyForcibly();
219
+
// Try to kill process tree
220
+
booleankilled = ProcessUtils.kill(taskRequest);
221
+
if (killed) {
222
+
log.info("Process tree for task: {} is killed or already finished, pid: {}",
Copy file name to clipboardExpand all lines: dolphinscheduler-task-plugin/dolphinscheduler-task-api/src/main/java/org/apache/dolphinscheduler/plugin/task/api/shell/BaseLinuxShellInterceptorBuilder.java
Copy file name to clipboardExpand all lines: dolphinscheduler-task-plugin/dolphinscheduler-task-api/src/main/java/org/apache/dolphinscheduler/plugin/task/api/utils/ProcessUtils.java
Copy file name to clipboardExpand all lines: dolphinscheduler-task-plugin/dolphinscheduler-task-api/src/test/java/org/apache/dolphinscheduler/plugin/task/api/utils/ProcessUtilsTest.java
0 commit comments