njnu-seafish commented on PR #17819:
URL: 
https://github.com/apache/dolphinscheduler/pull/17819#issuecomment-4046408020

   > In DolphinScheduler 3.4.1, when both "Timeout Alert" and "Timeout Failure" 
are selected in the timeout policy settings, only the alert is sent, but the 
task does not fail as expected. Will this be fixed later?
   
   
   Task timeout fail bug is fixed by this PR:   
https://github.com/apache/dolphinscheduler/pull/17818 
   
   I test it as follow: 
   <img width="1923" height="737" alt="企业微信截图_17733185198974" 
src="https://github.com/user-attachments/assets/8a96cee1-d656-4c4b-a7e9-f4b1f6d45236";
 />
   
   > 2026-03-12 20:24:10.819 INFO  - Final Script Content:
   ====================
   #!/bin/bash
   BASEDIR=$(cd `dirname $0`; pwd)
   cd $BASEDIR
   source 
/usr/local/apache-dolphinscheduler-dev-SNAPSHOT-bin/bin/env/dolphinscheduler_env.sh
   sleep 2m;
   ====================
   2026-03-12 20:24:10.820 INFO  - Executing shell command : sudo -u root -i 
/tmp/dolphinscheduler/exec/process/42/42.sh
   2026-03-12 20:24:10.830 INFO  - process start, process id is: 59604
   2026-03-12 20:25:10.866 INFO  - Begin killing task instance, processId: 59604
   2026-03-12 20:25:12.268 INFO  - prepare to parse pid, raw pid string: 
sudo(59604)---42.sh(59609)---sleep(59802)
   
   2026-03-12 20:25:15.785 INFO  - Sending 2 to process group: 59604 59609 
59802, command: sudo -u root -i kill -2 59604 59609 59802
   2026-03-12 20:25:30.036 INFO  - Kill command: sudo -u root -i kill -2 59604 
59609 59802, timed out, still running PIDs: 59604 59609 59802
   2026-03-12 20:25:33.314 INFO  - Sending 15 to process group: 59604 59609 
59802, command: sudo -u root -i kill -15 59604 59609 59802
   2026-03-12 20:25:34.401 ERROR - process has failure due to timeout kill, 
timeout value is:60, timeoutStrategy is:WARNFAILED
   2026-03-12 20:25:34.404 INFO  - process has killed. execute 
path:/tmp/dolphinscheduler/exec/process/42, processId:59604 ,exitStatusCode:-1 
,processWaitForStatus:false ,processExitValue:143
   2026-03-12 20:25:37.716 INFO  - Successfully killed process tree by SIGTERM, 
processId: 59604
   2026-03-12 20:25:37.717 INFO  - Process tree for task: 42 is killed or 
already finished, pid: 59604
   


-- 
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]

Reply via email to