FIX: Target endpoints in Service Broker of SQL Server 2005 leak in the valid message exchange pattern where the target sends only the end conversation message

Symptoms

Consider the following scenario. You have an application that uses Service Broker in Microsoft SQL Server 2005. The initiator and the target are in different databases on the same instance of SQL Server 2005. In the valid message exchange pattern where the target sends only the end conversation message, the sys.conversation_endpoints table shows that the target endpoint is in the CD state. Additionally, the target endpoint is deleted after the dialog lifetime expires.

Note The default value of the dialog lifetime is about 75 years.

Cause

If a target endpoint sends only the end conversation message, and the initiator and target are in different databases on the same instance of SQL Server 2005, the security time stamp on the target endpoint is not initialized. This causes the target endpoint to be not deleted when the conversation is ended. The target endpoint remains for about 75 years. If many target endpoints send only the end conversation message, the database that holds these target endpoints will become large. These undeleted target endpoints will adversely affect the performance of Service Broker and occupies lots of database space.

Resolution

Service pack information

To resolve this problem, obtain the latest service pack for SQL Server 2005. For more information, click the following article number to view the article in the Microsoft Knowledge Base:
913089 How to obtain the latest service pack for SQL Server 2005

Workaround

To work around this problem, manually force the target to send a dummy message before the target sends the end conversation message.

Status

Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section. This problem was first corrected in SQL Server 2005 Service Pack 3.

More Information

For more information about software update terminology, click the following article number to view the article in the Microsoft Knowledge Base:
824684 Description of the standard terminology that is used to describe Microsoft software updates
Proprietà

ID articolo: 959009 - Ultima revisione: 15 dic 2008 - Revisione: 1

Feedback