Subscribing to an Azure Queue

4.1k views Asked by At

I have an Azure web site that generates reports. The reports take ~45 seconds to generate and I'd like to migrate that a worker role to lessen the load on the web site.

I've been researching which tool to use to enable the web site to pass a "report generation request" to the worker role. Azure Queues look like the way to go, but from what I've seen in the Channel 9 Azure Friday series, blog posts and Stackoverflow (Azure Service bus queues topics vs queues for web/worker roles, Writing a listner to Azure Queue), Azure Queue only supports polling.

However, Azure is changing rapidly and this information is a bit old. Is it still the case that Queue's only support polling?

If that's the case would I be better off using Azure Service Bus to pass messages as it supports a Publish/Subscribe model? I'm a little hesitant to use the Service Bus as I don't seam to need any of the features specific to the Service Bus descibed on MSDN.

3

There are 3 answers

2
Seth Manheim - MSFT On BEST ANSWER

if you're looking for a publish/subscribe messaging pattern, check out Service Bus topics and subscriptions (http://msdn.microsoft.com/en-us/library/hh367516.aspx and http://msdn.microsoft.com/en-us/library/hh699844.aspx). Topics and subscriptions are basically Service Bus queues with pub/sub capabilities.

For more background information, you might want to check out this comparison of Azure Queues and Service Bus queues: http://msdn.microsoft.com/en-us/library/hh767287.aspx.

Hope that information helps, Seth Manheim Azure Doc Team

2
TheDude On

I believe Azure Queues still only support polling. I can't find any documentation that says otherwise. If you want a publish / subscribe model, Service Bus Queues or Event Hubs may work best for you.

0
johny why On

"Azure Storage Queues implements the publish/subscribe (pub/sub) pattern. In version 9 and below, this feature relies on message-driven pub/sub which requires a separate persistence for storage of subscription information. In version 10 and above, the transport handles subscription information natively and a separate persistence is not required." https://docs.particular.net/transports/azure-storage-queues/native-publish-subscribe

Adding trigger to workflow