Counting Service Sample

The Counting Service sample demonstrates how to use the Service Catalog consumer classes to retrieve service URIs given a set of binding keys. The service URIs are then used to compose a manifest, and then create and route message to a session using Session consumer classes.

The sample consists of a simple Windows Forms client and two ASHX Web services. The two Web services are identical in functionality in that they expose a Web method that accepts an integer value and then sends a reply message back to session with the input value incremented by one. The manifest is configured to tell Session to send the requests out in a round-robin fashion, hitting each ASHX Web service once, and the result is to be sent back to the Windows Forms UI client for display. The context diagram below illustrates the messaging sequence of this sample.

              Figure: Counting Service sample context diagram                       

From the Windows Forms UI, the user can perform the following tasks:

  1. Create a session, loading the session manifest either from a file or composing it programmatically
  2. Route a simple message containing an integer value as the message payload
  3. Terminate a session
  4. View the response message of each action


Counting Sample Design Overview