Reputation: 4807
I am trying to understand what is WCF, but can't get a visual understanding of how it adds value (reading msdn does'nt help). I have worked with COM in the past, and I know about webservices. Can someone shed some light on what is WCF and its pros and cons (maybe how it relates to COM or replaces COM etc)?
If I can visualize the architecture layout, I can begin to understand what component does what function.
Links to reference web sites would also be great.
Thanks
Upvotes: 7
Views: 5230
Reputation: 564821
I don't recommend comparing WCF to COM.
Windows Communication Foundation is all about communication - In particular, from the WCF website, it "provides a unified programming model for rapidly building service-oriented applications that communicate across the web and the enterprise."
It's really a different approach to inter process communication, unifying it. It makes it so you can use a clean, service oriented API for all communication between processes, and easily change the underlying technology used by the services (ie: switch from HTTP to TCP to Pipes, etc).
By leveraging WCF, you can make processes that communicate between themselves in a clean, consistent manner. The same API can be used for talking to web services, passing data between two desktop applications, or communication between the desktop and a service on a system. In all cases, you can easily switch the protocols used, etc.
This provides a lot of flexibility with a single toolkit.
As far as pros and cons vs. other options - There are a lot of pros, mainly in terms of being able to use a unified development model. Personally, I use WCF for all of my current IPC needs, as it's pretty much replaced remoting as the preferred API for IPC in .NET.
The main con would be performance in some specific scenarios. Using WCF adds a (slight) overhead, so, in some situations, doing your own low level socket development will perform better. Unless you're writing a real time game or something like that, the development effort involved in a low level communication protocol isn't worth the gain, though.
Upvotes: 8
Reputation: 60095
WCF is very general framework for Interprocess/Intermachine communications. That's it. For .net options are: custom network comm, webservice, .net remoting. WCF substitutes webservice (backward compatible) and .net remoting (not backward compatible) with proving rich set of communication options and features. It can use different transport layers - tcp, web service, msmq
Upvotes: 1