问题1:
io.jpower.kcp.netty.KcpException: State=-1 after update()
at io.jpower.kcp.netty.UkcpClientChannel.run(UkcpClientChannel.java:298)
at io.netty.util.concurrent.PromiseTask$RunnableAdapter.call(PromiseTask.java:38)
at io.netty.util.concurrent.ScheduledFutureTask.run(ScheduledFutureTask.java:125)
at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:163)
at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:404)
at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:463)
at io.netty.util.concurrent.SingleThreadEventExecutor$5.run(SingleThreadEventExecutor.java:886)
at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
at java.lang.Thread.run(Thread.java:745)
问题1: io.jpower.kcp.netty.KcpException: State=-1 after update() at io.jpower.kcp.netty.UkcpClientChannel.run(UkcpClientChannel.java:298) at io.netty.util.concurrent.PromiseTask$RunnableAdapter.call(PromiseTask.java:38) at io.netty.util.concurrent.ScheduledFutureTask.run(ScheduledFutureTask.java:125) at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:163) at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:404) at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:463) at io.netty.util.concurrent.SingleThreadEventExecutor$5.run(SingleThreadEventExecutor.java:886) at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) at java.lang.Thread.run(Thread.java:745)
在使用demo测试过程中,发现跑一段时间后就会报这个问题,网络环境是本地电脑模拟服务器和客户端,网络应该不成问题,但是还是会出现deadLink超过20次的问题,请教下kcp的C代码中没有断开连接的做法,不知道您这边基于什么考虑要将客户端断开连接?
问题2: 我们系统集成中,发现会存在netty的内存泄露问题,提示的报错信息集中在: io.netty.buffer.AdvancedLeakAwareByteBuf.readRetainedSlice(AdvancedLeakAwareByteBuf.java:106) kcp.netty.Kcp.input(Kcp.java:999) kcp.netty.Ukcp.input(Ukcp.java:51) kcp.netty.UkcpServerChildChannel.kcpInput(UkcpServerChildChannel.java:192) kcp.netty.UkcpServerChannel$UkcpServerUnsafe.read(UkcpServerChannel.java:566) 以上两个问题,请帮忙看看,是否我在使用中有什么注意点,不胜感谢!