WCF adding a service reference ,error Metadata contains a reference that cannot be resolved
Posted on 2014-02-07
Metadata contains a reference that cannot be resolved: 'net.tcp://server:port/DataService'.
I am trying to add a service reference to my console application, to an exitsing WCF service.
I get the following error
Metadata contains a reference that cannot be resolved: 'net.tcp://server:port/DataService'
The socket connection was aborted. This could be caused by an error processing your message or a receive timeout being exceeded by the remote host, or an underlying network resource issue. Local socket timeout was '00:04:59.5163969'.
An existing connection was forcibly closed by the remote host
If the service is defined in the current solution, try building the solution and adding the service reference again.
The server configuration is
<service name="DataService" behaviorConfiguration="DataServiceBehavior">
<endpoint address="net.tcp://server:port/DataService" binding="netTcpBinding" bindingConfiguration="XYZNetTcp" behaviorConfiguration="XYZConfig" name="NetTcpBindingEndpoint" contract="IDataService">
<endpoint address="mex" binding="mexTcpBinding" contract="IMetadataExchange" bindingConfiguration="" name="MexTcpBindingEndpoint" />
<add baseAddress="net.tcp://server:port/DataService" />