8000 [#1013] fix: prevent zombie processes in DAG execution by yottahmd · Pull Request #1024 · dagu-org/dagu · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

[#1013] fix: prevent zombie processes in DAG execution #1024

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 18, 2025
Merged

Conversation

yottahmd
Copy link
Collaborator
@yottahmd yottahmd commented Jun 18, 2025

Summary

  • Add proper process cleanup by calling cmd.Wait() in goroutines after cmd.Start()

Change

  • Modified StartDAGRun, RestartDAG, and RetryDAGRun to wait for child processes
  • Each cmd.Start() is now followed by a goroutine that calls cmd.Wait()

Why

When cmd.Start() is called without a corresponding cmd.Wait(), the child process becomes a zombie after it terminates.

Issue: #1013

@yottahmd yottahmd changed the title fix: prevent zombie processes in DAG execution [#1013] fix: prevent zombie processes in DAG execution Jun 18, 2025
Copy link

Deploying dagu-doc with  Cloudflare Pages  Cloudflare Pages

Latest commit: 6771024
Status: ✅  Deploy successful!
Preview URL: https://20194699.dagu-doc.pages.dev
Branch Preview URL: https://1023-zombie.dagu-doc.pages.dev

View logs

@yottahmd yottahmd merged commit 61fb9a2 into main Jun 18, 2025
6 checks passed
@yottahmd yottahmd deleted the 1023-zombie branch June 18, 2025 01:27
Copy link
codecov bot commented Jun 18, 2025

Codecov Report

Attention: Patch coverage is 40.90909% with 26 lines in your changes missing coverage. Please review.

Project coverage is 67.63%. Comparing base (d9eaa13) to head (6771024).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
internal/dagrun/manager.go 40.90% 22 Missing and 4 partials ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #1024      +/-   ##
==========================================
- Coverage   67.68%   67.63%   -0.06%     
==========================================
  Files          93       93              
  Lines       13840    13878      +38     
==========================================
+ Hits         9368     9386      +18     
- Misses       3672     3690      +18     
- Partials      800      802       +2     
Files with missing lines Coverage Δ
internal/dagrun/manager.go 38.16% <40.90%> (-0.84%) ⬇️

... and 1 file with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d9eaa13...6771024. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. A 5634 lready have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant
0