Aufruf von WCF-webservice service

Ich habe ein Problem das konsumieren eines webservice - (c#.net), die von einem WCF service.
Die Fehler ich erhalte, ist EndPointNotFoundException "TCP-Fehlercode 10061: es konnte Keine Verbindung hergestellt werden, da der Zielcomputer aktiv verweigert"

Schrieb ich einen unit-test zu überprüfen, wenn ich könnte senden Sie eine Anfrage an den web service und es hat funktioniert
[Der unit-test nutzt die gleiche Bindung-Konfiguration wie mein WCF-Dienst]

Webservices und WCF-Dienst (- client) haben basichttp-binding.

Hatte jemand schon ähnliche Art von Problem Aufruf eines webservice, die von einem WCF-Dienst?

Service-Modell-Abschnitt ist wie folgt

<system.serviceModel>
    <bindings>
        <basicHttpBinding>
            <binding name="DataService" closeTimeout="00:05:00" openTimeout="00:05:00" receiveTimeout="00:10:00" sendTimeout="00:05:00" allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard" maxBufferSize="65536" maxBufferPoolSize="524288" maxReceivedMessageSize="65536" messageEncoding="Text" textEncoding="utf-8" transferMode="Buffered" useDefaultWebProxy="true">
                <readerQuotas maxDepth="32" maxStringContentLength="8192" maxArrayLength="16384" maxBytesPerRead="4096" maxNameTableCharCount="16384"/>
                <security mode="None">
                    <transport clientCredentialType="None" proxyCredentialType="None" realm=""/>
                    <message clientCredentialType="UserName" algorithmSuite="Default"/>
                </security>
            </binding>
        </basicHttpBinding>
    </bindings>
    <client>
        <endpoint address="http://10.22.33.67/Service/DataService.asmx" binding="basicHttpBinding" 
            bindingConfiguration="DataService" contract="Service.DataService" name="DataService"/>
    </client>
    <services>
        <service name="TestToConsumeDataService.WCFHost.Service1" behaviorConfiguration="TestToConsumeDataService.WCFHost.Service1Behavior">
            <!-- Service Endpoints -->
            <endpoint address="" binding="basicHttpBinding" contract="TestToConsumeDataService.WCFHost.IService1">
                <!-- 
          Upon deployment, the following identity element should be removed or replaced to reflect the 
          identity under which the deployed service runs.  If removed, WCF will infer an appropriate identity 
          automatically.
      -->
                <identity>
                    <dns value="localhost"/>
                </identity>
            </endpoint>
            <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange"/>
        </service>
    </services>
    <behaviors>
        <serviceBehaviors>
            <behavior name="TestToConsumeDataService.WCFHost.Service1Behavior">
                <!-- To avoid disclosing metadata information, set the value below to false and remove the metadata endpoint above before deployment -->
                <serviceMetadata httpGetEnabled="true"/>
                <!-- To receive exception details in faults for debugging purposes, set the value below to true.  Set to false before deployment to avoid disclosing exception information -->
                <serviceDebug includeExceptionDetailInFaults="false"/>
            </behavior>
        </serviceBehaviors>
    </behaviors>
</system.serviceModel>

Den unit-test-Projekt ist auch mit dem gleichen service-Modell " und es funktioniert. Das einzige Problem ist beim Aufruf der service von einem anderen WCF-Dienst. Könnten Sie bitte vorschlagen.

InformationsquelleAutor Balaji | 2009-10-01
Schreibe einen Kommentar