Re: 8203937: Not possible to read data from socket after write detects connection reset

2018-06-18 Thread Norman Maurer
Sorry for the late response but I was able to verify the fix and all looks good 
again. 

Thanks for the quick turn-around,
Norman


> On 6. Jun 2018, at 11:03, Chris Hegarty  wrote:
> 
> 
>> On 3 Jun 2018, at 12:07, Alan Bateman  wrote:
>> 
>> ...
>> The following is the webrev to remove the detection of connection reset in 
>> the socket writing good. We can think of this as a follow-up to JDK-8199329 
>> in that it removes more of the JDK 1.4 era code that special cased 
>> connection reset on Solaris to work around the eager reporting of network 
>> errors. With this change, it means that hitting the connection reset when 
>> writing will not interfere with any subsequent reading from the socket.
> 
> +1 This is my reading of the code and your changes.
> 
>> I've added a test to ensure that further changes in this area don't change 
>> the behavior on Linux and macOS. I've run the tests several hundred tests 
>> and haven't seen any intermittent failures (which is always a concern with 
>> tests like this).
>> 
>> http://cr.openjdk.java.net/~alanb/8203937/webrev/index.html
> 
> Looks good.
> 
> -Chris.
> 



Re: 8203937: Not possible to read data from socket after write detects connection reset

2018-06-06 Thread Chris Hegarty


> On 3 Jun 2018, at 12:07, Alan Bateman  wrote:
> 
> ...
> The following is the webrev to remove the detection of connection reset in 
> the socket writing good. We can think of this as a follow-up to JDK-8199329 
> in that it removes more of the JDK 1.4 era code that special cased connection 
> reset on Solaris to work around the eager reporting of network errors. With 
> this change, it means that hitting the connection reset when writing will not 
> interfere with any subsequent reading from the socket.

+1 This is my reading of the code and your changes.

> I've added a test to ensure that further changes in this area don't change 
> the behavior on Linux and macOS. I've run the tests several hundred tests and 
> haven't seen any intermittent failures (which is always a concern with tests 
> like this).
> 
> http://cr.openjdk.java.net/~alanb/8203937/webrev/index.html

Looks good.

-Chris.



Re: 8203937: Not possible to read data from socket after write detects connection reset

2018-06-03 Thread Norman Maurer
I will test this with Netty as well and report back

Bye
Norman

> Am 03.06.2018 um 13:07 schrieb Alan Bateman :
> 
> This is a follow-up to the "Problem with half-closure related to 
> connection-reset in Java 11" thread that we've been discussing here over the 
> last few days. As we discussed, you can't reliably rely on being able to read 
> bytes after the connection reset but it is a reminder that a subtle behavior 
> change (even in a completely unspecified area) can break existing tests or 
> code that may rely on the behavior on specific platforms.
> 
> The following is the webrev to remove the detection of connection reset in 
> the socket writing good. We can think of this as a follow-up to JDK-8199329 
> in that it removes more of the JDK 1.4 era code that special cased connection 
> reset on Solaris to work around the eager reporting of network errors. With 
> this change, it means that hitting the connection reset when writing will not 
> interfere with any subsequent reading from the socket. I've added a test to 
> ensure that further changes in this area don't change the behavior on Linux 
> and macOS. I've run the tests several hundred tests and haven't seen any 
> intermittent failures (which is always a concern with tests like this).
> 
> http://cr.openjdk.java.net/~alanb/8203937/webrev/index.html
> 
> -Alan


8203937: Not possible to read data from socket after write detects connection reset

2018-06-03 Thread Alan Bateman
This is a follow-up to the "Problem with half-closure related to 
connection-reset in Java 11" thread that we've been discussing here over 
the last few days. As we discussed, you can't reliably rely on being 
able to read bytes after the connection reset but it is a reminder that 
a subtle behavior change (even in a completely unspecified area) can 
break existing tests or code that may rely on the behavior on specific 
platforms.


The following is the webrev to remove the detection of connection reset 
in the socket writing good. We can think of this as a follow-up to 
JDK-8199329 in that it removes more of the JDK 1.4 era code that special 
cased connection reset on Solaris to work around the eager reporting of 
network errors. With this change, it means that hitting the connection 
reset when writing will not interfere with any subsequent reading from 
the socket. I've added a test to ensure that further changes in this 
area don't change the behavior on Linux and macOS. I've run the tests 
several hundred tests and haven't seen any intermittent failures (which 
is always a concern with tests like this).


http://cr.openjdk.java.net/~alanb/8203937/webrev/index.html

-Alan