English 中文(简体)
通过冷聚问题实现出售品编号:E.05.II.A.1。
原标题:Consuming Salesforce WSDL via Coldfusion Issue

该公司的另一组开发商向Ive提供了一份分类文件,这些开发商在一个单独的案例中开展工作,产生一个基于WSDL的SOAP。 我已经进口了这一类档案,并且以我们为例产生了WSDL。 网络服务非常基本,它只是回归一套价值(当然是XML),不需要任何理由来收回这些价值。

仅测试妇女发展论坛正在工作,Ive从我们的手脚下载到我的当地人民民主力量,将其带入社会倡议,并成功地归还了一套价值观。

NOW ONTO THE ISSUE - CONSUMING VIA THE URL

采用冷聚式聚氯乙烯,因此我有两条CFHTTP电话,第一个电话是用我们这个案例的标识,该记录是一次有效的会议。 The session ID is used in my second calls which is below:

<!--- token from from first cfhttp --->
<cfset variables.access_token_node = xmlSearch(XMLContent, "//*[name()= sessionId ]") />
<cfset variables.access_token = variables.access_token_node[1].xmlText>

<cfset variables.wsdl_url2 = "https://cs12.salesforce.com/services/wsdl/class/WS_FAKE_WSDL">

<cfset packet = CreateObject("java", "java.lang.StringBuffer") />
<cfset packet.append( <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ws="http://soap.sforce.com/schemas/class/WS_FAKE_WSDL"> ) />
<cfset packet.append( <soapenv:Header> ) />
<cfset packet.append( <ws:SessionHeader> ) />
<cfset packet.append( <ws:sessionId>#variables.access_token#</ws:sessionId> ) />
<cfset packet.append( </ws:SessionHeader> ) />
<cfset packet.append( </soapenv:Header> ) />
<cfset packet.append( <soapenv:Body> ) />
<cfset packet.append( <ws:DescribesObjectFields/> ) />
<cfset packet.append( </soapenv:Body> ) />
<cfset packet.append( </soapenv:Envelope> ) />

<cfhttp method="post" url="#variables.wsdl_url2#" result="findResponse2">
 <cfhttpparam type="HEADER" name="Accept" value="application/soap+xml, application/xml, multipart/related, text/*">
 <cfhttpparam type="HEADER" name="ACCEPT-ENCODING" value="application/soap+xml">
 <cfhttpparam type="HEADER" name="CONNECTION" value="Keep-Alive">
 <cfhttpparam type="HEADER" name="SOAPAction" value="dummy">
 <cfhttpparam type="HEADER" name="Content-Type" value="text/xml; charset=utf-8">
 <cfhttpparam type="HEADER" name="Must-Understand" value="1">
 <cfhttpparam type="Header" name="Content-Length" value="#len(trim(packet.ToString()))#">
 <cfhttpparam type="body" value="#packet.ToString()#" encoded="yes">
</cfhttp>

Below is what I am receiving from the WSDL..that code just takes me back to the login screen. With a Session ID I would assume I wouldn t need to log back in, correct?

“entergraph

感谢所有建议。

最佳回答

你似乎向SDL案的URL发出过你的要求,这不是正确的URL,你应当将其寄给WSDL档案中详细列出的服务地址,见WSDL底部的<代码>Sap:address要素。

问题回答

暂无回答




相关问题
IIS 6.0 hangs when serving a web-service

I am having issues with one of our web-services. It works fine on my development machine (win XP) whether I host it as a separate application or using cassini from Visual studio. Once I deploy on the ...

ASP.net web services

I am using a web service which sets the Thread.CurrentPrincipal object while logging in and soon later when another webmethod of the same web service accesses Thread.CurrentPrincipal, its different/...

Unity Container Disposing and XML Web Service

I am registering some wrapers over un-managed objects in container. How can I dispose of them at the end of the container s lifetime? Please bear in mind I have an XML Web service.

SharePoint : web service permission error

I have a sharepoint site, and I am calling a standard sharepoint web service. I create the web service request like this : wsDws.Url = this.SiteAddress + @"/_vti_bin/Dws.asmx"; When I use ...

热门标签