SocketRocket icon indicating copy to clipboard operation
SocketRocket copied to clipboard

Stream end encountered !!!

Open LoveLifeLoveSelf opened this issue 7 years ago • 10 comments

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.

LoveLifeLoveSelf avatar Apr 16 '18 08:04 LoveLifeLoveSelf

Have you solved this problem?How to solve it? ths.

cbeiyou avatar Jul 24 '18 08:07 cbeiyou

I meet the same problem

yellowTiger avatar Sep 21 '18 01:09 yellowTiger

!!!!

tshradheya avatar Jan 14 '19 16:01 tshradheya

anybody have this fixed

coreypett avatar Jun 03 '19 21:06 coreypett

https://github.com/facebook/SocketRocket/issues/92#issuecomment-517957913

maxhawkins avatar Aug 03 '19 22:08 maxhawkins

I also have the same problem!!!!!!

bharatbhamare avatar Sep 18 '19 05:09 bharatbhamare

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 } }

yellowTiger avatar Sep 20 '19 02:09 yellowTiger

Same here 😞 , but I don't know how to reproduce this issue, anyone knows?

ElfSundae avatar Sep 24 '19 04:09 ElfSundae

截屏2021-09-14 下午5 34 42 maybe it is wrong here

JumpJumpSparrow avatar Sep 14 '21 09:09 JumpJumpSparrow

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.

ApesTalk avatar Nov 03 '21 06:11 ApesTalk