Skip to content

Daily/weekly digest email: scheduled job health summary #78

Description

@csoscd

Summary

Instead of individual alert emails per failure, send a configurable scheduled digest summarising the health of all jobs in one email.

Motivation / Use Case

Operators managing many low-priority jobs don't want inbox noise from individual alerts. A single daily or weekly summary gives an overview of job health without requiring constant attention.

Proposed Behaviour

  • Configurable schedule: daily or weekly, with a configurable send time
  • Each job listed with: last run timestamp, last exit code, 7-day success rate, and current failure streak (if any)
  • Jobs with active failure streaks are highlighted at the top
  • Only sent if there is at least one job to report on
  • Respects existing mail.* config (same sender/recipient as failure alerts)

Affected Component

  • Agent
  • Web UI (config UI for digest settings)

First Implementation Idea

  1. New scheduled scriptbin/send-digest.php queries execution_log and cronjobs for aggregate health data per job and builds the email body.
  2. Crontab entrysend-digest.php is added to the agent container's own crontab at the configured time (daily/weekly). The schedule is written by entrypoint.sh based on config values.
  3. Config keysnotifications.digest.enabled, notifications.digest.frequency (daily/weekly), notifications.digest.send_time (HH:MM), notifications.digest.weekday (0–6, for weekly mode).
  4. Email rendering — plain-text and HTML variants via MailNotifier; a simple table layout per job (name, last run, success rate, streak).
  5. Web UI — digest settings added to the notifications section of the settings/housekeeping page.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions