Merge lp:~fo0bar/turku/turku-agent-timers into lp:turku/turku-agent

Proposed by Ryan Finnie
Status: Merged
Approved by: Joel Sing
Approved revision: 55
Merged at revision: 56
Proposed branch: lp:~fo0bar/turku/turku-agent-timers
Merge into: lp:turku/turku-agent
Diff against target: 41 lines (+4/-12)
2 files modified
turku-agent-ping.timer (+2/-6)
turku-update-config.timer (+2/-6)
To merge this branch: bzr merge lp:~fo0bar/turku/turku-agent-timers
Reviewer Review Type Date Requested Status
Joel Sing (community) +1 Approve
Review via email: mp+381281@code.launchpad.net

Commit message

Switch timers from OnCalendar (+ dependency hacks) to monotonic OnUnitActiveSec/OnStartupSec

Description of the change

This mostly reverts revno 54's fixes for the startup edge case by switching to systemd's monotonic system. First timer is run 15m + rand(5m) after startup, then every 5m + rand(5m).

To post a comment you must log in.
Revision history for this message
🤖 Canonical IS Merge Bot (canonical-is-mergebot) wrote :

This merge proposal is being monitored by mergebot. Change the status to Approved to merge.

Revision history for this message
Joel Sing (jsing) wrote :

LGTM

review: Approve (+1)
Revision history for this message
🤖 Canonical IS Merge Bot (canonical-is-mergebot) wrote :

Change successfully merged at revision 56

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'turku-agent-ping.timer'
2--- turku-agent-ping.timer 2020-03-24 01:04:54 +0000
3+++ turku-agent-ping.timer 2020-03-26 22:16:38 +0000
4@@ -1,14 +1,10 @@
5 [Unit]
6 Description=turku-agent-ping
7-DefaultDependencies=no
8-Wants=network-online.target
9-After=network-online.target
10-After=time-sync.target
11
12 [Timer]
13-OnCalendar=*:0/5
14+OnUnitActiveSec=5m
15 RandomizedDelaySec=5m
16-Persistent=true
17+OnStartupSec=15m
18
19 [Install]
20 WantedBy=timers.target
21
22=== modified file 'turku-update-config.timer'
23--- turku-update-config.timer 2020-03-24 01:04:54 +0000
24+++ turku-update-config.timer 2020-03-26 22:16:38 +0000
25@@ -1,14 +1,10 @@
26 [Unit]
27 Description=turku-update-config
28-DefaultDependencies=no
29-Wants=network-online.target
30-After=network-online.target
31-After=time-sync.target
32
33 [Timer]
34-OnCalendar=0,12:0
35+OnUnitActiveSec=12h
36 RandomizedDelaySec=12h
37-Persistent=true
38+OnStartupSec=1h
39
40 [Install]
41 WantedBy=timers.target

Subscribers

People subscribed via source and target branches

to all changes: