Could not find a base address that matches scheme http for the endpoint with binding MetadataExchangeHttpBinding.

Could not find a base address that matches scheme http for the endpoint with binding MetadataExchangeHttpBinding. Registered base address schemes are [https].


 

The base address for your service defines "HTTPS://" - but your mex address is "HTTP".

If you want your service to use https://, you'll need to use the mexHttpsBinding as well:

 

<services>
      <service name="MyWCFService"
                behaviorConfiguration="mexServiceBehavior">
        <host>
          <baseAddresses>
            <add baseAddress="https://localhost:9090/MyService"/>
          </baseAddresses>
        </host>
        <endpoint address="" binding="wsHttpBinding" bindingConfiguration="MyBinding" contract="IMyService"/>
        <endpoint address="mex" binding="mexHttpsBinding" contract="IMetadataExchange" />
      </service>
</services>
 

posted @ 2011-04-19 12:43  sayo.net  阅读(1451)  评论(0编辑  收藏  举报