Important:
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.
A version of this page is also available for
4/8/2010

Message Queuing provides a single-message transaction that implicitly uses the internal transaction support provided by Message Queuing.

The benefits of this type of transaction include the following:

  • Greater speed, compared to using an external transaction coordinator.

  • Simplified application code.

  • Exactly once delivery without the need to coordinate other activities within a single transaction.

The only difference between sending a non-transactional message and using a single-message transaction is that the destination queue must be a transactional queue, and the Transaction parameter of MSMQMessage.Send must be set to MQ_SINGLE_MESSAGE.

Note:
Each Message Queuing message can have no more than 4 MB of data.
To send a single-message transaction
  1. Declare the objects needed to send a message.

    This example uses a MSMQQueueInfo, MSMQQueue, and MSMQMessageobject.

  2. Call MSMQQueueInfo.Opento open the transactional queue with send access.

  3. Call MSMQMessage.Sendto send the message.

    In this example, the Transactionparameter is set to MQ_SINGLE_MESSAGE.

  4. Call MSMQQueue.Closeto close the queue.

See Also

500 Internal Server Error

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator at webmaster@systemmanager.forsenergy.ru to inform them of the time this error occurred, and the actions you performed just before this error.

More information about this error may be available in the server error log.

Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.