日期:2014-05-17  浏览次数:20872 次

WCF双工部署到IIS中的虚拟目录就访问不了?
部署到IIS根目录可以正常访问WCF 双工,放到站点的虚拟目录就访问不了?

配置文件:
<?xml version="1.0" encoding="utf-8"?>

<!--
  有关如何配置 ASP.NET 应用程序的详细消息,请访问
  http://go.microsoft.com/fwlink/?LinkId=169433
  -->

<configuration>
  <system.web>
    <compilation debug="true" targetFramework="4.0" />
  </system.web>

  <system.serviceModel>
    <bindings>
      <netTcpBinding>
        <binding name="netTcpBindConfig"  closeTimeout="00:30:00" portSharingEnabled="true"
                openTimeout="00:30:00" receiveTimeout="00:30:00" sendTimeout="00:30:00"
                transactionFlow="false" transferMode="Buffered" transactionProtocol="OleTransactions"
                hostNameComparisonMode="StrongWildcard" listenBacklog="10">

          <readerQuotas maxDepth="2147483647"
                                    maxStringContentLength="2147483647"
                                    maxArrayLength="2147483647"
                                    maxBytesPerRead="2147483647"
                                    maxNameTableCharCount="2147483647" />
          <reliableSession ordered="true"  inactivityTimeout="00:01:00" enabled="false" />
          <security mode="None">
            <transport clientCredentialType="Windows" protectionLevel="EncryptAndSign"  />
            <message clientCredentialType="Windows"  />
          </security>
        </binding>
      </netTcpBinding>
    </bindings>
    <services>
      <service behaviorConfiguration="CommonService" name="WcfDoubleTest.CalculatorService">
        <endpoint binding="netTcpBinding" contract="WcfDoubleTest.ICalculator" bindingConfiguration="netTcpBindConfig"/>
        <endpoint address="mex" binding="mexTcpBinding" contract="IMetadataExchange" />
&nbs