Share via


MSMQMessage.Delivery (Compact 2013)

3/26/2014

This property specifies how Message Queuing delivers the message.

Syntax

HRESULT get_Delivery( 
  long* plDelivery 
);
HRESULT put_Delivery( 
  long lDelivery 
);

Parameters

  • plDelivery or lDelivery
    Value that specifies how Message Queuing delivers the message. The following table shows the possible values.

    Value

    Description

    MQMSG_DELIVERY_RECOVERABLE

    In every hop along its route, the message is forwarded to the next hop or stored locally in a backup file until delivered.

    This guarantees delivery even in the case of a computer crash.

    MQMSG_DELIVERY_EXPRESS

    The default. The message stays in memory until it can be delivered.

Return Value

The following table describes the common return values.

Value

Description

S_OK

Success

E_INVALIDARG

One or more arguments are invalid

E_NOTIMPL

The function contains no implementation

E_OUTOFMEMORY

Out of memory

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.

Message Queuing always sets the delivery mechanism of transactional messages to MQMSG_DELIVERY_RECOVERABLE.

Equivalent Function Property

When using function calls, the delivery type can be set and retrieved using the PROPID_M_DELIVERY message property.

Requirements

Header

mqoai.h

Library

mqoa.lib

See Also

Reference

MSMQMessage
PROPID_M_DELIVERY