Delen via


MSMQMessage.Delivery

 

Applies To: Windows 10, Windows 7, Windows 8, Windows 8.1, Windows Server 2008, Windows Server 2008 R2, Windows Server 2012, Windows Server 2012 R2, Windows Server Technical Preview, Windows Vista

The Delivery property of the MSMQMessage object specifies how Message Queuing delivers the message.

Data type: Long
Run-time access: Read/write
Property Delivery As Long  

Property Value

The Delivery property can have one of the following values:

MQMSG_DELIVERY_RECOVERABLE

In every hop along its route, the message is stored locally on disk until it is forwarded to the next computer. This guarantees delivery even in the case of a computer crash. When the message is placed in the destination queue, it is written to disk in a memory-mapped file.

MQMSG_DELIVERY_EXPRESS

The default. The message stays in volatile memory along its entire route until it is received. The message is not recovered if the computer where the message resides is rebooted. An express message delivered to a queue on a virtual server in a cluster will be lost if the virtual server fails over before the message is received.

Remarks

The Delivery property is used to specify express or recoverable messaging. Express messaging provides faster throughput. Recoverable messaging guarantees that the message will be delivered even if a computer crashes while the message is en route to the queue. For a comparison of express and recoverable messaging, see Express and Recoverable Messaging.

Message Queuing always sets the delivery mechanism of transactional messages to MQMSG_DELIVERY_RECOVERABLE. For information on transactions, see Transactions.

Equivalent API Function Property

With API function calls, the equivalent property is PROPID_M_DELIVERY.

Requirements

Windows NT/2000/XP: Included in Windows NT 4.0 SP3 and later.

Windows 95/98/Me: Included in Windows 95 and later.

Header: Declared in Mqoai.h.

Library: Use Mqoa.lib.

See Also

MSMQMessage
PROPID_M_DELIVERY