2012-01-31 6 views
1

JAXBとSpringフレームワークを使用してSOAPベースのWebサービスを作成しています。私は春のWebサービスを使用して動的にWSDLファイルを生成していますが、私はそれを試してみて、アクセスするとき、私は次のようなエラーになっています:の最後に今最初にすべての、私は見たことがない(Z)VをJAXB SOAPサービス実行時エラー(XPathメソッドが見つかりません)

java.lang.NoSuchMethodError: org.apache.xpath.XPathContext.<init>(Z)V 
at org.apache.xpath.jaxp.XPathExpressionImpl.eval(XPathExpressionImpl.java:115) 
at org.apache.xpath.jaxp.XPathExpressionImpl.eval(XPathExpressionImpl.java:99) 
at org.apache.xpath.jaxp.XPathExpressionImpl.evaluate(XPathExpressionImpl.java:184) 
at org.springframework.xml.xpath.Jaxp13XPathExpressionFactory$Jaxp13XPathExpression.evaluate(Jaxp13XPathExpressionFactory.java:114) 
at org.springframework.xml.xpath.Jaxp13XPathExpressionFactory$Jaxp13XPathExpression.evaluateAsNodeList(Jaxp13XPathExpressionFactory.java:106) 
at org.springframework.ws.transport.http.WsdlDefinitionHandlerAdapter.transformLocations(WsdlDefinitionHandlerAdapter.java:200) 
at org.springframework.ws.transport.http.WsdlDefinitionHandlerAdapter.handle(WsdlDefinitionHandlerAdapter.java:128) 
at org.springframework.ws.transport.http.MessageDispatcherServlet.doService(MessageDispatcherServlet.java:213) 
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:882) 
at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:778) 
at javax.servlet.http.HttpServlet.service(HttpServlet.java:734) 

をNoSuchMethodErrorの前に私はそれが何を意味するのか不明ですが、ここでも非常に限られたスタックトレースを取得しています。私は同じプロジェクトのクラスが存在しないメソッドをどのように呼び出すことができるかも理解していません。誰かが私がこれを解決するために探し始めなければならないところにいくつかのアイデアを持っているなら、それは素晴らしいだろう。もちろん、より多くの情報を要請に応じて提供することができます。

EDIT:

だから、MVN depedency使用:のxpathの異なるバージョンとみとめ瓶があるかどうかを確認するために、ツリーのコマンドを私は次の出力を得る:

--- maven-dependency-plugin:2.1:tree (default-cli) @ LicensingSOAPService --- 
[INFO] com.cepstral.licensing:LicensingSOAPService:war:0.1 
[INFO] +- junit:junit:jar:3.8.1:test 
[INFO] +- com.sun.xml.messaging.saaj:saaj-impl:jar:1.3:runtime 
[INFO] | \- javax.xml.soap:saaj-api:jar:1.3:runtime 
[INFO] +- org.springframework.ws:spring-ws-core:jar:2.0.3.RELEASE:compile 
[INFO] | +- org.springframework.ws:spring-xml:jar:2.0.3.RELEASE:compile 
[INFO] | +- wsdl4j:wsdl4j:jar:1.6.1:compile 
[INFO] | +- javax.xml.stream:stax-api:jar:1.0-2:compile 
[INFO] | \- commons-logging:commons-logging:jar:1.1.1:compile 
[INFO] +- org.springframework.ws:spring-ws-security:jar:2.0.3.RELEASE:runtime 
[INFO] | +- com.sun.xml.wsit:xws-security:jar:1.3.1:runtime 
[INFO] | +- com.sun.xml.wsit:wsit-rt:jar:1.1:runtime 
[INFO] | \- org.apache.ws.security:wss4j:jar:1.5.8:runtime 
[INFO] |  \- org.apache.santuario:xmlsec:jar:1.4.3:runtime 
[INFO] +- javax.xml.bind:jaxb-api:jar:2.0:compile 
[INFO] | +- javax.xml.bind:jsr173_api:jar:1.0:compile 
[INFO] | \- javax.activation:activation:jar:1.1:compile 
[INFO] +- com.sun.xml.bind:jaxb-impl:jar:2.0.3:compile 
[INFO] +- org.springframework:spring-context:jar:3.1.0.RELEASE:compile 
[INFO] | +- org.springframework:spring-core:jar:3.1.0.RELEASE:compile 
[INFO] | +- org.springframework:spring-expression:jar:3.1.0.RELEASE:compile 
[INFO] | \- org.springframework:spring-asm:jar:3.1.0.RELEASE:compile 
[INFO] +- org.springframework:spring-beans:jar:3.1.0.RELEASE:compile 
[INFO] +- org.springframework:spring-aop:jar:3.1.0.RELEASE:compile 
[INFO] | \- aopalliance:aopalliance:jar:1.0:compile 
[INFO] +- org.springframework:spring-web:jar:3.1.0.RELEASE:compile 
[INFO] +- org.jdom:jdom:jar:1.1.2:compile 
[INFO] | \- jaxen:jaxen:jar:1.1.3:compile 
[INFO] |  +- dom4j:dom4j:jar:1.6.1:compile 
[INFO] |  +- jdom:jdom:jar:1.0:compile 
[INFO] |  +- xml-apis:xml-apis:jar:1.3.02:compile 
[INFO] |  +- xerces:xercesImpl:jar:2.6.2:compile 
[INFO] |  \- xom:xom:jar:1.0:compile 
[INFO] |  +- xerces:xmlParserAPIs:jar:2.6.2:compile 
[INFO] |  +- xalan:xalan:jar:2.7.1:compile 
[INFO] |  \- com.ibm.icu:icu4j:jar:2.6.1:compile 
[INFO] +- org.springframework:spring-webmvc:jar:3.1.0.RELEASE:compile 
[INFO] | \- org.springframework:spring-context-support:jar:3.1.0.RELEASE:compile 
[INFO] +- org.springframework:spring-jdbc:jar:3.1.0.RELEASE:compile 
[INFO] | \- org.springframework:spring-tx:jar:3.0.6.RELEASE:compile 
[INFO] +- org.springframework:spring-oxm:jar:3.1.0.RELEASE:compile 
[INFO] | \- commons-lang:commons-lang:jar:2.5:compile 
[INFO] +- org.springframework.security:spring-security-core:jar:3.1.0.RELEASE:compile 
[INFO] | \- org.springframework.security:spring-security-crypto:jar:3.1.0.RELEASE:compile 
[INFO] \- commons-dbcp:commons-dbcp:jar:1.4:compile 
[INFO] \- commons-pool:commons-pool:jar:1.5.4:compile 

