Open powerLxc opened 5 years ago
你用的是数据文件进行的测试吗?
对了,你应该把PublisherManager类的那一大堆注释解开,看看ffmpeg的输出,另外,就是视频不能播放的时候,你看看ffmpeg进程还在不在,以前通过jstack -l PID看看线程的情况。。。。
数据文件和实时数据都有
呃,揪心,我上面说的那个你试过了没有?有没有看到ffmpeg的输出?有没有看过jstack的输出?
我在看,很奇怪的事,我吧PublisherManager类的那一大堆注释解开后就可以播放很长时间了,我在多试几次
我去,还有这种事。。。。我觉得你不用在这个事情上花太长时间了,再稍稍试试就成了,我觉得更应该考虑的事情是断了重连的一套策略,而不是想去尽可能长的维持这个时间,因为实际行驶过程中,随时有断网的可能性。。。。
断了重连我的想法是netty有监控连接断开的类,检测到断开的时候判断一下人为还是被动的动作然后在重新发送指令
嗯,想办法做好重发指令的事情,再多试试看看,祝你好运了。。。
好的,谢谢,能加个微信什么的吗
加QQ吧,65827536
io.netty.handler.codec.DecoderException: java.lang.RuntimeException: exceed the max buffer size, max length: 4096, data length: 512 at io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:459) at io.netty.handler.codec.ByteToMessageDecoder.channelInputClosed(ByteToMessageDecoder.java:392) at io.netty.handler.codec.ByteToMessageDecoder.channelInputClosed(ByteToMessageDecoder.java:359) at io.netty.handler.codec.ByteToMessageDecoder.channelInactive(ByteToMessageDecoder.java:342) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelInactive(AbstractChannelHandlerContext.java:245) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelInactive(AbstractChannelHandlerContext.java:231) at io.netty.channel.AbstractChannelHandlerContext.fireChannelInactive(AbstractChannelHandlerContext.java:224) at io.netty.channel.DefaultChannelPipeline$HeadContext.channelInactive(DefaultChannelPipeline.java:1409) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelInactive(AbstractChannelHandlerContext.java:245) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelInactive(AbstractChannelHandlerContext.java:231) at io.netty.channel.DefaultChannelPipeline.fireChannelInactive(DefaultChannelPipeline.java:927) at io.netty.channel.AbstractChannel$AbstractUnsafe$8.run(AbstractChannel.java:822) 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:748) Caused by: java.lang.RuntimeException: exceed the max buffer size, max length: 4096, data length: 512 at cn.org.hentai.jtt1078.util.ByteHolder.write(ByteHolder.java:32) at cn.org.hentai.jtt1078.util.ByteHolder.write(ByteHolder.java:26) at cn.org.hentai.jtt1078.server.Jtt1078Decoder.write(Jtt1078Decoder.java:16) at cn.org.hentai.jtt1078.server.Jtt1078Decoder.write(Jtt1078Decoder.java:23) at cn.org.hentai.jtt1078.server.Jtt1078MessageDecoder.decode(Jtt1078MessageDecoder.java:31) at io.netty.handler.codec.ByteToMessageDecoder.decodeRemovalReentryProtection(ByteToMessageDecoder.java:489) at io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:428) ... 17 more