views:

109

answers:

1

I'm just beginning WCF and so I don't understand exactly how the abstraction works. Can I write a WCF service and install the same thing on multiple machines, and have them communicate via some ID? I'm looking at sending/receiving commands, and continuous real-time data being sent between devices.

+2  A: 

Any service you write can be installed on any number of machines - no problem there.

Any machine or code you run on those machines can also act as a client at the same time, calling other services, yes, absolutely, that's totally possible.

You need to define your service contract as an interface and in that service contract you describe the operations (service methods). Once that service is deployed, anyone can act as a client to that service and send it messages.

And of course, you can have an app (ASP.NET, Winforms whatever) that is both simultaneously - it offers services, but also acts as a client to other services.

Hope that helps a bit!

marc_s
Thanks for the info marc! just one thing: How do I send data continuously, and have the app respond to it in real-time? e.g. for Video / Audio.
Jenko
To transfer large amounts of data, you should check out WCF streaming: http://msdn.microsoft.com/en-us/library/ms731913.aspx
marc_s