0

我已经安装了我的应用程序并重新启动WAS 8.5,我看到下面的异常SystemOut.log,因为它在WAS 7.

java.lang.NoSuchMethodError: org/apache/http/conn/ssl/SSLSocketFactory.<init>(Ljava/lang/String;Ljava/security/KeyStore;Ljava/lang/String;Ljava/security/KeyStore;Ljava/security/SecureRandom;Lorg/apache/http/conn/ssl/X509HostnameVerifier;)V

谁能帮我解决这个问题?

4

2 回答 2

0

我猜您正在部署并尝试使用一个版本的 Apache HttpClient,但 WebSphere 在其库中包含不同的版本。如果您可以使用包含 WebSphere 的版本,那将是最简单的,但如果您需要使用特定版本,您可以将 WebSphere 类加载器策略更改为 PARENT_LAST。

于 2012-12-24T02:52:15.957 回答
-1

websphere8 /WebSphere/AppServer/plugins/com.ibm.ws.prereq.jaxrs.jar 有包 org.http.* com.ibm.ws.prereq.jaxrs.jar 和 HttpClient.jar 冲突!

更改类加载器命令无效,因为 websphere 启动时已加载 com.ibm.ws.prereq.jaxrs.jar!

您可以将 HttpClient 包从 org.http.* 更改为 net.test.* 以避免冲突

ps: http ://www.ibm.com/developerworks/cn/websphere/library/techarticles/1108_jiangwk_classloader/1108_jiangwk_classloader.html

于 2014-12-18T03:41:42.123 回答