WCF分布式開發常見錯誤解決(5)Could not find a base address that matches scheme
WCF分布式應用開發,托管宿主配置終結點錯誤:找不到匹配式樣http的基地址,
Could not find a base address that matches scheme http for the endpoint with binding MetadataExchangeHttpBinding. Registered base address schemes are [].
如圖:
解決辦法:打開托管宿主配置文件,添加基地址節點,與配置文件裡終結點地址一致 即可。
<host>
<baseAddresses>
<add baseAddress="http://localhost:8001/"/>
<add baseAddress="net.tcp://localhost:8002/"/>
</baseAddresses>
< /host>