[英]JBoss7: class configured for SSLContext: sun.security.ssl.SSLContextImpl$TLS10Context not a SSLContext
I am developing an application which is a standalone application and gonna package it as a jar file (Which is lika a OSGi Plugin
) and will deploy that jar into JBoss
. 我正在开发一个独立的应用程序,并将其打包为jar文件(这是
OSGi Plugin
简称),并将该jar into JBoss
部署jar into JBoss
。
When I run my application in my eclipse the application works fine. 当我在Eclipse中运行应用程序时,该应用程序运行良好。 In Jboss It throws error.
在Jboss中引发错误。
java.lang.ClassNotFoundException: org.w3c.dom.Node
. java.lang.ClassNotFoundException: org.w3c.dom.Node
。
If I add rt.jar
to WEB-INF/lib
folder and deploy into Jboss. 如果我将
rt.jar
添加到WEB-INF/lib
文件夹并部署到Jboss中。 That error no longer thrown. 该错误不再引发。 But I got a new exception Even I added
jsse.jar
to lib
but unable to resolve the error. 但是我有一个新的异常,即使我向
lib
添加了jsse.jar
但也无法解决该错误。
com.microsoft.sqlserver.jdbc.SQLServerException: The driver could not establish a
secure connection to SQL Server by using Secure Sockets Layer (SSL) encryption.
Error: "class configured for SSLContext: sun.security.ssl.SSLContextImpl$TLS10Context
not a SSLContext".
......
Caused by: java.security.NoSuchAlgorithmException: class configured for
SSLContext: sun.security.ssl.SSLContextImpl$TLS10Context not a SSLContext
06:10:53,484 ERROR [stderr] (default-short-running-threads-threads - 26) at
sun.security.jca.GetInstance.checkSuperClass(GetInstance.java:258)
06:10:53,484 ERROR [stderr] (default-short-running-threads-threads - 26) at
sun.security.jca.GetInstance.getInstance(GetInstance.java:237)
06:10:53,484 ERROR [stderr] (default-short-running-threads-threads - 26) at
sun.security.jca.GetInstance.getInstance(GetInstance.java:164)
06:10:53,484 ERROR [stderr] (default-short-running-threads-threads - 26) at
javax.net.ssl.SSLContext.getInstance(SSLContext.java:156)
06:10:53,500 ERROR [stderr] (default-short-running-threads-threads - 26) at
com.microsoft.sqlserver.jdbc.TDSChannel.enableSSL(IOBuffer.java:1353)
My Development environment is Jdk1.7
, Windows XP
and Eclipse Juno
The server Environment is also same as my local environment. 我的开发环境是
Jdk1.7
, Windows XP
和Eclipse Juno
服务器环境也与我的本地环境相同。
Also try to add @PowerMockIgnore("javax.net.ssl.*") as class annotation. 也尝试将@PowerMockIgnore(“ javax.net.ssl。*”)添加为类注释。 Worked for me.
为我工作。
org.w3c.dom.Node;resolution:="optional"
org.w3c.dom.Node;resolution:="optional"
edit: or you could switch your DOM-parsing code to rely on an external library not provided with the jdk like dom4j and include that as a library 编辑:或者您可以切换DOM解析代码,使其依赖于dom4j之类的jdk未提供的外部库,并将其作为库包含在内
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.