-
Notifications
You must be signed in to change notification settings - Fork 179
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Access] Implement keepalive routine with ping-ponging to ws connection in ws controller #6757
base: master
Are you sure you want to change the base?
[Access] Implement keepalive routine with ping-ponging to ws connection in ws controller #6757
Conversation
…ub.com:The-K-R-O-K/flow-go into UlyanaAndrukhiv/6639-ws-ping-pong
…drukhiv/6639-ws-ping-pong
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #6757 +/- ##
==========================================
+ Coverage 39.71% 41.92% +2.20%
==========================================
Files 1332 1655 +323
Lines 123050 153507 +30457
==========================================
+ Hits 48875 64359 +15484
- Misses 69986 83860 +13874
- Partials 4189 5288 +1099
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
…ub.com:The-K-R-O-K/flow-go into UlyanaAndrukhiv/6638-ws-connection-configuring
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After the first round of review - looks cool!
} | ||
|
||
c.dataProviders.Clear() | ||
if err := c.conn.WriteMessage(websocket.PingMessage, nil); err != nil { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess what you need is WriteControl()
method which accepts deadline as well
Closes: #6639
Note: ##6750 should be merged first
Context
In this pull request implemented a
keepalive
routine to monitorWebSocket
network connectivity using ping-pong messages.Key Changes
keepalive
logic with forWebSocket
controller to detect and handle connectivity issues and ensured thekeepalive
operates independently, managing ping-pong messages and monitoring connection health.WebSocket
connection and gracefully shut down affected components when issues are detected.