java.io.IOException: Connection reset by peer

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

Samebug tips

,

Normally, the connection to an HTTP server is closed after each response. Change the network connection and make sure the network is stable when making the request. When the server closes such a connection the client usually reopens it again.

Solutions on the web

via GitHub by awilliamson
, 2 years ago
via GitHub by Panakotta00
, 1 year ago
via GitHub by spannerman79
, 1 year ago
Connection reset by peer
via GitHub by 61352151511
, 2 years ago
Connection reset by peer
via GitHub by matty
, 2 years ago
Connection reset by peer
java.io.IOException: Connection reset by peer
at sun.nio.ch.FileDispatcherImpl.read0(Native Method)
at sun.nio.ch.SocketDispatcher.read(SocketDispatcher.java:39)
at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:223)
at sun.nio.ch.IOUtil.read(IOUtil.java:192)
at sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:380)
at io.netty.buffer.UnpooledUnsafeDirectByteBuf.setBytes(UnpooledUnsafeDirectByteBuf.java:436)
at io.netty.buffer.AbstractByteBuf.writeBytes(AbstractByteBuf.java:870)
at io.netty.channel.socket.nio.NioSocketChannel.doReadBytes(NioSocketChannel.java:208)
at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:87)
at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:480)
at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:447)
at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:341)
at io.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:101)
at java.lang.Thread.run(Thread.java:745)

Users with the same issue

147 times, 2 days ago
3 times, 1 week ago
Once, 2 weeks ago
11 times, 1 month ago
10 times, 2 months ago

Write tip

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