• Register
0 votes
162 views

Problem :

I am trying to implement an HTTP Server using Sockets but getting bellow error

java net socketexception connection reset by peer socket write error

6 5 3
6,930 points

1 Answer

0 votes

Solution :

1. It happens when TCP socket is about to "close" but your  code is not yet notified.

2. You already must have written throws  IOException and SocketException extends IOException.

3. You just need to properly handle IOException because it is a normal part of the api.

Further Readings:

9 7 4
38,600 points

Related questions

0 votes
1 answer 44 views
44 views
Problem: I am seeing "{writer,send_failed,{error,closed}}" error on server side and "java.net.SocketException: Connection reset by peer: socket write error" error on java client side intermittently. What could possibly go wrong here? Both server and ... rabbitmq.client.impl.ChannelN.basicPublish(ChannelN.java:630) at com.rabbitmq.client.impl.ChannelN.basicPublish(ChannelN.java:621) Please help me.
asked Mar 23 LizzyM 6.1k points
0 votes
1 answer 280 views
280 views
Problem : I am getting bellow error while using Sockets java.net.socketexception: software caused connection abort: socket write error
asked Oct 19, 2019 peterlaw 6.9k points
1 vote
2 answers 315 views
315 views
What is the meaning of the "connection reset by peer" error on a TCP connection? Why do we get the error "Connection reset by peer" during a web service call? Explaining Connection Reset by Peer Log Messages? Is it a fatal error or just a notification or related ... it mean when it says the connection was reset? How do I fix my connection reset? What does Connection reset by peer mean on Instagram
asked Jul 23, 2019 sadmin 2.1k points
1 vote
2 answers 77 views
77 views
Problem: I am able to login through webservices api to particular account on 'Oracle on demand'. When i tries to call 'accountQueryPage' method of the stub class (Stub class is generated with help Account.wsdl file), i got the following exception java.net.SocketException: Software caused connection abort: recv failed Can anyone give me some pointers.
asked Mar 27 LizzyM 6.1k points
2 votes
1 answer 24 views
24 views
Problem: I am able to login through webservices api to particular account on 'Oracle on demand'. When i tries to call 'accountQueryPage' method of the stub class (Stub class is generated with help Account.wsdl file), i got the following exception java.net.SocketException: Software caused connection abort: recv failed Can anyone give me some pointers.
asked Mar 24 LizzyM 6.1k points