Administering the Service Broker


The SQL Server Service Broker provides a number of configuration options that govern how the SQL Server Service Broker subsystem operates. In this section, you’ll get a brief look at some of the most important configuration options. You’ll learn about SQL Server Service Broker security, as well as look at some of the system views that SQL Server 2005 provides to enable you to get information about the SQL Server Service Broker objects and applications.

System Configuration Options

There are several system configuration options that can be set using the sp_configure system stored procedure to influence the behavior of the SQL Server Service Broker subsystem. Table 6-3 lists the available sp_configure options for the SQL Server Service Broker.

Table 6-3: Options for sp_configure

sp_configure Parameter

Description

broker tcp listen port

Sets the port that the SQL Server Service Broker uses for network connections. The default value is 4022.

broker authentication mode

Sets type of remote authentication that will be used for connections. A value of 1 means no authentication will be used. A value of 2 means that authentication is supported. A value of 3 means authentication is required. The default value is 3.

broker forwarding size limit

Sets the maximum disk space in MB to store messages to be forwarded. The default value is 10.

broker message forwarding

Sets the type of message forwarding that is allowed. A value of 1 means no forwarding is allowed. A value of 2 allows forwarding with the domain. A value of 3 allows external forwarding. The default value is 1.

Dialog Security

When dialogs are created, they can optionally be secured using the WITH ENCRYPTION clause. When a dialog is created using the WITH ENCRYPTION clause, a session key is created that’s used to encrypt the messages sent using the dialog. One important point about dialog security is the fact that it is an end-to-end form of security. In other words, the message is encrypted when it is first sent from a dialog, and it is not decrypted until the message reaches its endpoint. The message contents remain encrypted as the message is forwarded across any intermediate hops. To implement dialog security, the SQL Server Service Broker uses certificate-based authentication, where the certificate of the sending user is sent along with the message. Because of the asynchronous nature of SQL Server Service Broker, the security information is stored in the message headers and retrieved by the receiving service when the message is retrieved. This design enables SQL Server Service Broker applications to avoid the need to establish a connection to authenticate messages.

System Views

SQL Server 2005 supplies several new system views that enable you to retrieve information about SQL Server Service Broker objects and their current statuses. Table 6-4 lists the new Service Broker catalog views.

Table 6-4: New Service Broker Catalog Views

System View

Description

sys.service_message_types

Lists all the message types that have been created. System message types are listed at the top, while user-defined messages types are listed at the end of the display.

sys.service_contracts

Lists all of the contracts that have been created.

sys.service_contract_message_usages

Lists the relationships between contracts and message types. Relationships can be one-to-one or one-to-many.

sys.services

Lists the created services.

sys.service_contract_usages

Lists the relationships between contracts and services. Relationships can be one-to-one or one-to-many.

sys.service_instances

Lists the services that are active at the current time.

sys.conversation_endpoints

Lists the conversation endpoints that are currently active.

sys.routes

Lists the created routes.

sys.remote_service_bindings

Lists the relationships of the services and the users that will execute the service.

sys.transmission_queue

Lists all of the messages that are queued to be sent.

sys.service_queues

Lists the queues that have been created.




Microsoft SQL Server 2005 New Features
Microsoft SQL Server 2005 New Features
ISBN: 0072227761
EAN: 2147483647
Year: 2005
Pages: 80
Authors: Michael Otey

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net