📜 ⬆️ ⬇️

Windows Azure: Queues and Service Bus Queues - Similarities and Differences

image

This article analyzes the similarities and differences between the two types of queues available in the modern Windows Azure platform: Windows Azure queues and Windows Azure service bus queues. Based on this information, you can highlight the similarities and differences of the relevant technologies and choose the solution that best meets your needs.

Introduction


Windows Azure supports two types of queuing mechanisms: Windows Azure queues and service bus queues .
')
The Windows Azure queues that are part of the Windows Azure storage infrastructure support a simple REST interface with Get / Put / Peek functions to create reliable and fault-tolerant messaging between and within services.

Service bus queues are part of a larger Windows Azure messaging infrastructure that supports queuing, as well as publishing, subscribing, web services, and integration patterns.

Both queuing technologies exist in parallel, but Windows Azure queues have appeared earlier. This add-on for Windows Azure storage services is a specialized mechanism for working with data warehouses using queues. Service bus queues are presented in the newest release of the service bus. They are an add-on to a more extensive messaging infrastructure. This infrastructure is designed to integrate applications or application components that can use several different messaging protocols, data contracts, trusted domains, and network environments.

This article provides a comparative analysis of the two queuing technologies implemented in Windows Azure. The modes of operation and functionality of both technologies are discussed. The article also provides recommendations for choosing the functions best suited for solving your application development tasks.

Technology selection


Windows Azure queues and service bus queues are an implementation of Message Queuing service that is currently available in Windows Azure. These technologies have different sets of functions. You can choose either of them or both at once, depending on your needs or the problem being solved (technical or commercial).

When choosing a queuing technology for a specific solution, its architects and developers should consider the recommendations below. For more information, see the following section.

Architects or solution developers need to consider using Windows Azure queues in the following cases.


Architects or solution developers need to consider using Windows Azure service bus queues in the following cases.


Comparing Windows Azure Queues and Service Bus Queues


The tables in the following sections contain logically grouped queue functions. These tables clearly demonstrate the difference in the capabilities of Windows Azure queues and service bus queues.

Basic features


This section provides a comparative analysis of the main functions of Windows Azure Queues and service bus queues.

Comparison criterion
Windows Azure Queues
Service Bus Queues
Ordering guarantee
Not
Yes - “first entered, first released” (FIFO)

(using messaging sessions)
Delivery guarantee
At-Least-Once (At least Once)
At-Least-Once (At least Once)

At-Most-Once (Maximum Once)
Transaction support
Not
Yes

(using local transactions)
Reaction to receive
Non-blocking

(terminates immediately if new messages are not found)
Blocking (with and without waiting time)

(support for long polling intervals or method based on long-lived HTTP connections )

Non-blocking

(only using the API managed by the .NET platform)
Receiving mode
Read and rent
Read and lock

Receiving and deleting
Exclusive access mode
Based on rent
Lock based
Duration of lease and blocking
30 seconds (default)

7 days (maximum)
60 seconds (default)

5 minutes (maximum)
Detail lease / lock
Message level

(each message can have its own timeout value)
Queue level

(each queue has its own lock specification that is valid for all messages and fixed for the entire period of the queue’s life)
Batch receipt
Yes

(explicit indication of the number of messages upon receipt, no more than 32 messages)
Yes

(including prefetching implicitly (using a parameter) or explicitly (using transactions))
Batch shipping
Not
Yes

(using transactions or batch sending by the client)

Additional Information



Extended capabilities


This section provides a comparative analysis of the advanced capabilities of Windows Azure queues and service bus queues.

Comparison criterion
Windows Azure Queues
Service Bus Queues
Scheduled Delivery
Yes
Yes
Automatic marking of deleted messages
Not
Yes
Deferred messaging
Yes

(using update on-site visibility timeout)
Yes

(using the specialized API function)
Fault reporting support
Yes
Yes
In-place upgrade
Yes
Not
Server side transaction log
Yes
Not
Storage metrics
Yes
Not
Queue cleaning function
Yes
Not
Message groups
Not
Yes

(using messaging sessions)
Duplicate message detection
Not
Yes

(configured on the sender side)
WCF integration
Not
Yes

(contains ready-made WCF bindings)
WF Integration
Customization

(requires the creation of a custom action WF)
Own

(contains ready-made WF actions)

Additional Information



Capacities and quotas


This section provides a comparative analysis of Windows Azure Queues and service bus queues in terms of capacity and effective quotas.

