当我试图嘲笑现有的网络服务时,我遇到了一个令人困惑的情况。
抽象
我正在尝试使用该服务的WSDL生成的接口来模拟Sharepoint Web服务。这种方式失败了。天真地,我只是建立了一个Web服务EJB,实现了从WSDL生成的接口。
1。设置
我们在JBoss 7上有一个JEE应用程序。它使用Sharepoint DMS提供的SOAP服务。我们使用maven和CXF插件将WSDL API封装到独立的DMS API JAR中。此DMS API在调用工厂中使用,该工厂从该对象创建DocumentSoap - 这是JEE App使用的真实SOAP客户端。
2。模拟
为了集成测试目的,我们将另一个EJB应用程序与产品EAR一起发送。这个其他EJB包含服务,servlet,数据夹具等pp。它应包含一个模拟web服务。 Web服务应该与Sharepoint Web服务的规范相匹配。
第3。我做了什么
我使用DMS API jar设置了一个新的Webservice Bean。看起来像这样
/**
* Created by me on 23.02.2016.
*/
@WebService(portName = "documentPort"
, serviceName = "Documents"
, targetNamespace = "http://FooService.SharePoint.API.Webservices.Documents"
, name = "Documents"
, endpointInterface = "de.customer.ws.fooservice.documents.DocumentsSoap")
@Stateless
@Local(DocumentsSoap.class)
public class DmsMockDocumentWebServiceImpl implements DocumentsSoap {
}
然后我(成功)可以使用我的bean的wdsl位置替换调用工厂中的URL。到目前为止,非常好。
4。问题
但是当我尝试访问模拟服务时,我收到此错误:
14:14:51,404 SEVERE [de.customer.ws.onlineanbindung.FooServiceCallFactory] (EJB default - 7) Java Fehlermeldung: javax.xml.ws.WebServiceException: Could not find service named {http://FooService.SharePoint.API.Webservices.Documents/}Documents in wsdl http://localhost:8080/ProofCenterTestSuite/Documents/Documents?wsdl
at org.apache.cxf.jaxws.ServiceImpl.initializePorts(ServiceImpl.java:159) [cxf-rt-frontend-jaxws-2.4.8-patch-01.jar:2.4.8-patch-01]
at org.apache.cxf.jaxws.ServiceImpl.<init>(ServiceImpl.java:147) [cxf-rt-frontend-jaxws-2.4.8-patch-01.jar:2.4.8-patch-01]
at org.jboss.wsf.stack.cxf.client.ProviderImpl.createServiceDelegate(ProviderImpl.java:141)
at javax.xml.ws.Service.<init>(Service.java:57) [jboss-jaxws-api_2.2_spec-2.0.1.Final.jar:2.0.1.Final]
at de.customer.ws.fooservice.documents.Documents.<init>(Documents.java:31) [DMS-API-2.6.6.5-SNAPSHOT.jar:]
at de.customer.ws.onlineanbindung.FooServiceCallFactory.getDocuments(FooServiceCallFactory.java:121) [PROOFCenter-EJB.jar:]
at de.customer.ws.onlineanbindung.FooServiceCallFactory.createDocumentsClient(FooServiceCallFactory.java:88) [PROOFCenter-EJB.jar:]
at de.customer.ws.onlineanbindung.FooServiceCallFactory.getDocumentClient(FooServiceCallFactory.java:79) [PROOFCenter-EJB.jar:]
at de.customer.ws.onlineanbindung.FooServiceCallFactory.add(FooServiceCallFactory.java:214) [PROOFCenter-EJB.jar:]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [rt.jar:1.7.0_45]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) [rt.jar:1.7.0_45]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.7.0_45]
at java.lang.reflect.Method.invoke(Method.java:606) [rt.jar:1.7.0_45]
at org.jboss.as.ee.component.ManagedReferenceMethodInterceptorFactory$ManagedReferenceMethodInterceptor.processInvocation(ManagedReferenceMethodInterceptorFactory.java:72) [jboss-as-ee-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.invocation.WeavedInterceptor.processInvocation(WeavedInterceptor.java:53) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ee.component.interceptors.UserInterceptorFactory$1.processInvocation(UserInterceptorFactory.java:36) [jboss-as-ee-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.component.invocationmetrics.ExecutionTimeInterceptor.processInvocation(ExecutionTimeInterceptor.java:43) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.jpa.interceptor.SBInvocationInterceptor.processInvocation(SBInvocationInterceptor.java:47) [jboss-as-jpa-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.invocation.InitialInterceptor.processInvocation(InitialInterceptor.java:21) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.invocation.ChainedInterceptor.processInvocation(ChainedInterceptor.java:61) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ee.component.interceptors.ComponentDispatcherInterceptor.processInvocation(ComponentDispatcherInterceptor.java:53) [jboss-as-ee-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.component.pool.PooledInstanceInterceptor.processInvocation(PooledInstanceInterceptor.java:51) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.tx.CMTTxInterceptor.invokeInCallerTx(CMTTxInterceptor.java:200) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.as.ejb3.tx.CMTTxInterceptor.required(CMTTxInterceptor.java:304) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.as.ejb3.tx.CMTTxInterceptor.processInvocation(CMTTxInterceptor.java:188) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.component.interceptors.CurrentInvocationContextInterceptor.processInvocation(CurrentInvocationContextInterceptor.java:41) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.security.SecurityContextInterceptor.processInvocation(SecurityContextInterceptor.java:76) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.component.interceptors.ShutDownInterceptorFactory$1.processInvocation(ShutDownInterceptorFactory.java:42) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.component.interceptors.LoggingInterceptor.processInvocation(LoggingInterceptor.java:59) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ee.component.NamespaceContextInterceptor.processInvocation(NamespaceContextInterceptor.java:50) [jboss-as-ee-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.component.interceptors.AdditionalSetupInterceptor.processInvocation(AdditionalSetupInterceptor.java:32) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ee.component.TCCLInterceptor.processInvocation(TCCLInterceptor.java:45) [jboss-as-ee-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.invocation.ChainedInterceptor.processInvocation(ChainedInterceptor.java:61) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ee.component.ViewService$View.invoke(ViewService.java:165) [jboss-as-ee-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.as.ee.component.ViewDescription$1.processInvocation(ViewDescription.java:181) [jboss-as-ee-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.invocation.ChainedInterceptor.processInvocation(ChainedInterceptor.java:61) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ee.component.ProxyInvocationHandler.invoke(ProxyInvocationHandler.java:72) [jboss-as-ee-7.1.3.Final.jar:7.1.3.Final]
at de.customer.ws.onlineanbindung.FooServiceCallFactory$$$view1204.add(Unknown Source) [PROOFCenter-EJB.jar:]
at de.customer.ws.onlineanbindung.FakturaDocumentStorer.storeDocument(FakturaDocumentStorer.java:47) [PROOFCenter-EJB.jar:]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [rt.jar:1.7.0_45]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) [rt.jar:1.7.0_45]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.7.0_45]
at java.lang.reflect.Method.invoke(Method.java:606) [rt.jar:1.7.0_45]
at org.jboss.as.ee.component.ManagedReferenceMethodInterceptorFactory$ManagedReferenceMethodInterceptor.processInvocation(ManagedReferenceMethodInterceptorFactory.java:72) [jboss-as-ee-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.invocation.WeavedInterceptor.processInvocation(WeavedInterceptor.java:53) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ee.component.interceptors.UserInterceptorFactory$1.processInvocation(UserInterceptorFactory.java:36) [jboss-as-ee-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.component.invocationmetrics.ExecutionTimeInterceptor.processInvocation(ExecutionTimeInterceptor.java:43) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.jpa.interceptor.SBInvocationInterceptor.processInvocation(SBInvocationInterceptor.java:47) [jboss-as-jpa-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.invocation.InitialInterceptor.processInvocation(InitialInterceptor.java:21) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.invocation.ChainedInterceptor.processInvocation(ChainedInterceptor.java:61) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ee.component.interceptors.ComponentDispatcherInterceptor.processInvocation(ComponentDispatcherInterceptor.java:53) [jboss-as-ee-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.component.pool.PooledInstanceInterceptor.processInvocation(PooledInstanceInterceptor.java:51) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.tx.CMTTxInterceptor.invokeInOurTx(CMTTxInterceptor.java:226) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.as.ejb3.tx.CMTTxInterceptor.required(CMTTxInterceptor.java:302) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.as.ejb3.tx.CMTTxInterceptor.processInvocation(CMTTxInterceptor.java:188) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.component.interceptors.CurrentInvocationContextInterceptor.processInvocation(CurrentInvocationContextInterceptor.java:41) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.security.SecurityContextInterceptor.processInvocation(SecurityContextInterceptor.java:76) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.component.interceptors.ShutDownInterceptorFactory$1.processInvocation(ShutDownInterceptorFactory.java:42) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.component.interceptors.LoggingInterceptor.processInvocation(LoggingInterceptor.java:59) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ee.component.NamespaceContextInterceptor.processInvocation(NamespaceContextInterceptor.java:50) [jboss-as-ee-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.component.interceptors.AdditionalSetupInterceptor.processInvocation(AdditionalSetupInterceptor.java:43) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ee.component.TCCLInterceptor.processInvocation(TCCLInterceptor.java:45) [jboss-as-ee-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.invocation.ChainedInterceptor.processInvocation(ChainedInterceptor.java:61) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ee.component.ViewService$View.invoke(ViewService.java:165) [jboss-as-ee-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.as.ee.component.ViewDescription$1.processInvocation(ViewDescription.java:181) [jboss-as-ee-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ejb3.component.interceptors.AsyncFutureInterceptorFactory$1$1.runInvocation(AsyncFutureInterceptorFactory.java:77) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at org.jboss.as.ejb3.component.interceptors.AsyncInvocationTask.run(AsyncInvocationTask.java:73) [jboss-as-ejb3-7.1.3.Final.jar:7.1.3.Final]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_45]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_45]
at java.lang.Thread.run(Thread.java:744) [rt.jar:1.7.0_45]
at org.jboss.threads.JBossThread.run(JBossThread.java:122)
WSDL本地与远程
来自相同界面的本地生成的WSDL与Sharepoint提供的WSDL大不相同。
本地
<?xml version='1.0' encoding='UTF-8'?><wsdl:definitions name="Documents" targetNamespace="http://FooService.SharePoint.API.Webservices.Documents" xmlns:ns1="http://FooService.SharePoint.API.Webservices.Documents/" xmlns:ns2="http://schemas.xmlsoap.org/soap/http" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="http://FooService.SharePoint.API.Webservices.Documents" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<wsdl:import location="http://localhost:8080/TheProductTestSuite/Documents/Documents?wsdl=DocumentsSoap.wsdl" namespace="http://FooService.SharePoint.API.Webservices.Documents/">
</wsdl:import>
<wsdl:binding name="DocumentsSoapBinding" type="ns1:DocumentsSoap">
<soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
<wsdl:operation name="AddLinkedFile">
<soap:operation soapAction="http://FooService.SharePoint.API.Webservices.Documents/AddLinkedFile" style="document"/>
<wsdl:input name="AddLinkedFile">
<soap:body use="literal"/>
</wsdl:input>
<wsdl:output name="AddLinkedFileResponse">
<soap:body use="literal"/>
</wsdl:output>
</wsdl:operation>
<wsdl:operation name="UploadDocumentBySearchPath">
<soap:operation soapAction="http://FooService.SharePoint.API.Webservices.Documents/UploadDocumentBySearchPath" style="document"/>
<wsdl:input name="UploadDocumentBySearchPath">
<soap:body use="literal"/>
</wsdl:input>
<wsdl:output name="UploadDocumentBySearchPathResponse">
<soap:body use="literal"/>
</wsdl:output>
</wsdl:operation> ...
调用工厂加载的原始WSDL如下所示:
<wsdl:definitions xmlns:s="http://www.w3.org/2001/XMLSchema" xmlns:tns="http://FooService.SharePoint.API.Webservices.Documents/" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:s1="http://microsoft.com/wsdl/types/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" targetNamespace="http://FooService.SharePoint.API.Webservices.Documents/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
<wsdl:types>
<s:schema elementFormDefault="qualified" targetNamespace="http://FooService.SharePoint.API.Webservices.Documents/">
<s:import namespace="http://microsoft.com/wsdl/types/" />
<s:element name="GetDocumentInformationByURL">
<s:complexType>
<s:sequence>
<s:element minOccurs="0" maxOccurs="1" name="documentURL" type="s:string" />
</s:sequence>
</s:complexType>
</s:element>
<s:element name="GetDocumentInformationByURLResponse">
<s:complexType>
<s:sequence>
<s:element minOccurs="0" maxOccurs="1" name="GetDocumentInformationByURLResult" type="tns:DocumentInfo" />
</s:sequence>
</s:complexType>
</s:element>
<s:complexType name="DocumentInfo">
<s:sequence>
<s:element minOccurs="0" maxOccurs="1" name="VersionLabel" type="s:string" />
<s:element minOccurs="1" maxOccurs="1" name="IsConvertedFile" type="s:boolean" />
<s:element minOccurs="1" maxOccurs="1" name="TotalLength" type="s:long" />
<s:element minOccurs="0" maxOccurs="1" name="URL" type="s:string" />
<s:element minOccurs="1" maxOccurs="1" name="UniqueID" type="s1:guid" />
<s:element minOccurs="1" maxOccurs="1" name="ListItemID" type="s:int" />
<s:element minOccurs="1" maxOccurs="1" name="ListID" type="s1:guid" />
<s:element minOccurs="0" maxOccurs="1" name="FilePath" type="s:string" />
<s:element minOccurs="0" maxOccurs="1" name="DependentFiles" type="tns:ArrayOfDependentFile" />
<s:element minOccurs="0" maxOccurs="1" name="Content" type="tns:Content" />
<s:element minOccurs="1" maxOccurs="1" name="IsLinked" type="s:boolean" />
<s:element minOccurs="1" maxOccurs="1" name="IsArchived" type="s:boolean" />
<s:element minOccurs="1" maxOccurs="1" name="CheckedOutState" type="tns:SPCheckOutStatus" />
</s:sequence>
</s:complexType>
....
大问题
由于我是从Sharepoint WSDL生成DMS API jar的,那么实现该API的EJB服务如何与原始API大不相同,它不能被接受为替代品?
我错过了关键点吗?或者它只是一个生成问题 - 意味着:携带webservice信息的java客户端API永远不会产生与先前规范匹配的EJB Web服务?
提前致谢!
答案 0 :(得分:0)
您正在使用的Java EE的实现与Sharepoint的WSDL生成实现不同。 SOAP框架的不同之处是不同,因为WSDL生成没有单一的标准。只有WSDL语言是标准化的。版本也有所不同。如果您愿意,可以将WSDL文件放在应用程序的WEB-INF / wsdl目录中,然后在EJB中使用@WebService(wsdlLocation="yourwsdl.wsdl")
之类的内容。