Skip to content
  • Michael Olbrich's avatar
    service: add watchdog timestamp · a6927d7f
    Michael Olbrich authored
    This patch adds WatchdogTimestamp[Monotonic] to the systemd service
    D-Bus API. The timestamp is updated to the current time when the
    service calls 'sd_nofity("WATCHDOG=1\n")'.
    Using a timestamp instead of an 'alive' flag has two advantages:
    1. No timeout is needed to define when a service is no longer alive.
       This simplifies both configuration (no timeout value) and
       implementation (no timeout event).
    2. It is more robust. A 'dead' service might not be detected should
        systemd 'forget' to reset an 'alive' flag. It is much less likely
        to get a valid new timestamp if a service died.
    a6927d7f