2016-05-03 16 views
-1

webapp(Spring 3)内のxerces(xsd v1.1)でxmlを検証する必要があります.jboss 6サーバーに展開する必要があります。しかし、私は展開でエラーが発生しています。これはTomcatでは起こりません。これは、次の例外がスローされます。Jboss 6、Spring&Xerces

org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter#0': Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter]: Constructor threw exception; nested exception is java.lang.ClassCastException: org.apache.xalan.processor.TransformerFactoryImpl cannot be cast to javax.xml.transform.TransformerFactory 

は、私は、JBoss-web.xmlファイルとJBoss-classloading.xmlと、いくつかの設定を試してみましたが、私は動作しませんでした。いくつかのアイデア?

答えて

0

のJBossクラスローダーがイライラすることができます(私たちはセキュリティのために支払う価格!)しかし、これは...助けファイルシステム上のどこかにあなたの1.1 xervesライブラリを配置して、JBossの起動時に次のJVM引数を追加する必要があります

-Djava.endorsed.dirs=/PATH/TO/LIBRARIES 
-Djavax.xml.stream.XMLInputFactory=com.sun.xml.internal.stream.XMLInputFactoryImpl 
-Djavax.xml.stream.XMLOutputFactory=com.sun.xml.internal.stream.XMLOutputFactoryImpl 
-Djavax.xml.stream.XMLEventFactory=com.sun.xml.internal.stream.events.XMLEventFactoryImpl 
関連する問題