默认
发表评论 6
想开发IM:买成品怕坑?租第3方怕贵?找开源自已撸?尽量别走弯路了... 找站长给点建议
[已回复] 求助MobileIMSDK的客户端频繁上下线的问题
日志信息如下:
2023-09-13 17:40:10.998 [main] INFO  com.zzstxx.Application:61 - Started Application in 6.184 seconds (JVM running for 6.699)
2023-09-13 17:40:11.098 [main] INFO  net.x52im.mobileimsdk.server.ServerLauncher:233 - [IMCORE-tcp] 配置项:未开启与MobileIMSDK Web的互通.
2023-09-13 17:40:11.167 [main] INFO  net.x52im.mobileimsdk.server.network.GatewayUDP:142 - [IMCORE-udp] 基于MobileIMSDK的UDP服务绑定端口成功 √
2023-09-13 17:40:11.168 [main] INFO  net.x52im.mobileimsdk.server.network.GatewayUDP:164 - [IMCORE-udp] .... continue ...
2023-09-13 17:40:11.169 [main] INFO  net.x52im.mobileimsdk.server.network.GatewayUDP:165 - [IMCORE-udp] 基于MobileIMSDK的UDP服务正在端口7901上监听中...
2023-09-13 17:40:11.171 [main] INFO  net.x52im.mobileimsdk.server.network.GatewayTCP:179 - [IMCORE-tcp] 基于MobileIMSDK的TCP服务绑定端口成功 √
2023-09-13 17:40:11.172 [main] INFO  net.x52im.mobileimsdk.server.network.GatewayTCP:202 - [IMCORE-tcp] .... continue ...
2023-09-13 17:40:11.172 [main] INFO  net.x52im.mobileimsdk.server.network.GatewayTCP:203 - [IMCORE-tcp] 基于MobileIMSDK的TCP服务正在端口8901上监听中...
2023-09-13 17:40:11.619 [nioEventLoopGroup-5-1] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:389 - [IMCORE-tcp]与{uid:null}/219.157.255.116:44438的会话建立(channelActive)了...
2023-09-13 17:40:11.660 [nioEventLoopGroup-5-1] INFO  n.x.mobileimsdk.server.processor.LogicProcessor:239 - [IMCORE-tcp]>> 客户端{uid:null}/219.157.255.116:44438发过来的登陆信息内容是:loginInfo=70AAB1098A|getToken=
2023-09-13 17:40:11.660 [nioEventLoopGroup-5-1] DEBUG com.zzstxx.im.server.ServerEventListenerImpl:83 - 【DEBUG_回调通知】正在调用回调方法:OnVerifyUserCallBack...(extra=null)
2023-09-13 17:40:11.822 [nioEventLoopGroup-5-1] DEBUG com.zzstxx.im.server.ServerEventListenerImpl:104 - 【IM_回调通知OnUserLoginAction_CallBack】用户:70AAB1098A 上线了!
2023-09-13 17:40:11.822 [nioEventLoopGroup-5-1] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:198 - [IMCORE-tcp]<< 收到客户端{uid:70AAB1098A}/219.157.255.116:44438的ACK应答包发送请求.
2023-09-13 17:40:11.833 [nioEventLoopGroup-5-1] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:315 - [IMCORE-tcp]{uid:70AAB1098A}/219.157.255.116:44438的会话已关闭(user_id=70AAB1098A)了...
2023-09-13 17:40:11.833 [nioEventLoopGroup-5-1] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:321 - .......... 【0】[当前正在被关闭的session] session.hashCode=-1717868250, session.ip+port=/219.157.255.116:44438
2023-09-13 17:40:11.833 [nioEventLoopGroup-5-1] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:326 - .......... 【1】[处于在线列表中的session] session.hashCode=-1717868250, session.ip+port=
2023-09-13 17:40:11.849 [nioEventLoopGroup-5-1] DEBUG com.zzstxx.im.server.ServerEventListenerImpl:122 - 【DEBUG_回调通知OnUserLogoutAction_CallBack】用户:70AAB1098A 离线了!
2023-09-13 17:40:11.935 [nioEventLoopGroup-5-2] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:389 - [IMCORE-tcp]与{uid:null}/219.157.255.116:44440的会话建立(channelActive)了...
2023-09-13 17:40:11.942 [nioEventLoopGroup-5-2] INFO  n.x.mobileimsdk.server.processor.LogicProcessor:239 - [IMCORE-tcp]>> 客户端{uid:null}/219.157.255.116:44440发过来的登陆信息内容是:loginInfo=70AAB1098A|getToken=
2023-09-13 17:40:11.960 [nioEventLoopGroup-5-2] DEBUG com.zzstxx.im.server.ServerEventListenerImpl:104 - 【IM_回调通知OnUserLoginAction_CallBack】用户:70AAB1098A 上线了!
2023-09-13 17:40:11.984 [nioEventLoopGroup-5-2] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:198 - [IMCORE-tcp]<< 收到客户端{uid:70AAB1098A}/219.157.255.116:44440的ACK应答包发送请求.
2023-09-13 17:40:11.988 [nioEventLoopGroup-5-2] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:315 - [IMCORE-tcp]{uid:70AAB1098A}/219.157.255.116:44440的会话已关闭(user_id=70AAB1098A)了...
2023-09-13 17:40:11.988 [nioEventLoopGroup-5-2] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:321 - .......... 【0】[当前正在被关闭的session] session.hashCode=-1057460089, session.ip+port=/219.157.255.116:44440
2023-09-13 17:40:11.988 [nioEventLoopGroup-5-2] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:326 - .......... 【1】[处于在线列表中的session] session.hashCode=-1057460089, session.ip+port=
2023-09-13 17:40:12.005 [nioEventLoopGroup-5-2] DEBUG com.zzstxx.im.server.ServerEventListenerImpl:122 - 【DEBUG_回调通知OnUserLogoutAction_CallBack】用户:70AAB1098A 离线了!
2023-09-13 17:40:12.086 [nioEventLoopGroup-5-3] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:389 - [IMCORE-tcp]与{uid:null}/219.157.255.116:44442的会话建立(channelActive)了...
2023-09-13 17:40:12.091 [nioEventLoopGroup-5-3] INFO  n.x.mobileimsdk.server.processor.LogicProcessor:239 - [IMCORE-tcp]>> 客户端{uid:null}/219.157.255.116:44442发过来的登陆信息内容是:loginInfo=70AAB1098A|getToken=
2023-09-13 17:40:12.091 [nioEventLoopGroup-5-3] DEBUG com.zzstxx.im.server.ServerEventListenerImpl:83 - 【DEBUG_回调通知】正在调用回调方法:OnVerifyUserCallBack...(extra=null)
2023-09-13 17:40:12.108 [nioEventLoopGroup-5-3] DEBUG com.zzstxx.im.server.ServerEventListenerImpl:104 - 【IM_回调通知OnUserLoginAction_CallBack】用户:70AAB1098A 上线了!
2023-09-13 17:40:12.130 [nioEventLoopGroup-5-3] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:198 - [IMCORE-tcp]<< 收到客户端{uid:70AAB1098A}/219.157.255.116:44442的ACK应答包发送请求.
2023-09-13 17:40:12.133 [nioEventLoopGroup-5-3] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:315 - [IMCORE-tcp]{uid:70AAB1098A}/219.157.255.116:44442的会话已关闭(user_id=70AAB1098A)了...
2023-09-13 17:40:12.133 [nioEventLoopGroup-5-3] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:321 - .......... 【0】[当前正在被关闭的session] session.hashCode=1518395866, session.ip+port=/219.157.255.116:44442
2023-09-13 17:40:12.134 [nioEventLoopGroup-5-3] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:326 - .......... 【1】[处于在线列表中的session] session.hashCode=1518395866, session.ip+port=
2023-09-13 17:40:12.150 [nioEventLoopGroup-5-3] DEBUG com.zzstxx.im.server.ServerEventListenerImpl:122 - 【DEBUG_回调通知OnUserLogoutAction_CallBack】用户:70AAB1098A 离线了!
2023-09-13 17:40:12.211 [nioEventLoopGroup-5-4] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:389 - [IMCORE-tcp]与{uid:null}/219.157.255.116:44444的会话建立(channelActive)了...
2023-09-13 17:40:12.217 [nioEventLoopGroup-5-4] INFO  n.x.mobileimsdk.server.processor.LogicProcessor:239 - [IMCORE-tcp]>> 客户端{uid:null}/219.157.255.116:44444发过来的登陆信息内容是:loginInfo=70AAB1098A|getToken=
2023-09-13 17:40:12.218 [nioEventLoopGroup-5-4] DEBUG com.zzstxx.im.server.ServerEventListenerImpl:83 - 【DEBUG_回调通知】正在调用回调方法:OnVerifyUserCallBack...(extra=null)
2023-09-13 17:40:12.236 [nioEventLoopGroup-5-4] DEBUG com.zzstxx.im.server.ServerEventListenerImpl:104 - 【IM_回调通知OnUserLoginAction_CallBack】用户:70AAB1098A 上线了!
2023-09-13 17:40:12.262 [nioEventLoopGroup-5-4] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:198 - [IMCORE-tcp]<< 收到客户端{uid:70AAB1098A}/219.157.255.116:44444的ACK应答包发送请求.
2023-09-13 17:40:12.266 [nioEventLoopGroup-5-4] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:315 - [IMCORE-tcp]{uid:70AAB1098A}/219.157.255.116:44444的会话已关闭(user_id=70AAB1098A)了...
2023-09-13 17:40:12.266 [nioEventLoopGroup-5-4] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:321 - .......... 【0】[当前正在被关闭的session] session.hashCode=-603087362, session.ip+port=/219.157.255.116:44444
2023-09-13 17:40:12.266 [nioEventLoopGroup-5-4] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:326 - .......... 【1】[处于在线列表中的session] session.hashCode=-603087362, session.ip+port=
2023-09-13 17:40:12.284 [nioEventLoopGroup-5-4] DEBUG com.zzstxx.im.server.ServerEventListenerImpl:122 - 【DEBUG_回调通知OnUserLogoutAction_CallBack】用户:70AAB1098A 离线了!
2023-09-13 17:40:12.379 [nioEventLoopGroup-5-5] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:389 - [IMCORE-tcp]与{uid:null}/219.157.255.116:44446的会话建立(channelActive)了...
2023-09-13 17:40:12.384 [nioEventLoopGroup-5-5] INFO  n.x.mobileimsdk.server.processor.LogicProcessor:239 - [IMCORE-tcp]>> 客户端{uid:null}/219.157.255.116:44446发过来的登陆信息内容是:loginInfo=70AAB1098A|getToken=
2023-09-13 17:40:12.384 [nioEventLoopGroup-5-5] DEBUG com.zzstxx.im.server.ServerEventListenerImpl:83 - 【DEBUG_回调通知】正在调用回调方法:OnVerifyUserCallBack...(extra=null)
2023-09-13 17:40:12.401 [nioEventLoopGroup-5-5] DEBUG com.zzstxx.im.server.ServerEventListenerImpl:104 - 【IM_回调通知OnUserLoginAction_CallBack】用户:70AAB1098A 上线了!
2023-09-13 17:40:12.417 [nioEventLoopGroup-5-5] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:198 - [IMCORE-tcp]<< 收到客户端{uid:70AAB1098A}/219.157.255.116:44446的ACK应答包发送请求.
2023-09-13 17:40:12.419 [nioEventLoopGroup-5-5] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:315 - [IMCORE-tcp]{uid:70AAB1098A}/219.157.255.116:44446的会话已关闭(user_id=70AAB1098A)了...
2023-09-13 17:40:12.419 [nioEventLoopGroup-5-5] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:321 - .......... 【0】[当前正在被关闭的session] session.hashCode=1597182430, session.ip+port=/219.157.255.116:44446
2023-09-13 17:40:12.419 [nioEventLoopGroup-5-5] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:326 - .......... 【1】[处于在线列表中的session] session.hashCode=1597182430, session.ip+port=
2023-09-13 17:40:12.435 [nioEventLoopGroup-5-5] DEBUG com.zzstxx.im.server.ServerEventListenerImpl:122 - 【DEBUG_回调通知OnUserLogoutAction_CallBack】用户:70AAB1098A 离线了!
2023-09-13 17:40:12.530 [nioEventLoopGroup-5-6] INFO  net.x52im.mobileimsdk.server.ServerCoreHandler:389 - [IMCORE-tcp]与{uid:null}/219.157.255.116:44448的会话建立(channelActive)了...
2023-09-13 17:40:12.534 [nioEventLoopGroup-5-6] INFO  n.x.mobileimsdk.server.processor.LogicProcessor:239 - [IMCORE-tcp]>> 客户端{uid:null}/219.157.255.116:44448发过来的登陆信息内容是:loginInfo=70AAB1098A|getToken=
2023-09-13 17:40:12.534 [nioEventLoopGroup-5-6] DEBUG com.zzstxx.im.server.ServerEventListenerImpl:83 - 【DEBUG_回调通知】正在调用回调方法:OnVerifyUserCallBack...(extra=null)

