title: WCF help, how can I expose a service over http, that calls another service over net.tcp?
body: <p>I have a WCF .svc file hosted in IIS. I want to use basicHTTP binding. This services job is to actually call another service over net.tcp. Everything works fine locally, but when I deployed, I'm getting this error.</p>
  
  <blockquote>
    <p>The provided URI scheme 'http' is
    invalid; expected 'net.tcp'. Parameter
    name: via</p>
  </blockquote>
  
  <p>Here is the server config</p>
  
  <pre><code>&lt;client&gt;
    &lt;endpoint address="net.tcp://localhost:9300/InternalInterfaceService"
        binding="netTcpBinding" bindingConfiguration="NetTcpBinding_IInternalInterfaceService"
        contract="IInternalInterfaceService" name="NetTcpBinding_IInternalInterfaceService"&gt;
      &lt;identity&gt;
        &lt;servicePrincipalName value="localhost" /&gt;
      &lt;/identity&gt;
    &lt;/endpoint&gt;
  &lt;/client&gt;
  &lt;services&gt;
  &lt;service name="MyExternalService"&gt;
  &lt;endpoint address="" binding="basicHttpBinding" contract="IMyExternalService" /&gt;
  &lt;/service&gt;
  &lt;/services&gt;
  </code></pre>
  
  <p>And here is the config that svcutil generates</p>
  
  <pre><code>&lt;system.serviceModel&gt;
      &lt;bindings&gt;
          &lt;basicHttpBinding&gt;
              &lt;binding name="BasicHttpBinding_IMyExternalService" closeTimeout="00:01:00"
                  openTimeout="00:01:00" receiveTimeout="00:10:00" sendTimeout="00:01:00"
                  allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard"
                  maxBufferSize="65536" maxBufferPoolSize="524288" maxReceivedMessageSize="65536"
                  messageEncoding="Text" textEncoding="utf-8" transferMode="Buffered"
                  useDefaultWebProxy="true"&gt;
                  &lt;readerQuotas maxDepth="32" maxStringContentLength="8192" maxArrayLength="16384"
                      maxBytesPerRead="4096" maxNameTableCharCount="16384" /&gt;
                  &lt;security mode="None"&gt;
                      &lt;transport clientCredentialType="None" proxyCredentialType="None"
                          realm="" /&gt;
                      &lt;message clientCredentialType="UserName" algorithmSuite="Default" /&gt;
                  &lt;/security&gt;
              &lt;/binding&gt;
          &lt;/basicHttpBinding&gt;
      &lt;/bindings&gt;
      &lt;client&gt;
          &lt;endpoint address="http://myserver.somesdomain.com/Services/MyExternalService.svc"
              binding="basicHttpBinding" bindingConfiguration="BasicHttpBinding_IMyExternalService"
              contract="IMyInternalService" name="BasicHttpBinding_IMyExternalService" /&gt;
      &lt;/client&gt;
  &lt;/system.serviceModel&gt;
  </code></pre>
  
  <p>What do I need to do to wire this up correctly. I do not want to expose InternalInterfaceService over http. What am I doing incorrectly here? Any tips or suggestions are certainly appreciated.</p>
  
  <p>Thanks,<br>
  ~ck</p>