Closed KostyaEsmukov closed 8 years ago
Hi Kostya,
this part of recovery process is required to trigger the connection lost event with WIFI connection. We noticed this strange behaviour ONLY in the boards connected in WIFI and that have an Internet connection provided via ADSL/Fiber. In particular (without tcpkill tool) the WAMP socket channel keeps "ALIVE" and only after 10 minutes (more or less) WAMP notices that the connection is compromised. So we need tcpkill tool to directly cut off the socket...in this way WAMP correctly/instantly triggers the connection lost through heartbeat+timeout mechanisms.
Of course if you have other suggestions let us know!
Nicola.
Hi Nicola,
Thank you for your response. I guess I have an idea how to gracefully handle such situations. Please let me know whether you are able to reproduce such setup in order to test my idea in real conditions. Thank you.
Kostya.
Let me clarify that unfortunately this is not so easy to reproduce, as it is obviously dependent on (broken) NAT implementations on the side of CPEs (Customer Premises Equiment) such as routers our DSL/Fiber providers rent us as residential customers. The only way to know for sure how reproducible it is (on your side) is by trying it out on any router you have and see if it behaves correctly or not.
Hello,
Please explain the purpose of tcpkill in WAMP connection recovery part. Are you sure that it is required? Because in case of broken network link it will be closed anyway. Heartbeats+timeout approach is much more robust than tcpkill one. I'm almost sure that it can be safely pulled out. Please let me know what do you think of this.
https://github.com/MDSLab/s4t-lightning-rod/blob/00e3e5b9356156f2fa86b3e4443047aa730ceb1f/lightning-rod.js#L230-L313