Consuming WCF Service in other Computer RRS feed

  • Question

  • I have created a simple wcf service with netTcp binding.I have to consume that service in other computer .Is that Possible ?If yes how it could be? 
    Friday, January 31, 2020 12:06 PM

All replies

  • Hi,
    Nettcpbinding supports natively supports intranet network. As long as the network between the server and the client is unblocked, the client can consume the service properly.
    We usually consume the WCF service by using a client proxy, it is also applicable for the WCF service created by Nettcpbinding.
    Mex service endpoint can be searched by the menu of adding service reference, therefore, it is necessary to add this kind of service endpoint on the server-side.
    Binding mexbinding = MetadataExchangeBindings.CreateMexTcpBinding();
                    sh.AddServiceEndpoint(typeof(IMetadataExchange), mexbinding, "mex");

              <serviceMetadata httpGetEnabled="true" httpsGetEnabled="true" />

    Feel free to let me know if the problem still exists.
    Best Regards
    Monday, February 3, 2020 6:21 AM