What Changed#
Increases the patched Effect RPC pinger delay from 5 seconds to 60 seconds.
This changes the existing patches/effect@4.0.0-beta.73.patch so the generated RPC client waits longer before declaring the connection unhealthy due to a missed Pong.
Why#
Large thread snapshots can occupy the WebSocket long enough that the Effect RPC Pong is queued behind snapshot chunks. On slow remote connections, the current 5 second heartbeat window can expire before the Pong reaches the client, causing a reconnect. The reconnect then requests the same large snapshot again, which can repeat the failure loop.
A 60 second window gives large snapshot sends more time to drain before the client treats the connection as dead.
This is a small mitigation for #2761. It does not solve the deeper issue that large snapshots and control/heartbeat messages share the same WebSocket queue; longer term, snapshots likely need pagination, truncation, backpressure, or control-message prioritization.
Checklist#
Note
Increase Effect RPC ping interval to 60 seconds for large snapshot support#
- Updates patches/effect@4.0.0-beta.78.patch to change the protocol worker ping interval from 5 seconds to 60 seconds.
- Adds an
hooks.onPing call (when provided) before each ping is sent, allowing pre-ping side effects.
- Behavioral Change: ping frequency drops from every 5s to every 60s, which may affect connection keepalive behavior in environments with short idle timeouts.
Macroscope summarized 2825718.
Note
Medium Risk
Changes connection health detection for all Effect RPC WebSocket clients; a 60s window delays detection of truly dead peers but reduces false reconnect loops during heavy snapshot traffic.
Overview
Updates the vendored effect@4.0.0-beta.78 patch so the RPC socket pinger waits 60 seconds between ping attempts instead of 5 seconds, giving large WebSocket transfers (e.g. thread snapshots) more time before the client treats a missing Pong as a dead connection.
The same patch delta wires ConnectionHooks into the ping loop: onPong runs after recording a pong, onPing runs before writePing, and both default to Effect.void when unset. pnpm-lock.yaml is refreshed so every workspace consumer resolves the new effect patch hash.
Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit 2825718f3bfd49bf709b76103cba9247dc16d904. Bugbot is set up for automated code reviews on this repo. Configure [here](https://www.cursor.com/dashboard/bugbot).
Important
Review skipped#
Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the
.coderabbit.yamlfile in this repository. To trigger a single review, invoke the@coderabbitai reviewcommand.⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID:
869b0f55-01e6-4fd4-8ceb-cad2894b8ac5You can disable this status message by setting the
reviews.review_statustofalsein the CodeRabbit configuration file.Use the checkbox below for a quick retry:
✨ Finishing Touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
❤️ Share