我正在使用第三方WCF服务,并且其配置如下(的一部分为)。我想将serviceBehaviors
分配给端点,但此处没有<service>
标记。在这种情况下,你如何分配'serviceBehaviors'?WCF - 如何将serviceBehaviors附加到WCF端点(没有<service>标签)
<client>
<endpoint address="https://something/someservice.asmx" binding="customBinding" bindingConfiguration="ABCBinding" contract="Democlient.Soap" name="Soap" behaviorConfiguration="SoapEndpointB" />
</client>
<behaviors>
<endpointBehaviors>
<behavior name="SoapEndpointB">
<dataContractSerializer maxItemsInObjectGraph="2147483647"/>
</behavior>
</endpointBehaviors>
<serviceBehaviors>
<behavior name="SoapServiceB">
<dataContractSerializer maxItemsInObjectGraph="2147483647" />
<serviceMetadata httpsGetEnabled="true" />
<serviceDebug includeExceptionDetailInFaults="true" />
</behavior>
</serviceBehaviors>
</behaviors>