Demo Script

AppFabric Service Bus Service Registry

Lab version:2.0.0

Last updated:10/19/2018

Contents

Overview

Key Messages

Key Technologies

Time Estimates

Setup and Configuration

Task 1 –Running Dependency Checker

Task 2 – Creating a Windows Azure Service project

Task 3 – Opening the Echo Sample

Demo Flow

Opening Statement

Step-by-Step Walkthrough

Show the ServiceRegistrySettings behavior

Run the Echo Service and show the service registry ATOM feed

Summary

Known Issues

Overview

This demo shows Service BusService Registry displayed as an Atom feed in the browser.

Note: In order to run through this complete demo, you must have network connectivity and a Service Bus namespace.

Key Messages

  1. Services can be published via the service registry via WS-Transfer or Atom Publishing protocol
  2. Because they are exposed as an ATOM feed they are easily viewed from a browser
  3. You have complete control over what is published

Key Technologies

This demo uses the following technologies:

  1. .NET Framework 3.5 SP1
  2. Visual Studio 2010
  3. Windows Azure platform AppFabric SDK
  4. AppFabric Services Service Bus

Time Estimates

  • Estimated time for setting up and configuring the demo: 10 min
  • Estimated time to complete the demo: 5 min

Setup and Configuration

This demo does not have any advanced configuration requirements. You simply need to have the prerequisites installed and have an account for AppFabric. For more information on how to purchase an account, visit the AppFabric Portal at

Task 1 –Running Dependency Checker

The following steps describe how to run the Dependency Checker utility included with the demo to verify that you have the prerequisite components. You can skip this exercise if you are confident that the prerequisites are properly installed and configured.

  1. Open a Windows Explorer window and browse to the demo’sSource\Scriptfolder.
  2. Double-click theDependencies.depfile in this folder to launch the Dependency Checkertool and install any missing prerequisites.
  3. If the User Account Control dialog is shown, confirm the action to proceed.

Note: This process may require elevation.The .dep extension is associated with the Dependency Checker tool during its installation. For additional information about thesetupprocedure and how to install the Dependency Checker tool, refer to theSetup.docxdocument in theAssetsfolder of the training kit.

Task 2 – Creating a Windows Azure Service project

  1. You must create a Windows Azure Services project and one or more service namespaces inside it.To create and manage your project and service namespaces, log in to the AppFabric portal and select the solution you want to manage.

Task 3 – Opening the Echo Sample

  1. Open Visual Studio running as administrator and open %ProgramFiles%\Windows Azure platform AppFabric SDK\V1.0\Samples\ServiceBus\GettingStarted\Echo\CS35\EchoSample.sln

Note: The Windows Azure AppFabric SDK samples are available as Visual Studio 2008 solutions (C# and VB) and require Microsoft .NET Framework 3.5 SP1 or higher to run. In order to run the samples with Visual Studio 2010 open the solutions with Visual Studio 2010 and follow the Conversion Wizard instructions. Notice that the solutions will work as expected but will be still targeting .Net Framework 3.5 (not 4.0).

Demo Flow

The following diagram illustrates the high-level flow for this demo and the steps involved:

Figure 1

Demo Flow

Opening Statement

This demo shows the AppFabric Service Bus Service Registry. This provides a very simple way for you to make your services discoverable over the internet via an ATOM feed.

Step-by-Step Walkthrough

This demo is composed of the following segments:

  1. Run the Echo sample
  2. Login to the portal
  3. Show the service registry ATOM feed – nothing
  4. Add ServiceRegistrySettings behavior
  5. Show the service registry ATOM feed – entry shows up

Showthe ServiceRegistrySettings behavior

Action / Script / Screenshot
  1. Open EchoSample.sln.
  2. Open program.cs in the service project.
  3. Show the ServiceRegistrySettingsbehaviour creation.
/
  • To add our service and make it visible we need to add a SeviceRegistrySettings behavior with a discovery type of Public.
/

Run the Echo Service and show the service registry ATOM feed

Action / Script / Screenshot
  1. Run the echo service
  2. Enter the namespace, issuer name and key.
  3. Browse to web page with the ATOM Feed,
/
  • Our service appears in the public Service Registry ATOM feed.
/

Summary

This demo showed how services can be added to the AppFabric Services service registry when they are connected to the Service Bus.

Known Issues

Please note the following known issues with this demo:

  • Beware the lifetimes of published services in the registry. There is currently a 15 minute limit.