Microsoft KB Archive/255546

From BetaArchive Wiki
Knowledge Base

Microsoft Message Queuing duplicate message removal mechanism

Article ID: 255546

Article Last Modified on 2/23/2007


  • Microsoft Message Queuing 3.0
  • Microsoft Message Queuing 2.0
  • Microsoft Message Queue Server 1.0

This article was previously published under Q255546

Important This article contains information about how to modify the registry. Make sure that you back up the registry before you modify it. Make sure that you know how to restore the registry if a problem occurs. For more information about how to back up, restore, and modify the registry, click the following article number to view the article in the Microsoft Knowledge Base:

256986 Description of the Microsoft Windows registry


When you use the following configurations, Microsoft Message Queuing monitors for duplicate messages and removes them:

  • Microsoft Message Queuing version 3.0 on Microsoft Windows Server 2003 or on Microsoft Windows XP
  • Microsoft Message Queuing version 2.0 on Microsoft Windows 2000
  • Microsoft Message Queue Server version 1.0 on Microsoft Windows NT Server 4.0 with Service Pack 6 installed

The behavior that is described in this article affects only non-transactional messages. The delivery for transactional messages is not changed or affected by the caching mechanism that is described in this article.


Warning Serious problems might occur if you modify the registry incorrectly by using Registry Editor or by using another method. These problems might require that you reinstall the operating system. Microsoft cannot guarantee that these problems can be solved. Modify the registry at your own risk.

Queue Manager in Microsoft Message Queuing caches messages that are sent to a computer that is running Microsoft Message Queuing. Queue Manager removes any incoming messages that are duplicates of the messages in the cache. By default, this cache has a size of 10,000 messages and is cleaned up every 30 minutes. Any messages that are older than the cleanup interval are removed from the cache during the cleanup operation.

The cache is stored in memory and is reset if you restart the computer. Memory that the caching mechanism uses is very efficient because the cache contains only computer identifiers and message identifiers. The cache does not store the whole message.

You can change the cache size value and the cleanup interval value through the following registry settings:

  • HKEY_LOCAL_MACHINE\Software\Microsoft\MSMQ\Parameters\RemoveDuplicateSize: Specifies the cache size for removing duplicate messages. The default is 10,000 incoming messages.
  • HKEY_LOCAL_MACHINE\Software\Microsoft\MSMQ\Parameters\RemoveDuplicateCleanup: Specifies the cleanup interval for removing duplicate messages. The default time is 30 minutes.

By setting the RemoveDuplicateSize registry value to 0, you can disable the mechanism for removing duplicate messages.

Note This information reflects the current implementation of this mechanism. The implementation of this mechanism may be subject to change in later versions of Microsoft Message Queuing.

Additional query words: MSMQ Duplicate Message

Keywords: kbinfo KB255546