Skip to content
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

[ISSUE 565] Implement Timeout Configuration for DAG Tasks #660

Merged
merged 1 commit into from
Aug 11, 2024

Conversation

Kiyo510
Copy link
Contributor

@Kiyo510 Kiyo510 commented Aug 11, 2024

Fixes: #565

Modified to allow timeouts to be set for DAG task execution.

time=2024-08-11T14:41:08.210+09:00 level=INFO msg="Workflow execution initiated" workflow=test2 requestID=0553ba38-1861-4a35-a0c5-5a9196e6f1ca logFile=/Users/kiyofumi.sano/.dagu/logs/start_test2.20240811.14:41:08.210.0553ba38.log
time=2024-08-11T14:41:08.213+09:00 level=INFO msg="Step execution started" step=step1
time=2024-08-11T14:41:08.214+09:00 level=INFO msg="Step execution started" step=step4
time=2024-08-11T14:41:08.214+09:00 level=INFO msg="Step execution started" step=step5
time=2024-08-11T14:41:09.231+09:00 level=INFO msg="Step execution finished" step=step1 status=finished
time=2024-08-11T14:41:09.324+09:00 level=INFO msg="Step execution started" step=step2
time=2024-08-11T14:41:09.324+09:00 level=INFO msg="Step execution started" step=step6
time=2024-08-11T14:41:10.215+09:00 level=INFO msg="Step execution deadline exceeded" step=step4 error="signal: killed"
time=2024-08-11T14:41:10.215+09:00 level=INFO msg="Step execution deadline exceeded" step=step6 error="signal: killed"
time=2024-08-11T14:41:10.215+09:00 level=INFO msg="Step execution deadline exceeded" step=step2 error="signal: killed"
time=2024-08-11T14:41:10.215+09:00 level=INFO msg="Step execution deadline exceeded" step=step5 error="signal: killed"
time=2024-08-11T14:41:10.216+09:00 level=INFO msg="Step execution finished" step=step4 status=canceled
time=2024-08-11T14:41:10.220+09:00 level=INFO msg="Step execution finished" step=step6 status=canceled
time=2024-08-11T14:41:10.224+09:00 level=INFO msg="Step execution finished" step=step2 status=canceled
time=2024-08-11T14:41:10.227+09:00 level=INFO msg="Step execution finished" step=step5 status=canceled
time=2024-08-11T14:41:10.334+09:00 level=INFO msg="Workflow execution finished" status=failed

Summary ->
+--------------------------------------+-------+---------------------------+---------------------------+--------+--------+----------------+
| REQUESTID                            | NAME  | STARTED AT                | FINISHED AT               | STATUS | PARAMS | ERROR          |
+--------------------------------------+-------+---------------------------+---------------------------+--------+--------+----------------+
| 0553ba38-1861-4a35-a0c5-5a9196e6f1ca | test2 | 2024-08-11T14:41:08+09:00 | 2024-08-11T14:41:10+09:00 | failed |        | signal: killed |
+--------------------------------------+-------+---------------------------+---------------------------+--------+--------+----------------+
Details ->
+---+-------+---------------------------+---------------------------+----------+----------+----------------+
| # | STEP  | STARTED AT                | FINISHED AT               | STATUS   | COMMAND  | ERROR          |
+---+-------+---------------------------+---------------------------+----------+----------+----------------+
| 1 | step1 | 2024-08-11T14:41:08+09:00 | 2024-08-11T14:41:09+09:00 | finished | sleep 1  |                |
| 2 | step2 | 2024-08-11T14:41:09+09:00 | 2024-08-11T14:41:10+09:00 | canceled | sleep 10 | signal: killed |
| 3 | step3 | -                         | -                         | canceled | sleep5   |                |
| 4 | step4 | 2024-08-11T14:41:08+09:00 | 2024-08-11T14:41:10+09:00 | canceled | sleep 4  | signal: killed |
| 5 | step5 | 2024-08-11T14:41:08+09:00 | 2024-08-11T14:41:10+09:00 | canceled | sleep 5  | signal: killed |
| 6 | step6 | 2024-08-11T14:41:09+09:00 | 2024-08-11T14:41:10+09:00 | canceled | sleep 1  | signal: killed |
+---+-------+---------------------------+---------------------------+----------+----------+----------------+time=2024-08-11T14:41:10.343+09:00 level=ERROR msg="Workflow execution failed" error="signal: killed" workflow=test2 requestID=0553ba38-1861-4a35-a0c5-5a9196e6f1ca

@Kiyo510 Kiyo510 force-pushed the issue_565_implement_timeout branch from 95a81ca to 88d30a6 Compare August 11, 2024 05:51
@Kiyo510 Kiyo510 marked this pull request as draft August 11, 2024 05:53
@Kiyo510 Kiyo510 marked this pull request as ready for review August 11, 2024 05:53
Copy link

codecov bot commented Aug 11, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Please upload report for BASE (main@6165756). Learn more about missing BASE report.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             main     #660   +/-   ##
=======================================
  Coverage        ?   66.37%           
=======================================
  Files           ?       53           
  Lines           ?     4173           
  Branches        ?        0           
=======================================
  Hits            ?     2770           
  Misses          ?     1183           
  Partials        ?      220           
Files Coverage Δ
internal/agent/agent.go 74.40% <100.00%> (ø)
internal/dag/builder.go 78.52% <100.00%> (ø)
internal/dag/dag.go 76.59% <ø> (ø)
internal/dag/scheduler/scheduler.go 88.13% <100.00%> (ø)

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 6165756...88d30a6. Read the comment docs.

Copy link
Collaborator

@yohamta yohamta left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✨✨✨LGTM✨✨🚀, thank you very much for the amazing work!

@yohamta yohamta merged commit a756068 into dagu-org:main Aug 11, 2024
8 checks passed
@Kiyo510 Kiyo510 deleted the issue_565_implement_timeout branch August 11, 2024 08:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement Timeout Configuration for DAG Tasks
2 participants