Sdílet prostřednictvím


Monitoring Service Broker

SQL Server provides dynamic management views, trace events, and performance objects to monitor Database Engine activity that is related to Service Broker.

Dynamic Management Views

The following dynamic management views let you monitor Service Broker activity.

View Description

sys.dm_broker_activated_tasks

Contains a row for each stored procedure activated by Service Broker.

sys.dm_broker_connections

Contains a row for each Service Broker network connection.

sys.dm_broker_forwarded_messages

Contains a row for each Service Broker message that the SQL Server instance is in the process of forwarding.

sys.dm_broker_queue_monitors

Contains a row for each queue monitor in the instance. A queue monitor manages activation for a queue.

Performance Objects

The following performance objects report on Service Broker activity.

Performance object Description

SQL Server, Broker Activation Object

Contains performance counters that report information on stored procedure activation.

SQL Server, Broker Statistics Object

Contains performance counters that report general Service Broker information.

SQL Server, Broker / DBM Transport Object

Contains performance counters that report information related to Service Broker and database mirroring network activity.

Trace Events

SQL Server includes the Broker event category for monitoring Service Broker activity. The following table lists the events in the Broker event category:

Event Description

Broker:Activation Event Class

An event generated when a queue monitor starts an activation stored procedure.

Broker:Connection Event Class

An event generated to report the status of a transport connection managed by Service Broker.

Broker:Conversation Event Class

An event generated to report the progress of a conversation.

Broker:Conversation Group Event Class

An event generated when the database creates or drops a conversation group.

Broker:Corrupted Message Event Class

An event generated to report that the database has received a corrupt message.

Broker:Forwarded Message Dropped Event Class

An event generated when SQL Server drops a Service Broker message that was to have been forwarded.

Broker:Forwarded Message Sent Event Class

An event generated when SQL Server forwards a Service Broker message.

Broker:Message Classify Event Class

An event generated when Service Broker determines the routing for a message.

Broker:Message Drop Event Class

An event generated when Service Broker is unable to retain a received message that should have been delivered to a service in this instance.

Broker:Remote Message Ack Event Class

An event generated when Service Broker sends or receives a message acknowledgement.

Two security audit events are also provided for Service Broker. For more information on those events, see Audit Broker Login Event Class and Audit Broker Conversation Event Class.

See Also

Other Resources

Service Broker Catalog Views (Transact-SQL)

Help and Information

Getting SQL Server 2005 Assistance