私は不審な何も表示されませんが、だから私は本当にどこに行くべきか分からない。私はglassfishの-verboseオプションを使ってエラーを追跡しようとし続けています。みんな、ありがとう。

編集2:だから、GlassFishの中で、それは次のことを示してログインします。どこかのXalan-2.6.0 jarファイルがロードされていることを確実に示している

[Loaded org.springframework.web.context.request.AbstractRequestAttributes from file:/C:/glassfish/glassfish/domains/domain1/applications/licensingSoap/WEB-INF/lib/spring-web-3.1.0.RELEASE.jar] 
[Loaded org.springframework.web.context.request.ServletRequestAttributes from file:/C:/glassfish/glassfish/domains/domain1/applications/licensingSoap/WEB-INF/lib/spring-web-3.1.0.RELEASE.jar] 
[Loaded org.apache.xml.dtm.DTMManager from file:/C:/glassfish/glassfish/domains/domain1/applications/licensingSoap/WEB-INF/lib/xalan-2.6.0.jar] 
[Loaded org.apache.xpath.XPathContext from file:/C:/glassfish/glassfish/domains/domain1/applications/licensingSoap/WEB-INF/lib/xalan-2.6.0.jar] 
[Loaded org.apache.xml.dtm.ObjectFactory$ConfigurationError from file:/C:/glassfish/glassfish/domains/domain1/applications/licensingSoap/WEB-INF/lib/xalan-2.6.0.jar] 
[Loaded org.apache.xml.dtm.DTMException from file:/C:/glassfish/glassfish/domains/domain1/applications/licensingSoap/WEB-INF/lib/xalan-2.6.0.jar] 
[Loaded org.apache.xml.dtm.DTMConfigurationException from file:/C:/glassfish/glassfish/domains/domain1/applications/licensingSoap/WEB-INF/lib/xalan-2.6.0.jar] 
[Loaded org.apache.xml.dtm.DTM from file:/C:/glassfish/glassfish/domains/domain1/applications/licensingSoap/WEB-INF/lib/xalan-2.6.0.jar] 
[Loaded org.apache.xalan.extensions.ExpressionContext from file:/C:/glassfish/glassfish/domains/domain1/applications/licensingSoap/WEB-INF/lib/xalan-2.6.0.jar] 
[Loaded org.apache.xml.utils.ObjectStack from file:/C:/glassfish/glassfish/domains/domain1/applications/licensingSoap/WEB-INF/lib/xalan-2.6.0.jar] 
[Loaded org.apache.xml.utils.IntVector from file:/C:/glassfish/glassfish/domains/domain1/applications/licensingSoap/WEB-INF/lib/xalan-2.6.0.jar] 
[Loaded org.apache.xml.utils.IntStack from file:/C:/glassfish/glassfish/domains/domain1/applications/licensingSoap/WEB-INF/lib/xalan-2.6.0.jar] 

が、私は、ターゲットの\ licensingSoapで見たとき私のmavenプロジェクトのフォルダには、私が望むものと仮定しているxalan-2.7.1 jarファイルしかありません。私は、この瓶がグラスフィッシュの実行時にどのように栽培されているのか分かりません。何か案は?

答えて

1

おそらく、間違ったバージョンのクラスファイルをどこかから取得しているでしょう。 -verbose:classを使用して再実行し、これらのクラスがどこからロードされているかを確認します。 結果を解釈するのに助けが必要な場合は、ここに結果を投稿してください(あなたが許されているサイズを知ることができない場合は!)。

HTH、

デビッド

+0

あなたは-verbose使う意味:JVM変数でクラスを自分のGlassFishの容器の中に? – thatidiotguy

+1

あなたがGlassfishの場合、あなたはかなりの出力を得るでしょうが、あなたが問題を抱えているクラス名を検索することができるはずです – davidfrancis

+1

Googleには、 -verbose:classスタックトレース内のクラスがどこからロードされているかを確認できます。そして、うまくいけばどこが間違っているのか理解することができます。 – davidfrancis

関連する問題