Skip to content

Add WebSocket Heartbeat/Ping-Pong to Detect Silent Connection Death #252

Description

@maugauwi-hash

Area: WebSocket / Real-Time
Priority: Medium
Estimated Time: 1.5 hours

Description:
shared/api-contract.md says clients "are expected to reconnect with backoff on an unexpected
drop," which requires detecting the drop in the first place. A silently dead TCP connection (e.g.,
NAT timeout without a clean close frame) can go undetected for a long time without an
application-level ping.

Tasks:

  • Add a periodic ping frame (or app-level heartbeat message) from both VaultEventSocket implementations
  • Trigger the existing reconnect-with-backoff path if no pong/heartbeat response arrives in time
  • Add tests simulating a silent connection death (no close frame, no further messages)

Activity

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

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions