Creating WCF Services Experience

I have started with my study of Windows Communication Foundation. As you can read in my previous post I have decided to learn it myself. There are possibilities of learning it form recommended training and consulting companies like IDesign, Developmentor, Wintellect, newtellingence, thinktecture or Pluralsight. I kicked off with a book called learning WCF written by Michele Leroux Bustamante, who also has a blog called thatindigo girl. WCF makes it possible to build secure, reliable, and transacted systems through a simplified programming model that unifies and extends many of the previous .NET technologies including ASMX, WSE, .NET Remoting, .NET Enterprise Services, and System.Messaging. And this just what I want to learn one technology that can do all stuff that ASMX, WSE, etcetera does. It has focus on service orientation and supports for standardized Web Services specifications.

Ok I first lab I did was creating a service contract with a simple operation and implemented it on a service type. Next I had to create a host application and finally a client application.

So let’s recap here what I have done:

  • Service contract with service type

  • Created a host

  • Created a client

  • These 3 steps and one creates a WCF service and it can be run (called). The lab I did was from the book 'Learning WCF' from O'Reilly written by Michele Leroux Bustamante. She also has a site where you can download code used in labs. When I tested my client that calls the service I ran into an error: TCP error code 10061: No connection could be made because the target machine actively refused it. From this I learned that I had to start the host project first, followed by client project. Now it worked. On web there are also a nice article on code project that let you explore Windows Communication Foundation. I tried this out and it worked. Approach was a bit different, because here a configuration file was used for the host. In this case one use svcutil to create proxy code and configuration items. I did run into another problem, when using svcutil. Their solution though I found here at this blog post. By running sn -Vr svcutil inside C:\Program Files\Microsoft SDKs\Windows\V6.0A\Bin folder it will work (thanks to Nishith Pathak).


    Labels: ,