feat: make global default timeout 0 (infinite) instead of required 30s

DefaultTimeoutSeconds now means "no timeout" when 0/empty, and that is
the new default, rather than an invalid config forcing a positive
value. runner.RunJob avoids context.WithTimeout with a zero duration
(which would expire immediately) and instead runs on a plain
cancelable context when no timeout is configured. Per-job
TimeoutSeconds inherit semantics are unchanged.
This commit is contained in:
mixeme
2026-07-26 13:57:03 +03:00
parent 3992b40eda
commit 33a246cd13
14 changed files with 75 additions and 23 deletions
+1
View File
@@ -18,5 +18,6 @@ type Job struct {
// TimeoutSeconds bounds how long a run may take before it is killed. 0 means
// "inherit the global Config.DefaultTimeoutSeconds", mirroring OverlapPolicy:
// normalizeJobs must leave 0 untouched rather than backfilling the default.
// The inherited global default may itself be 0, meaning no timeout at all.
TimeoutSeconds int `json:"timeout_seconds,omitempty"`
}