Plot live drive activity every three minutes (#91)
- Change default collection cadence from 5 minutes to 3 minutes (CADENCE_DEFAULT_S=180, systemd OnUnitInactiveSec=3min, runit CADENCE=180) - Update freshness threshold to 450s (2×180 + AccuracySec + 60) - Add _query_live_graph_data(): queries raw samples from the last 3 hours and computes interval byte deltas with actual timestamps - Add LiveActivityGraph widget: vertical bar chart of interval volumes with read/write toggle (w key), arrow key inspection, and click support - Wire live graph into TUI layout (full-width row between daily graph and drive health), refresh cycle, and CSS grid - Replace t theme binding with t today/live binding; theme selection via preferences file - Add w binding for read/write toggle on live graph - Update action legend, help screen, and grid layout for new live-activity row - Add 20 tests covering cadence constants, live query, widget rendering, toggle, and TUI integration - Update all cadence documentation (README, ADR 0003, acceptance criteria LC-2, fenris-redesign constants table, CHANGELOG)
This commit is contained in:
@@ -4,7 +4,7 @@ Documentation=https://git.bongbetic.com/xavierk/Fenris
|
||||
|
||||
[Timer]
|
||||
OnBootSec=2min
|
||||
OnUnitInactiveSec=5min
|
||||
OnUnitInactiveSec=3min
|
||||
AccuracySec=30s
|
||||
Persistent=no
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
#
|
||||
# Guarantees (must match systemd timer semantics):
|
||||
# - Initial 2-minute boot delay (sleep 120 before first collect)
|
||||
# - Completion-relative 5-minute cadence (sleep 300 after collect)
|
||||
# - Completion-relative 3-minute cadence (sleep 180 after collect)
|
||||
# - Bounded execution (timeout 90s on each collect)
|
||||
# - No catch-up (fixed sleep interval, no Persistent=)
|
||||
# - Serialized runs (runsv does not restart until exit)
|
||||
@@ -20,7 +20,7 @@ set -eu
|
||||
|
||||
COLLECT_TIMEOUT=90
|
||||
BOOT_DELAY=120
|
||||
CADENCE=300
|
||||
CADENCE=180
|
||||
LOCK_FILE=/var/lib/fenris/fenris-collect.lock
|
||||
|
||||
# Ensure lock directory exists
|
||||
|
||||
Reference in New Issue
Block a user