【发布时间】:2011-01-13 05:42:45
【问题描述】:
快速总结:
Taleo 有一个单一的操作“Dispatcher WSDL”,它应该返回一个 URL 以供其 WebAPI WSDL 使用……目的是允许 URL 用于所有意图和目的的软编码。
对于getURL操作, WcfTestClient.exe XML 视图显示在 SOAP 信封中返回了一个 URL。
但是,WcfTestClient.exe 格式的视图显示
名称:(返回)值:(null)类型:NullObject
我的 c# vs2010 .NET 4 代码; taleoURL 始终为空
DispatcherAPIClient dispatcherClient = new DispatcherAPIClient("rpcrouter");
string taleoOrgCode = "TALEOSK";
string taleoURL = dispatcherClient.getURL(taleoOrgCode);
if (taleoURL == null) Console.WriteLine("null returned for " + taleoOrgCode);
这个空值很奇怪,因为这是来自 WcfTestClient.exe 的 XML 响应:
<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<s:Header xmlns:s="http://schemas.xmlsoap.org/soap/envelope/" />
<SOAP-ENV:Body>
<ns1:getURLResponse xmlns:ns1="urn:TBEDispatcherAPI" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<return xsi:type="xsd:string">https://tbe.taleo.net/NA12/ats/services/rpcrouter</return>
</ns1:getURLResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
https://tbe.taleo.net/NA12/ats/services/rpcrouter 是 值 return> 元素。
为了能够使用上面的链接,显然我需要 taleoURL 不为空。
Taleo API 指南的第 154-155 页说
getURL 定义为字符串 getURL(string orgCode)
http://tbe.taleo.net/products/TBE_API_Guide.pdf from
http://www.taleo.com/solutions/taleo-business-edition-web-integration-api
还有
http://tbe.taleo.net/wsdl/DispatcherAPI.wsdl
http://tbe.taleo.net/wsdl/WebAPI.wsdl
这是 DispatcherAPI.wsdl 的请求/响应部分:
<wsdl:message name="getURLRequest">
<wsdl:part name="orgCode" type="xsd:string" />
</wsdl:message>
<wsdl:message name="getURLResponse">
<wsdl:part name="getURLReturn" type="xsd:string" />
</wsdl:message>
我最好的猜测是我错过了一些东西。
这是我自己的无知不是幸福的情况。
MSDN 和谷歌没有帮助。
谢谢你...格里
【问题讨论】:
标签: c# wcf visual-studio-2010 .net-4.0 soap-client