JDK-8143397 : It looks like InetAddress.isReachable(timeout) works incorrectly
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.net
  • Affected Version: 8u72,9
  • Priority: P3
  • Status: Closed
  • Resolution: Fixed
  • OS: windows
  • Submitted: 2015-11-20
  • Updated: 2022-06-27
  • Resolved: 2015-12-09
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 7 JDK 8 JDK 9
7u281Fixed 8u101Fixed 9 b97Fixed
Related Reports
Relates :  
Relates :  
Description
Negative networking test
  HostReachability/ReachableHostNegativeTest
has started to fail after fixes  for JDK-8135305, JDK-8133015 were integrated.
Comments
URL: http://hg.openjdk.java.net/jdk9/jdk9/jdk/rev/8418f5ee381d User: lana Date: 2015-12-16 19:10:55 +0000
16-12-2015

Core-libs nightly is OK. SQE OK to take the fix to CPU16_01
11-12-2015

URL: http://hg.openjdk.java.net/jdk9/dev/jdk/rev/8418f5ee381d User: robm Date: 2015-12-09 15:16:23 +0000
09-12-2015

The most probable cause of a problem is JDK-8135305.
07-12-2015

This is a regression introduced in 8u72. What is a justification to defer it from the release? Probably whould better to revoke the fix that caused this regression?
07-12-2015

I think a possible contribution to this issue is that there is an "undocumented" minimum timeout for the API calls c.f. https://msdn.microsoft.com/en-us/library/windows/desktop/aa366050%28v=vs.85%29.aspx " Minimum timeout There appears to be an undocumented minimum timeout, below which unexpected behavior ensues! This minimum timeout is 1000 milliseconds. In Windows 7, setting it to any number between 1ms and 999ms results in these behaviors: 1: The API still takes 1000ms to timeout if the ping gets lost, regardless of the requested timeout time. 2: The API still receives pings with round-trip times of >100ms even with a requested timeout of 1ms. 3: The API randomly returns instantly with error code 11010 (Error due to lack of resources) as if the ping timed-out, even with a requested timeout of 800ms. This is not supposed to happen. When it does this, the ping goes out (as seen by SmartSniff), but the reply is ignored since the API returns instantly with the error. " the minimum reliable timeout seems to be about 100ms
23-11-2015

I attached the test TimeIsReachableTest.java and 8u72b02 and 8u72b03 test results for different values of timeout.
23-11-2015