Sunday, March 27, 2011

WCF - advantages and disadvantages

I would like to find out about BOTH advantages and disadvantages of Windows Communication Foundation from people who have used it or just know it theoretically.

From stackoverflow
  • For me it is that your code to communicate via SOAP, WS*, TCP, MSMQ, Named Pipes or any other transport later is the same.

  • A major advantage is that WCF allows a single consistent access to windows communication technologies for developers thereby enabling easier development of SOA applications. Microsoft has abstracted a lot of the plumbing work so as to enable this.

    A drawback would be that, WCF is Microsoft's implementation of SOA and hence its APIs are solely controlled by MS which makes interoperability a bit difficult. Also, to deploy WCF apps, you will need more underlying hardware resources on the platform on which the WCF applications will be running, since there is an additional layer of abstraction to deal with.

  • advantages

    • Its made of a lot of different components, so you can create new components for security, transport, authentication
    • Its faster than ASMX
    • Supports Scaling/Load Balancing
    • Its Interoperability, for java, and more..

    disadvantages - bit of a learning curve to learn about all the different transport types/security spec.

    If you want anything faster you would have to go to the TCP level

    Edit Also Its Hard To Get To Grips With Concurrency To Do With Connected Clients

  • I found it very easy to set up and learn. I had a web-service running in a few hours without any experience using WCF. I can do it in a few minutes now.

    The downside of this is that I still know next to nothing about webservices. This can turn around and bite you later. Its very easy to make the wrong design decisions based on incorrect assumptions on how things work. It's very easy to maintain state in your service classes for example but this will cause scaling-problems later.

  • I don't think there are supposed to be inherent trade-offs aside from having to use the WinStack. WCF is supposed to be replacing both .NET remoting and bog standard web services (or rather WCF can also do Web Services)

  • Primary advantage: Once you get over the learning curve, WCF makes it relatively easy to expose and consume software components. i.e. Given a component bakes functionality into a WCF Service Contract, a developer can expose that same component in-proc, across processes on a single box, across a Windows intranet, or throughout the internet all by just changing hosts and configuration information. Likewise it's easy for clients of said component to use it in any of those scenarios as well.

    Primary disadvantage: the learning curve. WCF seems very daunting to many developers when they first begin looking into it. I made several false starts trying to get into Juval Lowy's "Programming WCF Services." Though I've found that comprehension came quickly once I began actually creating and consuming components.

    The key thing to remember is that WCF let's you write some nice functional code and wrap it into a component that you can then relatively easily use just about anywhere with just about any amount of security, reliability and durability.

    Compared to what we were forced to use previously, WCF is fantasitc!

  • The advantage is a standard architecture for SOA applications. You can customize the components of the architecture to enable connection with any kind of non-Windows clients, however there is a steep learning curve.

0 comments:

Post a Comment