SQL SERVER – Introduction to Service Broker

Service Broker supports transactional asynchronous messaging within SQL Server. I separate queued work from the application that processes it.

A wrapped parcel waits safely in a receiving cubby beside a prepared delivery shelf.

Database Mail was the example in the original introduction. It uses a queued architecture, and its external program sends mail to an SMTP server. Service Broker itself is broader than an email sender and does not use SMTP to deliver its own database conversations.

Separate sending and processing

A transaction can enqueue a message with its database work. A receiver processes committed messages later. The applications don’t need to be active together. Routing, security and conversation handling still matter.

Services, queues, message types, contracts, and conversations give that work structure. Durable messaging does not excuse an application from handling errors or completing conversations.

Keep the historical comparison clear

SQL Server 2005 introduced SMTP-based Database Mail as an alternative to SQLMail’s older MAPI approach. That history explains the relationship. A new mail configuration still needs an environment-specific review.

Reference: Database Mail external program.

Related reading

A queued message is not completed business work, it is a committed request awaiting processing.

Published by Pinal Dave on SQLAuthority. More of my work at pinaldave.com.


Discover more from SQL Authority with Pinal Dave

Subscribe to get the latest posts sent to your email.

Database Mail, Service Broker, SQL Server
Previous Post
Organising Notes You Have Already Written
Next Post
SQL Server – Fix – Error : 9692 The _MSG protocol transport cannot listen on port because it is in use by another process.

Related Posts

6 Comments. Leave new

Leave a Reply

Your email address will not be published. Required fields are marked *

Fill out this field
Fill out this field
Please enter a valid email address.