3.2.4.10.1 Receive a Message by Using a Cursor Without a Transaction

  • The client MUST call the R_StartReceive (Opnum 7) (section 3.1.4.7) method and MUST specify the following parameter values:

    • phContext set to a QUEUE_CONTEXT_HANDLE_NOSERIALIZE (section 2.2.4.1) handle that has been returned by the server in the pphQueue output parameter of a prior call to the R_OpenQueue (Opnum 2) (section 3.1.4.2) method and that MUST NOT have been previously closed through a call to the R_CloseQueue (Opnum 3) (section 3.1.4.3) method. This value MUST NOT be NULL.

    • hCursor set to the value specified by the message queuing application.

    • ulAction set to the value specified by the message queuing application.

    • ulTimeout set to the time-out value.

    • dwMaxBodySize set to the value specified by the message queuing application.

    • dwRequestId set to a value that uniquely identifies this call from all other pending calls to this protocol.

    • LookupId set to 0x0000000000000000.

  • The client MUST reconstruct the message from the SectionBuffers (section 2.2.6) received in the ppPacketSections parameter, as specified in section 3.1.4.7.

  • The client MUST advise the server that the message was received by the message queuing application by calling the R_EndReceive (Opnum 9) (section 3.1.4.9) method with:

    • The same phContext parameter as in the call to the R_StartReceive method.

    • The same dwRequestId parameter as in the call to the R_StartReceive method.

  • If MQ_OK (0x00000000) is returned:

    • The client MUST return the reconstructed message to the message queuing application.

  • Else if the return value is not MQ_OK

    • The client MAY<35> return MQ_OK to the message queuing application.