Communication between applications of different systems in the SAP environment includes connections between SAP systems as well as between SAP systems and non SAP systems. Remote Function Call (RFC) is the standard SAP interface for communication between SAP systems. RFC calls a function to be executed in a remote system.
There is now a whole series of different RFC variants, each of which has different properties and is used for a specific purpose.
RFC Variants are:
Synchronous RFC (sRFC)
Asynchronous RFC (aRFC)
The main characteristics of aRFC are as follows:
Using aRFC is always a good idea when real-time communication is established with a remote system, where processing in the calling program should not be interrupted until the results of the called function module have been obtained (the term asynchronous is used in this sense here).
Transactional RFC (sRFC)
tRFC is always used if a function is executed as a Logical Unit of Work (LUW). Within a LUW, all calls are:
Implementation of tRFC is recommended if you want to maintain the transactional sequence of the calls.
Disadvantages of tRFC
tRFC processes all LUWs independently of one another. Due to the amount of activated tRFC processes, this procedure can reduce performance significantly in both the send and the target systems.
In addition, the sequence of LUWs defined in the application cannot be kept. It is therefore impossible to guarantee that the transactions will be executed in the sequence dictated by the application. The only thing that can be guaranteed is that all LUWs are transferred sooner or later.
Queued RFC (qRFC)
Background RFC (bgRFC)
With the bgRFC, therefore, the asynchronicities between the caller and the called application can result in the following advantages:
The bgRFC organizes the different calls using queues. A call that is placed in several queues at the same time creates a dependency between these queues. This leads to a synchronization point, which is similar to a lock.
The dependent queues can be processed until the entry for processing is at the head of the queue that defines the dependency. This entry can only then be processed if it is at the head of all the queues.