App.config 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. <?xml version="1.0" encoding="utf-8" ?>
  2. <configuration>
  3. <appSettings>
  4. <add key="aspnet:UseTaskFriendlySynchronizationContext" value="true" />
  5. </appSettings>
  6. <system.web>
  7. <compilation debug="true" />
  8. </system.web>
  9. <!-- 部署服务库项目时,必须将配置文件的内容添加到主机的 app.config 文件中。System.Configuration 不支持库的配置文件。-->
  10. <system.serviceModel>
  11. <services>
  12. <service name="Realm.ICalculator">
  13. <endpoint address="" binding="basicHttpBinding" contract="Realm.IService1">
  14. <identity>
  15. <dns value="localhost" />
  16. </identity>
  17. </endpoint>
  18. <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" />
  19. <host>
  20. <baseAddresses>
  21. <add baseAddress="http://localhost:8733/Design_Time_Addresses/Realm/Calculator/" />
  22. </baseAddresses>
  23. </host>
  24. </service>
  25. </services>
  26. <behaviors>
  27. <serviceBehaviors>
  28. <behavior>
  29. <!-- 为避免泄漏元数据信息,请在部署前将以下值设置为 false -->
  30. <serviceMetadata httpGetEnabled="True" httpsGetEnabled="True"/>
  31. <!-- 要接收故障异常详细信息以进行调试,请将以下值设置为true。在部署前设置为false以避免泄漏异常信息-->
  32. <serviceDebug includeExceptionDetailInFaults="False" />
  33. </behavior>
  34. </serviceBehaviors>
  35. </behaviors>
  36. </system.serviceModel>
  37. </configuration>