SocketRocket
SocketRocket copied to clipboard
Stream end encountered !!!
The program runs for a period of time and the connection is automatically disconnected. I was very surprised that my server did not break the initiative, and the client's code did not break, and the heartbeat package was 60 seconds.
Have you solved this problem?How to solve it? ths.
I meet the same problem
!!!!
anybody have this fixed
https://github.com/facebook/SocketRocket/issues/92#issuecomment-517957913
I also have the same problem!!!!!!
I have resolve it ,but the way is not perfect. I found that when the disconnection take place , the delegate function would be called,and the param code is SRStatusCodeGoingAway。
- (void)webSocket:(SRWebSocket *)webSocket didCloseWithCode:(NSInteger)code reason:(NSString *)reason wasClean:(BOOL)wasClean { MJRefreshLog(@"关闭websocket"); if (code==SRStatusCodeGoingAway) { [self reConnect];// your reconect code }else{ [self destoryHeartBeat];//close HeartBeat } }
Same here 😞 , but I don't know how to reproduce this issue, anyone knows?
maybe it is wrong here
I also have the same problem. I thought it was caused by conflicts with other third-party SDKs until I learned that our websocket server needs to append some parameters after the link.