Comparison criterion
Windows Azure Queues
Service Bus Queues
Maximum message size
64 KB

(48 KB using Base64 encoding)
256 KB

(including the header and text of the message; the maximum header size is 64 KB)
Maximum queue size
100 TB

(limited to one storage account)
1, 2, 3, 4 or 5 GB

(determined when creating a queue)
Maximum lifetime of the message
7 days
With no restrictions
Maximum number of queues
With no restrictions
10,000

(for one service namespace, can be increased)
Maximum number of concurrent clients
With no restrictions
With no restrictions

(A limit of 100 simultaneous connections applies only to TCP communication)

Additional Information



Management and operation


This section provides a comparative analysis of the Windows Azure queue management and service bus queue management features.

Comparison criterion
Windows Azure Queues
Service Bus Queues
Control protocol
REST over HTTP / HTTPS
REST over HTTPS
Runtime protocol
REST over HTTP / HTTPS
REST over HTTPS

TCP with TLS support
API running .NET
Yes

(Storage Client API Running .NET)
Yes

(.NET Intermediate Messaging API)
Java API
Yes
Yes
PHP API
Yes
Yes
Node.js API
Yes
Not
Support for custom metadata
Yes
Not
Queue Naming Rules
Up to 63 characters

(in the queue name only lower case should be used)
Up to 260 characters

(queue names are not case sensitive)
The function of getting the queue length
Yes

(approximate value)
Yes

(exact value for a specific point in time)
Read function
Yes
Not

Additional Information



Performance


This section provides a comparative analysis of Windows Azure Queues and service bus queues in terms of performance.

Comparison criterion
Windows Azure


2000
2000

( 1 )

10

( TCP Nagle )
100

HTTP 503

(, , )
HTTP 503

(, , )

Additional Information



Authentication and Authorization


This section provides a comparative analysis of the authentication and authorization features of Windows Azure queues and service bus queues.

Comparison criterion
Windows Azure Queues
Service Bus Queues
Authentication
Symmetric key
ACS Applications
Role Based Access Control
Not
Yes

(using ACS roles)
Federation of Identity Providers
Not
Yes

Additional Information



Expenses


This section provides a comparative analysis of the costs of using Windows Azure queues and service bus queues.

Comparison criterion
Windows Azure Queues
Service Bus Queues
Transaction Cost for Queue
0,01 .

( 10 000 )
0,01 .

( 10 000 )

Everything


( )



( )


( )

0,14 .

( )
0,00 .

0,12–0,19 .

( )
0,12–0,19 .

( )
Windows Azure Access Control (ACS)
0,00 .

( ACS )
1,99 .

( 10 000 ; . )

Additional Information



Note.All cost indicators are subject to change. The table above reflects pricing at the time of this writing. The article does not contain promotional offers available at the time of reading. For current pricing information, see the Pricing Overview page .

Conclusion


Obviously, deciding whether to use Windows Azure queues or service bus queues depends on a large number of factors. These factors depend on the specific requirements of your application and its architecture. If your application already uses the basic functions of Windows Azure, you can select Windows Azure queues. This is especially true if you need basic data and message exchange between services, or if you need queues that exceed 5 GB.

Service bus queues have many advanced features: sessions, transactions, duplicate detection, automatic queuing for deletion, fault-tolerant publishing and subscription tools. You can choose this solution if you are creating a hybrid application, or if the above features are needed for your application to work.

At the beginning of this article, an overview of the prescriptions and recommendations is given. Next, we consider the capabilities of queuing technologies available in the Windows Azure environment. The grouping of features by function allows for a visual comparative analysis to identify similarities and differences between Windows Azure queues and service bus queues.

An in-depth study of these issues will help you choose the queuing technology that is most appropriate for specific tasks.

see also


Best Practices for Leveraging Windows Azure Service Bus Brokered Messaging API ( API Windows Azure)

Best Practices for Performance Improvements Using Service Bus Brokered Messaging ( )

How to Use Service Bus Queues ( )

How to Use the Queue Storage Service ( )

Introducing Queues and Topics in Azure Service Bus ( , Azure)

The Developer's Guide to Service Bus ( ; )

Windows Azure Tables and Queues Deep Dive ( Windows Azure — )

Windows Azure Storage Architecture ( Windows Azure)

Using the Queuing Service in Windows Azure ( Windows Azure)

Understanding Windows Azure Storage Billing – Bandwidth, Transactions, and Capacity ( Windows Azure — , )

Source: https://habr.com/ru/post/156715/


All Articles