44

Is there a way to play with and discover Azure Service Bus on the local emulator without registering to the real Azure Services?

I was following a tutorial on the use of the Azure Service Bus but at a certain point a Namespace and an Issuer Name and Key is required. I don't have that data since I'm not registered to Azure Services and I don't want to do it now (I will get my trial when I will feel ready to develop/test something real).

SliverNinja - MSFT
  • 31,051
  • 11
  • 110
  • 173
Alex
  • 1,237
  • 3
  • 18
  • 29
  • 1
    Consider using a messaging framework like NServiceBus or MassTransit which will give you a higher-level API as well as support for other more locally-friendly transports like RabbitMQ or even in-memory. Here's a nice "game" for getting familiar with these architectural styles: https://parsec.particular.net/ – Udi Dahan Oct 28 '22 at 13:41

2 Answers2

53

If you want to use the Brokered Messaging capabilities (Queues, Topics and Subscriptions) then you can install Service Bus for Windows Server, which will allow you to test locally.

http://msdn.microsoft.com/en-us/library/windowsazure/jj193022(v=azure.10).aspx

For relayed messaging you will have to use an Azure account. The costs of using the relay service for development and testing are minimal, so it may be worth creating a pay-as-you-go subscription for this.

Benjamin Wegman
  • 465
  • 4
  • 15
Alan Smith
  • 706
  • 1
  • 5
  • 4
  • 2
    Thanks for sharing! [**Service Bus 1.0** is something that just became available 10/24/12.](http://blogs.msdn.com/b/windowsazure/archive/2012/10/24/announcing-public-availability-of-service-bus-for-windows-server-service-bus-1-0.aspx). They say the API is symmetric with the Azure Service Bus API, but from a security standpoint it seems you need to use STS instead of Azure ACS. Too bad you can't run this on a developer machine - Service Bus 1.0 requires a windows server (*BizTalk doesn't even require this and **Server AppFabric** just requires IIS*) – SliverNinja - MSFT Oct 28 '12 at 14:16
  • 7
    Confirming that **Windows 8** does support **Service Bus 1.0** - you [don't have to run it on a Windows Server](http://social.msdn.microsoft.com/Forums/en-US/servbus/thread/e5f887b5-9925-4bb3-ac64-93dddd4b13ca). [Download Service Bus 1.0 here and get started!](http://www.microsoft.com/en-us/download/details.aspx?id=35374). See the [getting started guide here.](http://msdn.microsoft.com/en-us/library/jj193021(v=azure.10)). A **default Namespace** (*ServiceBusDefaultNamespace*) and **access token** are generated for you as part of the installation process. – SliverNinja - MSFT Oct 28 '12 at 14:53
  • @SliverNinja do you happen to know if this is supported by the Node.js library? I have got it running locally but when I attempt to connect using the azure lib it fails with a 401. – James Feb 26 '14 at 11:53
  • 4
    Be aware that he Service Bus for Windows Server requires a specific version of the .NET Azure Client. This means that you may not be able to use the same client package for accessing a Windows Server instance and a Azure Instance. – Douglas Jimenez Feb 29 '16 at 04:12
  • 1
    @DouglasJimenez Which version is 'a specific version'? – Russell Horwood Mar 06 '18 at 11:08
  • hi, I placed another question here, thanks https://stackoverflow.com/questions/63527485/net-test-azure-service-bus-queues-locally –  Aug 21 '20 at 17:34
26

Unfortunately there is not an emulated Azure Service Bus you can run locally. The Azure Service Bus requires an active Azure Subscription. You will need a trial, MSDN subscription, or pay for a pay-as-you go subscription. The relay itself is extremely cheap - $0.01 per 10,000 messages. Dive in and start experimenting with your Azure 90 day trial. If you run out of trial, I'm sure MS would work with you if you could justify the extension.

One of the reasons I expect that it doesn't work without a subscription is that the service bus requires Azure ACS for authentication (this is the source of the Issuer Name and Key you are looking for) which also lacks emulation to my knowledge.

0xced
  • 25,219
  • 10
  • 103
  • 255
SliverNinja - MSFT
  • 31,051
  • 11
  • 110
  • 173
  • hi, I placed another question here, thanks https://stackoverflow.com/questions/63527485/net-test-azure-service-bus-queues-locally –  Aug 21 '20 at 17:34