The Java Servlet Expect Group reported that they have identified a specific HTTP2 server use-case that cannot be easily addressed using the existing ALPN APIs.
This changeset fixes that problem. It supports a new callback mechanism to allow TLS server applications to set an application protocol during the TLS handshake. Specifically it allows the cipher suite chosen by the TLS protocol implementation to be examined by the TLS server application before it sets the application protocol. Additional TLS parameters are also available for inspection in the callback function. This new mechanism is available only to TLS server applications. TLS clients will continue to use the existing ALPN APIs. Thanks Bug: https://bugs.openjdk.java.net/browse/JDK-8170282 Webrev: http://cr.openjdk.java.net/~vinnie/8170282/webrev.00/