domain/config.go + app: persist global pause state across restarts (T4.1, T4.2)
Add Config.Paused bool so the scheduler's paused flag survives a restart. SetGlobalPause now writes the flag into store.Config and calls SaveConfig; NewService seeds s.paused from Config.Paused before computing first next-run times, so jobs show "Scheduler paused" immediately at startup when paused. Also add Paused to the yamlConfig shadow struct to keep the direct conversion from domain.Config valid until the YAML import path is dropped in T6.3. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -40,6 +40,7 @@ type Config struct {
|
||||
NotifyOnFailure bool `json:"notify_on_failure,omitempty"`
|
||||
ExecutionMode ExecutionMode `json:"execution_mode,omitempty"`
|
||||
OverlapPolicy OverlapPolicy `json:"overlap_policy,omitempty"`
|
||||
Paused bool `json:"paused,omitempty"`
|
||||
}
|
||||
|
||||
// JobsFile is the on-disk shape of jobs.json. Wrapping the slice in a top-level
|
||||
|
||||
Reference in New Issue
Block a user