JDK-7183450 : Hang reading from HTTP server with JDK7 when IPv6 is enabled
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.net
  • Affected Version: 7,7u5
  • Priority: P3
  • Status: Resolved
  • Resolution: Cannot Reproduce
  • OS: windows_7
  • CPU: x86
  • Submitted: 2012-07-11
  • Updated: 2013-07-15
  • Resolved: 2013-07-15
Related Reports
Duplicate :  
Duplicate :  
Duplicate :  
Description
FULL PRODUCT VERSION :
java version "1.7.0_05"
Java(TM) SE Runtime Environment (build 1.7.0_05-b05)
Java HotSpot(TM) 64-Bit Server VM (build 23.1-b03, mixed mode)

ADDITIONAL OS VERSION INFORMATION :
Microsoft Windows [Version 6.1.7601]

A DESCRIPTION OF THE PROBLEM :
Unless using the -Djava.net.preferIPv4Stack=true, the report in bug 7115226 hangs every time.

REGRESSION.  Last worked in version 7

STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
See bug 7115226 - compile and run the program.

Another way to reproduce is to run a Tomcat unit test

1. svn co http://svn.apache.org/repos/asf/tomcat/trunk
2. cd trunk
3. [with java 6] ant
4. [with java 7]  ant -Dtest.entry=org.apache.catalina.connector.TestSendFile test-bio test-nio

Work arounds are
a) Use Java 6
b) Use -Djava.net.preferIPv4Stack=true when using Java 7



EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
test case hangs using Java 7, works fine when using Java 6 or using -Djava.net.preferIPv4Stack=true


REPRODUCIBILITY :
This bug can be reproduced always.

CUSTOMER SUBMITTED WORKAROUND :
-Djava.net.preferIPv4Stack=true

Comments
This issue is no longer reproducible. Although the Tomcat project pointed out no longer compiles, creating a socket and connecting/reading from it does not hang when using a vpn environment.
15-07-2013

EVALUATION The issue is not reproducible too. This could be a firewall issue or some network configuration issue on the host machine/router.
23-07-2012