Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is Service Broker in SQL Server?

What is Service Broker in SQL Server and is it meaningful to enable it in a simple database, not in a distributed database?

like image 267
Nasser Hadjloo Avatar asked May 18 '10 12:05

Nasser Hadjloo


People also ask

What is a servicing broker?

What Is a Full-Service Broker? A full-service broker is a licensed financial broker-dealer firm that provides a large variety of services to its clients, including research and advice, retirement planning, tax tips, and much more.

What is SQL service broker process?

Service Broker is a feature of SQL Server that monitors the completion of tasks, usually command messages, between two different applications in the database engine. It is responsible for the safe delivery of messages from one end to another.


1 Answers

SQL Service Broker is an extension mechanism that allows you to queue events for asynchronous processing.

There is no intrinsic harm in enabling the broker. If it's not used, it will just be idle.

It works in both simple and distributed DBs. A simple use case would be a logging queue. We used it at a client to queue XML messages to be processed asynchronously. So we push an XML to an InitatorQueue, and then had a service pull them from the queue, extract some necessary attributes via XPath, and insert them into a persistence table in our database.

Here is a good reference from Microsoft.

like image 74
Nix Avatar answered Nov 15 '22 15:11

Nix