Skip to main content

heartbeat

Function heartbeat 

Source
pub fn heartbeat() -> Action
Expand description

The “steady-state heartbeat” requeue action — after_secs(HEARTBEAT_SECONDS).

The ONE substrate owner of the “default periodic reconcile heartbeat” requeue intent. Pre-lift bound at 11 workspace-wide sites past the ★★ PRIME-DIRECTIVE ≥ 2 duplication threshold across three files:

  • tatara-reconciler::phase_machine — 7 sites fed the local const HEARTBEAT: u64 = 30; at handler tails that maintain steady-state re-observation (forking / execing / running / attested / reconverging / releasing / failed).
  • tatara-reconciler::controller — 2 sites fed a bare 30 literal at the reconcile-error sink and the error_policy return (both semantically “back off to the default heartbeat after an error”).
  • tatara-reconciler::table_controller — 2 sites fed a bare 30 literal at the ProcessTable heartbeat return and its error_policy return.

Post-lift each callsite reads tatara_process::requeue::heartbeat(). Peer to tick and short_retry on the “named requeue intent” axis; each future controller that wants the workspace-canonical heartbeat cadence lands as ONE new callsite here instead of another hand-authored after_secs(30) chain, and a future workspace-wide heartbeat re-tuning (a config-slot override, a per-controller adaptive cadence) lands at THIS primitive rather than as a scatter- gather sweep across every reconciler.