The transactional behavior of tRFC is enhanced by a serialization mechanism with qRFC. This mechanism can be realized using an outbound queue or an outbound and additional inbound queue.
The following programming example shows qRFC communication with an outbound queue (optional parameters are shown in blue):
qRFC Outbound Queue
report rstrfct0. ...
call function ‘TRFC_SET_QUEUE_NAME’. EXPORTING QNAME = ‘queue1’ * NOSEND = ' ' * TRFC_IF_SYSFAIL = ' ' * CALL_EVENT = ' ' * EXCEPTIONS * INVALID_QUEUE_NAME = 1 * OTHERS = 2 . call function ’rfc_function’ destination rfcdest in background task ( as separate unit ) exporting ... tables ...
...
commit work.
|
1. You can set the queue name for the outbound queue by calling one of the following function modules:
○ TRFC_SET_QUEUE_NAME
○ TRFC_SET_QUEUE_NAME_LIST (for multiple queue assignments for each qRFC call)
○ TRFC_SET_QUEUE_RECEIVER_LIST (for multiple destinations for each qRFC call)
2. Call tRFC (Call Function … in Background Task)
The qRFC Manager creates a counter for the LUW when the Commit Workis executed.
Serialization is done by a Queue Identifier. This Queue Identifier is made up of the Client, Queue Name, Destination and Queue Counter parameters.
For detailed information on programming the outbound queue, see: