JDK-8217094 : HttpClient SSL race if a socket IOException is raised before ALPN is available
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.net
  • Affected Version: 11,12,13
  • Priority: P3
  • Status: Closed
  • Resolution: Fixed
  • Submitted: 2019-01-15
  • Updated: 2019-09-26
  • Resolved: 2019-01-16
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 11 JDK 12 JDK 13
11.0.4-oracleFixed 12.0.2Fixed 13 b04Fixed
Description
While investigating another test I stumbled on a race condition in the SSLTube/SSLFlowDelegate: if an IOException is raised at the lower level (socket) before the ALPN is available the ALPN CF may never be completed, and as a result the connection may be stuck. 
Comments
Fix Request Backporting this patch fixes a race condition in SSL clients. Patch applies cleanly to 11u, but the test fails to compile. See RFR here: https://mail.openjdk.java.net/pipermail/jdk-updates-dev/2019-March/000775.html
13-03-2019

Fix Request: A race condition which should be eliminated. Auto unit test case developed.
14-02-2019