zoukankan      html  css  js  c++  java
  • VS2010 SL4解决方案前端发现不了解决方案中WCF服务问题

    在VS2010 SL4项目解决方案中,前端添加服务引用,点击“发现”无法找到解决方案中的服务。启动中间层WCF服务报错(基地址错误)

    发现问题在于中间层WCF项目的App.Config部分配置不正确引起的(很难查):

    1、下面的<serviceMetadata httpsGetEnabled="true"/>应修改为<serviceMetadata httpGetEnabled="true"/>

        <behaviors>
    <endpointBehaviors>
    <behavior name="WebBehavior">
    <webHttp/>
    </behavior>
    </endpointBehaviors>
    <serviceBehaviors>
    <behavior name="ServerBehavior">
    <serviceMetadata httpsGetEnabled="true"/>
    <serviceDebug includeExceptionDetailInFaults="true"/>
    </behavior>
    </serviceBehaviors>
    </behaviors>

    2、下面的<security mode="Transport"> <transport clientCredentialType="None"/> </security>应删除,因为不是部署在HTTPS网站上所以不要这个安全设置。

        <bindings>
    <basicHttpBinding>
    <binding name="BlobConfig" maxBufferSize="2147483646" maxBufferPoolSize="2147483646" maxReceivedMessageSize="2147483646">
    <readerQuotas maxDepth="32" maxStringContentLength="52428800" maxArrayLength="52428800" maxBytesPerRead="52428800" maxNameTableCharCount="16384"/>
    <security mode="Transport">
    <transport clientCredentialType="None"/>
    </security>
    </binding>
    </basicHttpBinding>
    </bindings>

    修改完上述地方就能发现到相应的服务,且启动中间层服务不会再报基地址错了。

  • 相关阅读:
    C++出现 error: no match for 'operator==' (operand types are 'Person' and 'const Person')
    python三元运算符公式/出错怎么看
    我学函数遗漏的东西
    学习函数时一些没注意到的地方
    Python文件操作回顾
    我学习python没有记住的东西
    转载
    UE SC -kismetmathlibrary
    LineTrace跟Overlap开销
    UE4 插件无法读取常见错误
  • 原文地址:https://www.cnblogs.com/chriskwok/p/2230074.html
Copyright © 2011-2022 走看看