io.netty.handler.codec.DecoderException: java.lang.IndexOutOfBoundsException: readerIndex(1) + length(1) exceeds writerIndex(1): SlicedAbstractByteBuf(ridx: 1, widx: 1, cap: 1/1, unwrapped: PooledUnsafeDirectByteBuf(ridx: 2, widx: 2, cap: 2))

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Solutions on the web

via GitHub by mibby
, 1 year ago
java.lang.IndexOutOfBoundsException: readerIndex(1) + length(1) exceeds writerIndex(1): SlicedAbstractByteBuf(ridx: 1, widx: 1, cap: 1/1, unwrapped: PooledUnsafeDirectByteBuf(ridx: 2, widx: 2, cap: 2))
via GitHub by rkapsi
, 1 year ago
java.lang.IndexOutOfBoundsException: readerIndex(63) + length(1) exceeds writerIndex(63): PooledUnsafeDirectByteBuf(ridx: 63, widx: 63, cap: 4096)
via GitHub by dmk23
, 2 years ago
java.lang.IndexOutOfBoundsException: readerIndex(512) + length(4) exceeds writerIndex(512): PooledUnsafeDirectByteBuf(ridx: 512, widx: 512, cap: 4096)
via GitHub by jonas-ren
, 1 year ago
java.lang.IndexOutOfBoundsException: readerIndex(480) + length(65) exceeds writerIndex(541): PooledUnsafeDirectByteBuf(ridx: 480, widx: 541, cap: 4096)
via Stack Overflow by Bhesh Gurung
, 1 year ago
com.google.protobuf.InvalidProtocolBufferException: While parsing a protocol message, the input ended unexpectedly in the middle of a field. This could mean either than the input has been truncated or that an embedded message misreported its own length.
via Stack Overflow by Sanjana Senthil
, 1 year ago
org.apache.tinkerpop.gremlin.driver.ser.SerializationException: java.lang.IndexOutOfBoundsException: Index: 121, Size: 0
java.lang.IndexOutOfBoundsException: readerIndex(1) + length(1) exceeds writerIndex(1): SlicedAbstractByteBuf(ridx: 1, widx: 1, cap: 1/1, unwrapped: PooledUnsafeDirectByteBuf(ridx: 2, widx: 2, cap: 2))
at io.netty.buffer.AbstractByteBuf.checkReadableBytes0(AbstractByteBuf.java:1345)
at io.netty.buffer.AbstractByteBuf.readByte(AbstractByteBuf.java:648)
at net.md_5.bungee.protocol.DefinedPacket.readVarInt(DefinedPacket.java:100)
at net.md_5.bungee.protocol.DefinedPacket.readVarInt(DefinedPacket.java:90)
at net.md_5.bungee.protocol.packet.Handshake.read(Handshake.java:26)
at net.md_5.bungee.protocol.DefinedPacket.read(DefinedPacket.java:185)
at net.md_5.bungee.protocol.MinecraftDecoder.decode(MinecraftDecoder.java:41)
at net.md_5.bungee.protocol.MinecraftDecoder.decode(MinecraftDecoder.java:10)
at io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:89)
at io.netty.channel.ChannelHandlerInvokerUtil.invokeChannelReadNow(ChannelHandlerInvokerUtil.java:83)
at io.netty.channel.DefaultChannelHandlerInvoker.invokeChannelRead(DefaultChannelHandlerInvoker.java:154)
at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:354)
at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:145)
at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:277)
at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:264)
at io.netty.channel.ChannelHandlerInvokerUtil.invokeChannelReadNow(ChannelHandlerInvokerUtil.java:83)
at io.netty.channel.DefaultChannelHandlerInvoker.invokeChannelRead(DefaultChannelHandlerInvoker.java:154)
at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:354)
at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:145)
at io.netty.handler.codec.ByteToMessageDecoder.handlerRemoved(ByteToMessageDecoder.java:217)
at io.netty.channel.DefaultChannelPipeline.callHandlerRemoved0(DefaultChannelPipeline.java:756)
at io.netty.channel.DefaultChannelPipeline.remove(DefaultChannelPipeline.java:577)
at io.netty.channel.DefaultChannelPipeline.remove(DefaultChannelPipeline.java:540)
at net.md_5.bungee.protocol.LegacyDecoder.decode(LegacyDecoder.java:37)
at io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:387)
at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:245)
at io.netty.channel.ChannelHandlerInvokerUtil.invokeChannelReadNow(ChannelHandlerInvokerUtil.java:83)
at io.netty.channel.DefaultChannelHandlerInvoker.invokeChannelRead(DefaultChannelHandlerInvoker.java:154)
at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:354)
at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:145)
at io.netty.handler.timeout.ReadTimeoutHandler.channelRead(ReadTimeoutHandler.java:152)
at io.netty.channel.ChannelHandlerInvokerUtil.invokeChannelReadNow(ChannelHandlerInvokerUtil.java:83)
at io.netty.channel.DefaultChannelHandlerInvoker.invokeChannelRead(DefaultChannelHandlerInvoker.java:154)
at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:354)
at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:145)
at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:1078)
at io.netty.channel.epoll.AbstractEpollStreamChannel$EpollStreamUnsafe.epollInReady(AbstractEpollStreamChannel.java:872)
at io.netty.channel.epoll.EpollEventLoop.processReady(EpollEventLoop.java:359)
at io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:275)
at io.netty.util.concurrent.SingleThreadEventExecutor$5.run(SingleThreadEventExecutor.java:742)
at java.lang.Thread.run(Thread.java:745)

Users with the same issue

6 times, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago

Write tip

Know the solutions? Share your knowledge to help other developers to debug faster.