Skip to content

operator: heartbeat loop has no timeout, so a hung chain RPC silently stops all heartbeats #488

Description

@euxaristia

Summary

operator::send_heartbeat (crates/gitlawb-node/src/operator.rs:118-145) connects and sends with no timeout at any stage, and the heartbeat loop's select! arm awaits it to completion (:160-180), so one hung chain-RPC call (silent TCP black hole, or a provider that accepts the tx but stalls receipt polling) stops the interval silently: no tick, no error log, no heartbeat again. Related: heartbeat_interval_hours (config.rs:172) is documented as "must be < 24h" but has no clap range or validate() check.

Impact

The node silently drops out of "currently active" on-chain after the 24h window - a liveness/penalty failure with no local signal. A misconfigured interval above 24h makes staying active impossible by construction.

Remediation

  1. Wrap the heartbeat send in a timeout and log + continue on expiry.
  2. Validate heartbeat_interval_hours in validate()/clap range.

Proposed labels: kind:bug, crate:node, subsystem:attestation.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    crate:nodegitlawb-node — the serving node and REST APIkind:bugDefect fix — wrong or unsafe behaviorsev:mediumDegraded but workaround existssubsystem:attestationCertificates, anchoring, per-ref attestation

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions