我已经通过在web.config中指定WebGET和WebHttpBinding在C#中创建了REST WCF。该服务通过IE工作正常。我的wsdl从下面开始,它在wsdl中有soap。由于这是REST,因此不应该在wsdl中存在肥皂。WSDL for REST WCF
WSDL:
<?xml version="1.0" encoding="utf-8" ?>
<wsdl:definitions name="ServiceImp" targetNamespace="http://tempuri.org/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:wsam="http://www.w3.org/2007/05/addressing/metadata"
xmlns:tns="http://tempuri.org/"
xmlns:wsa="http://schemas.xmlsoap.org/ws/2004/08/addressing"
xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"
xmlns:wsap="http://schemas.xmlsoap.org/ws/2004/08/addressing/policy"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:msc="http://schemas.microsoft.com/ws/2005/12/wsdl/contract"
xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl"
xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/"
xmlns:wsa10="http://www.w3.org/2005/08/addressing"
xmlns:wsx="http://schemas.xmlsoap.org/ws/2004/09/mex">
在上面的WSDL,因为这是HTTP,为什么皂含量在REST服务来吗?
感谢, Vinoth Khanna.S
REST不**具有** WSDL .....不完全确定**什么**您'再看看这里......另外:REST服务没有任何** SOAP **内容..... – 2011-05-17 12:28:52
你还没有发布你的整个WSDL ... – 2011-05-17 12:29:23
是的,我没有发布我的整个wsdl。那么当我给我的wsdl服务后显示wsdl时,它是怎么样的? – 2011-05-17 12:30:54