fix: idle WebSocket connections are dropped after 30 seconds - #115
Conversation
…ed after 30s Signed-off-by: Oleksander Piskun <oleksandr2088@icloud.com>
|
Warning Review limit reached
Next review available in: 51 minutes You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthroughAdded 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
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. Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro Plus
Run ID: f4d7d8f9-cdbd-4ac6-8325-3a716ba5e646
📒 Files selected for processing (3)
README.mdhaproxy.cfg.templatestart.sh
… reaping Signed-off-by: Oleksander Piskun <oleksandr2088@icloud.com>
While investigating #114 I found that idle WebSocket connections through HaRP are closed after exactly 30 seconds: the config defines no
timeout tunnel, so after the 101 upgrade HAProxy falls back totimeout clientfor the tunnel, and any ExApp WebSocket that does not ping more often than that gets cut (termination flagscD--in the access log).This adds
timeout tunnel, configurable through a newHP_TIMEOUT_TUNNELvariable that defaults to the value ofHP_TIMEOUT_SERVER(1800s), so raising the server timeout keeps tunnels covered too. Setting it to0means unlimited: HAProxy has no infinite value for this timeout (a literaltimeout tunnel 0silently falls back to the client timeout again, verified live), so start.sh maps0to HAProxy's24dmaximum. Also addstimeout client-fin 30sso half-closed tunnels are reaped quickly instead of lingering for the whole tunnel timeout.Tested live against a probe ExApp connected through a real FRP tunnel: on the current release an idle WebSocket dies at 30.0s; with this change it survives 120s of idle with the default, an explicit
HP_TIMEOUT_TUNNEL=15scuts it at 15s, and0keeps it alive. SSE streams (idle, headers-only, with pings), slow responses and the 30s request-phase client timeout all behave exactly as before.