rhernandez35 opened a new pull request #146: Set accessiblity flag on reflected methods in ReflectionUtils URL: https://github.com/apache/httpcomponents-core/pull/146 Prior to this change, attempts to reflectively invoke methods on protected classes in other modules could fail on JDK9 and above. Currently, the methods in ReflectionUtils are only used to get and set properties related to ALPN on SSLEngine instances at runtime. On JDK11, reflectively invoking the `getApplicationProtocol` method on `SSLEngineImpl`, a protected class, throws an `IllegalAccessException`. `callGetter` swallows this and returns `null`, causing the client runtime to ignore whatever protocol was negotiated with ALPN and default to HTTP/1.1. This specific reflective access is still illegal and will eventually break in a future Java release. A proper fix would require creating a multi-release jar with a dedicated SSLEngine accessor class for JDK9+ that can natively invoke these methods.
---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