即时通讯网 - 即时通讯开发者社区! 来源: - 即时通讯开发者社区!

上一篇:[已回复] 求教MobileIMSDK服务端中的ReadTimeoutHandler使用疑问下一篇:[已回复] MobileIMSDK-H5端登录时,服务端“没有存放user_id,可能是没成功合法认证”

本帖已收录至以下技术专辑

推荐方案
评论 6
看你日志,客户端100毫秒就掉一次。
而且接着马上又重连,连延迟都不带的。。。原版的代码,哪怕你掉线,也是几秒后才会再次发起重连,为何这连气都不喘一口马上就再次发起重连

你是有改动过什么代码吗?客户端是什么端?有日志吗,可以像服务的log一样抓出来看看
引用:JackJiang 发表于 2023-09-14 10:44
看你日志,客户端100毫秒就掉一次。
而且接着马上又重连,连延迟都不带的。。。原版的代码,哪怕你掉线, ...

没做改动,该服务在另一台服务器上正常,这台新服务器就有问题了。

9DC24318-298E-4280-A9A1-2FA40A8C3D71.png (128.35 KB, 下载次数: 251)

9DC24318-298E-4280-A9A1-2FA40A8C3D71.png
客户端是Android,链接另外一台服务正常,连这台就异常,不知道是不是服务器网络限制还是?
引用:hlf520 发表于 2023-09-14 11:24
客户端是Android,链接另外一台服务正常,连这台就异常,不知道是不是服务器网络限制还是?

限制的话,也不会这么死命连,客户端会定时重连,至少有几秒间隔

这台服务器的JDK版本具体是多少?操作系统的具体版本是多少?
引用:JackJiang 发表于 2023-09-14 15:41
限制的话,也不会这么死命连,客户端会定时重连,至少有几秒间隔

这台服务器的JDK版本具体是多少?操 ...

jdk:jdk1.8.0_231
操作系统:Linux version 3.10.0-1160.76.1.el7.x86_64 (mockbuild@kbuilder.bsys.centos.org) (gcc version 4.8.5 20150623 (Red Hat 4.8.5-44) (GCC) ) #1 SMP
引用:hlf520 发表于 2023-09-15 09:05
jdk:jdk1.8.0_231
操作系统:Linux version 3.10.0-1160.76.1.el7.x86_64 () (gcc version 4.8.5 201506 ...

JDK用的是openjdk还早Oracle官方的版本?

另外,你的服务器ip地址是多少,我用demo客户端帮你连连看看
打赏楼主 ×
使用微信打赏! 使用支付宝打赏!

返回顶部