Application designers and developers have been attempting to deliver loosely coupled services using technologies like ASMX, .NET Enterprise Services, MSMQ, and .NET Remoting for roughly the past five years. These experiences have proven to be very challenging, and there have been limitations found in each of the .NET programming techniques. The result has been passive adoption by enterprises and constant confusion in the development community on what technology is best suited for delivering building block application components.
Enter Windows Communication Foundation (formerly Indigo). This technology stack from Microsoft claims to be the unified technology best positioned to help developers deliver a service-oriented strategy. In this two-part article I will briefly talk about the goals of a service-oriented architecture. Following that overview, I will describe the feature set that has been delivered with Beta 1 of the Windows Communication Foundation (WCF). As we look at each feature, I will talk about how it overcomes many of the limitations of the previously fragmented approaches. I will also discuss how these features help to reinforce the four primary service-oriented tenets.
Why Do We Care about Service Orientation?
The features delivered with WCF are positioned as the best technology stack to date that facilitates designing and delivering service-oriented components. Service-orientation is often misrepresented as a technology stack itself. In actual practice, service orientation is a design concept. That concept focuses on delivering concise loosely coupled application components that can stand the test of time. Application architects today have a challenging task. The constant pursuit of renewable investments in a companys application development deliverables requires careful planning and extreme flexibility.
There are also other reasons that service-oriented components continue to be the focus of most enterprises. Reusable application components will continue to find new clients that will need to consume them. In the past, component-based code reuse would suffice, but in most companies today the need for cross-platform reuse makes any proprietary strategy very short-sighted. The constant need for agility, platform independence, return on investment (ROI), and multi-client capabilities will continue to drive any enterprise to service-oriented design.
Services vs. Web Services
Most, if not all, conversations about service-oriented architectures progress into a broad overview of the shortcomings of ASMX. One of the most important concepts to realize when looking at the WCF technology is that we are no longer talking about web services alone. WCF is positioned to help deliver services, not simply web services. The following four items help to better describe the differences.
- Web services are only invoked via HTTP. Services are not limited by transport. As you will see later in this article, there are a number of other transports that can be used to invoke WCF services.
- Web services today are limited to request-reply communications. Services are capable of many other types of communication techniques.
- Web services do not contain a robust set of features. Services, on the other hand, have features that allow them to be considered more of an enterprise strength technology set.
- Web services are not flexible. The limitations of web services today have created numerous challenges when attempting to satisfy the services are autonomous tenet of service orientation. Services on the other hand remain very agile. The remainder of this article will show how.
What is Windows Communication Foundation?
Windows Communication Foundation is the unification of all the technologies used to deliver distributed systems that run on the Microsoft platform. WCF is also an evolution of the recent attempts to promote service-oriented delivery on top of the ASMX stack. Microsoft has used the experiences from the industry after delivering the web service enhancements version 1.0 and 2.0 and shipped a consolidated set of features for developing distributed interoperable systems.
WCF can promote service orientation, but it is definitely not limited to that design strategy. WCF can be used just as .NET Remoting and .NET Enterprise Services were in the past. When the application requires physical separation of its tiers, WCF can be used.