【发布时间】:2010-03-02 01:12:46
【问题描述】:
我有一个 WCF 服务,每个服务都有 REST 和 SOAP 端点。这与这篇文章的实现类似:REST / SOAP endpoints for a WCF service,配置类似于以下:
<services>
<service name="TestService">
<endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange"/>
<endpoint address="soap" binding="basicHttpBinding" contract="ITestService"/>
<endpoint address="rest" binding="webHttpBinding" contract="ITestService"/>
</service>
</services>
问题在于 REST 端点在生成的 WSDL 中显示为附加端口和绑定。
有什么方法可以防止 REST 端点被包含在 WSDL 中?
【问题讨论】: