You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[BUG] Dead connections with active subscriptions are never cleaned up #427
Describe the bug
Dead WebSocket connections with active subscriptions are never terminated. If a client subscribes to events and then drops unexpectedly, the server keeps it around forever, pinging it every 2 minutes, matching events against its subscriptions, leaking memory.
To Reproduce
Connect a WebSocket client to the relay.
Send a REQ message to create a subscription.
Kill the client abruptly (don't send CLOSE, just cut the connection).
Watch the server. It keeps pinging the dead client but never closes it.
Expected behavior
Dead clients should be terminated by the heartbeat regardless of whether they had active subscriptions.
Screenshots
N/A
System (please complete the following information):
Activity
tharu-jwd commentedon Apr 9, 2026
Hey @cameri, found this while going through the codebase.
Happy to submit a PR with the fix if you'd like!
cameri commentedon Apr 10, 2026
@tharu-jwd sure!