哇!它还活着!它的工作!
仍然无法在调试(security exception),但我会一直活到下一个版本。
这里是一个工作的配置:
<system.serviceModel>
<bindings>
<basicHttpBinding>
<binding name="SecureBasicHttpBinding">
<security mode="Transport">
<transport clientCredentialType="None" />
</security>
</binding>
</basicHttpBinding>
</bindings>
<behaviors>
<serviceBehaviors>
<behavior name="Silverheat.Cloud_WebRole.API.DataServiceBehavior">
<serviceMetadata httpGetEnabled="true" httpsGetEnabled="true" />
<serviceDebug includeExceptionDetailInFaults="true" />
</behavior>
</serviceBehaviors>
</behaviors>
<serviceHostingEnvironment aspNetCompatibilityEnabled="true" />
<services>
<service behaviorConfiguration="Silverheat.Cloud_WebRole.API.DataServiceBehavior"
name="Silverheat.Cloud_WebRole.API.DataService">
<endpoint bindingConfiguration="SecureBasicHttpBinding"
address="" binding="basicHttpBinding"
contract="Silverheat.Cloud_WebRole.API.DataService" />
<endpoint address="mex" binding="mexHttpsBinding" contract="IMetadataExchange" />
</service>
</services>
</system.serviceModel>
(我认为这是“mexHttpsBinding”,使得它最终的工作,虽然我并不完全明白为什么它已经配置后需要元数据,回我猜想的书)
我仍然想知道如何为WCF启用某种日志记录,但是我会在这个伟大的站点上多找一点,我相信我会找到答案。