sockets - java.net.SocketException: Connection reset -


i getting following error trying read socket. i'm doing readint() on inputstream, , getting error. perusing documentation suggests client part of connection closed connection. in scenario, server.

i have access client log files , not closing connection, , in fact log files suggest closing connection. have idea why happening? else check for? arise when there local resources perhaps reaching thresholds?


i note have following line:

socket.setsotimeout(10000); 

just prior readint(). there reason (long story), curious, there circumstances under might lead indicated error? have server running in ide, , happened leave ide stuck on breakpoint, , noticed exact same errors begin appearing in own logs in ide.

anyway, mentioning it, not red herring. :-(

there several possible causes.

  1. the other end has deliberately reset connection, in way not document here. rare, , incorrect, application software this, not unknown commercial software.

  2. more commonly, caused writing connection other end has closed normally. in other words application protocol error.

  3. it can caused closing socket when there unread data in socket receive buffer.

  4. in windows, 'software caused connection abort', not same 'connection reset', caused network problems sending end. there's microsoft knowledge base article this.


Comments

Popular posts from this blog

c++ - How do I get a multi line tooltip in MFC -

asp.net - In javascript how to find the height and width -

c# - DataTable to EnumerableRowCollection -