开发者

Can we use WCF Discovery to discover services outside your local network?

Is it possible to use WCF disco开发者_如何学Govery to access services that reside outside your local network ?


The short answer is no.

Discovery uses a UDP broadcast packet. You can discover anything that your UDP broadcast packet is allowed to reach. There is the catch, most routers, firewalls, and commercial switches block udp broadcast packets. You may be able to change the settings on your router where you connect to the next larger network (or internet), and you 'might' extend your discovery slightly. Again though, the very next switch or router you hit will most likely be set to block udp.

In this situation, most people design a "report in" server. This is one static place to which all other hosts and clients and pre-programmed to "report in" on startup. This one server keeps a table of where all hosts and clients are, and if one client wants to find a certain host, it asks this main server for the uri of the host its looking for.

EDIT: Robin mentioned increasing the TTL (Time To Live) from the default of 1 to a higher number. Maybe this will help someone. https://serverfault.com/a/619825/146341

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