I have a WCF Service hosted on Windows Azure and I just recently changed it’s contract to be a Duplex contract (to support a progress bar on the client). I first used the wsDualHttpBinding which worked well on my local machine, but as expected failed to work once I deployed it.
I am now trying to configure the service to work with netTcpBinding, but I’m getting the error “The protocol specified is not valid. The protocol ‘tcp’ for the binding named ‘Endpoint1’ is currently not supported.”.
ServiceDefinition.csdef :
<Endpoints>
<InputEndpoint name="AlertsEndpoint" protocol="tcp" port="3030" />
</Endpoints>
Web.config:
<services>
<service name="AlertsService.AlertsService" behaviorConfiguration="AlertsServiceBehavior">
<endpoint address="" binding="netTcpBinding" bindingConfiguration="NetTcp" contract="AlertsService.IAlertsService" />
<endpoint address="mex" binding="mexTcpBinding" bindingConfiguration="MexTcp" contract="IMetadataExchange" />
</service>
</services>
<bindings>
<netTcpBinding>
<binding name="NetTcp" />
</netTcpBinding>
<mexTcpBinding>
<binding name="MexTcp"/>
</mexTcpBinding>
</bindings>
Web Roleshosting WCF services doesn’t support the TCP protocol.You will need to host your WCF service in a
Worker Role.Web Roles:
Worker Roles: