SuperSocket
SuperSocket copied to clipboard
2.0websocket一个必现BUG
2.0-beta18版本 使用websocket建立连接 ,然后客户端连接完成后通过切换网络再关闭客户端,服务端接收不到客户端断开连接的消息
当前使用解决方法通过检测心跳由服务端关闭无效的客户端连接
It's not a bug, when your network changes, there is noway to detect the client disconnected. That's why you need implement the heartbeat. The heartbeat is designed to handle this kind of issue https://stackoverflow.com/questions/46111656/must-websockets-have-heartbeats
Enable clearIdleSession in server side.