我有一個WCF Web服務與暴露3個端點。 但是,當我將它調試到WCF測試客戶端時,它僅顯示一個basicHttpBinding端點。WCF測試客戶端顯示1端點,而配置文件顯示3端點
1:爲什麼這樣?
2:在這裏,我有一個經營合同「CallADSWebMethod」它返回一個DataContract(VINDescription)..只是好奇,想知道.. 爲什麼這對我的作品很大實時但仍通過測試客戶端是不可檢驗 ..我的意思是測試客戶端說:「此操作不支持測試客戶端」
3:在這裏在endpointBehaviors-我只給與沒有...但仍然是從jQuery的ajax調用.. 那麼「enableWebScript」的意義是什麼?
配置信息
<system.serviceModel>
<services>
<service behaviorConfiguration="asmx" name="ADSChromeVINDecoder.Service">
<endpoint address="basic"
binding="basicHttpBinding"
name="httpEndPoint"
contract="ADSChromeVINDecoder.IService"/>
<endpoint address="json"
binding="webHttpBinding"
behaviorConfiguration="webBehavior"
name="webEndPoint"
contract="ADSChromeVINDecoder.IService"/>
<endpoint contract="IMetadataExchange"
binding="mexHttpBinding"
address="mex" />
</service>
</services>
<behaviors>
<endpointBehaviors>
<behavior name="webBehavior">
<webHttp/>
</behavior>
</endpointBehaviors>
<serviceBehaviors>
<behavior name="asmx">
<serviceMetadata httpGetEnabled="true"/>
<serviceDebug includeExceptionDetailInFaults="true"/>
</behavior>
</serviceBehaviors>
</behaviors>
<serviceHostingEnvironment multipleSiteBindingsEnabled="true"/>
</system.serviceModel>
在同一個操作契約「CallADSWebMethod」,它返回一個DataContract(VINDescription)..只是好奇知道..爲什麼這個工程對我來說很實時,但它仍然是不被測試客戶端測試的..我的意思是測試客戶端說「測試客戶端不支持此操作」 – James
@Learner:WCF測試客戶端相當有限,其中一個限制是它無法處理您自己的自定義數據類型作爲參數。你基本上只能用類型爲「int」,「string」,「datetime」等參數的簡單數據類型來測試方法。 –
好的。因此可能是WCF測試客戶端的新版本將與此一起。 – James