Skip to content

Windows Azure Service Bus Queues, Topics / Subscriptions

September 14, 2011

We just released to production the Queues, Publish-Subscribe with Topics / Subscriptions features that were earlier showcased in Community Technology Preview for Service Bus. For an introductory period these Brokered Messaging features are free, but you continue to pay Azure data transfer. Also the Relay features continue to be charged as before. Following are steps to quickly get started, and the links to additional resources:

The steps below are to download and run a simple application that showcases the publish-subscribe capabilities of Service Bus. You will need to have Visual Studio and NuGet installed. We will start by creating a new console application in VS:



Open the Project –> Properties and change the Target framework to .NET Framework 4



From the References node in Solution Explorer click on the context menu item for Add Library Package Reference. This will show only if you have NuGet Extension installed. (To learn more about NuGet see this TechEd video).



Search for “AppFabric” and select the Windows Azure AppFabric Service Bus Samples – PublishSubscribe item. Then complete the Install and close this dialog.



Note that the required client assemblies are now referenced and some new code files are added.



Add the following line to the main method in Program.cs and hit F5


At this point you will be prompted to provide a ServiceNamespace and Issuer Name and Key. You can create your own namespace from



Once a new namespace has been created you can retrieve the key from the Properties section by clicking View under Default Key:


These values can now be used in the Console application:


At this point you can run thru the different scenarios showcased by the sample. Following are some additional resources:

Download page for SDK and Samples

Documentation for Service Bus September Release

Forum for feedback

Looking forward to your feedback / questions / concerns / suggestions.

  1. Mikel permalink

    Hello Abhishek,

    we use the Windows Service Bus to publish and subscribe messages. I want to develop a C# application. The application should check performance counters on the Service Bus like

    • The current number of messages per Topic / Queue
    • The average processing time per message
    • The number of messages processed per unit of time

    I saw that there is a package for C# available named “Service Bus 1.0 for Windows Server” but with that you can’t check performance counters, am I right?

    But then I found the Windows Azure Monitoring Services Management Library:

    I tried to check performance counters with the help of the Microsoft.WindowsAzure.Diagnostics.dll. But I looked at the online documentation and I found out that you can use this library only if you use the whole Windows Azure Suit, am I right? We only use the Servis Bus for Windows Server.

    Do you have any suggestions how to check the performance counters on the Service Bus for Windows Server?

    Best regards and thank you for your help

Trackbacks & Pingbacks

  1. Windows Azure and Cloud Computing Posts for 9/19/2011+ - Windows Azure Blog
  2. A Conceptual Understanding of Azure ServiceBus Topics |
  3. A Conceptual Understanding of Azure AppFabric ServiceBus Topics

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: