The new syntax for calling a function module for background processing (previously done using IN BACKGROUND TASK) is as follows:
CALL FUNCTION 'function_name'
IN BACKGROUND UNIT unit
Where unit points to an object of the type IF_BGRFC_UNIT. This object contains all the information that is needed to run the function module in the background. This information includes, for example, the execution destination, the difference between the bgRFC type t or bgRFC type q, and possibly the number of queues into which the unit is to be placed. If the same unit object is used with multiple function module calls, then all these function modules are executed in one unit. In this way, it is possible to use multiple unit objects in parallel within a single application LUW. Consequently, multiple background units can be created in parallel within an application LUW. In the previous version, this was possible using the AS SEPARATE Unit addition. The advantage of the new solution is that multiple background units can accept multiple function modules.
In the event of an invalid unit object, the exception CX_BGRFC_INVALID_UNIT is raised.