WCF virker kun på localhost
Jeg har en wcf duplex service, som jeg pt har brugt på localhost. Når jeg forsøger at bruge servicen over netværket får jeg en fejl.Jeg har testet at der er hul igennem på porten.
Nogen bud?
FEJL:
The requested upgrade is not supported by 'net.tcp://1.2.3.4:8080/SortingJobService'. This could be due to mismatched bindings (for example security enabled on the client and not on the server).
KLIENTEN:
var netTcpBinding = new NetTcpBinding();
//netTcpBinding.Security.Mode = SecurityMode.None;
var duplexChannelFactory =
new DuplexChannelFactory<ISortingJobService>(
sortingJobEventCallback,
netTcpBinding,
new EndpointAddress("net.tcp://1.2.3.4:8080/SortingJobService"));
SortingJobService = duplexChannelFactory.CreateChannel();
SERVICEN:
var netTcpBinding = new NetTcpBinding();
//netTcpBinding.Security.Mode = SecurityMode.None;
_duplex = new ServiceHost(typeof(SortingJobService));
_duplex.AddServiceEndpoint(typeof(ISortingJobService),
netTcpBinding,
"net.tcp://1.2.3.4:8080/SortingJobService");
_duplex.Open();