SAP AIF 3.0
SAP AIF with release 3.0 has got many new features and one of them is a much tighter integration with SAP rule engine : BRFPlus/DSM. In this video presentation you can find out why it’s worth using AIF together with BRFPlus/DSM: SAP Application Interface Framework with SAP NetWeaver Decision Service Management.
BRFplus and AIF
The main topic of this article will be to show how quickly and easily can a BRFPlus rule be used in the AIF value mapping from the development point of view. For a start we need to design a BRFPlus function which can later be used within AIF. There are however two important things to be considered here:
- if you’re building a new BRFPlus function together with a new BRFPlus expression (for example a decision table) you can try building it according to the AIF requirements (for input parameters). This basically means that the BRFPlus function can be used in the “Functional mode” with just one top expression (for example : decision table) which has the same input/output parameters
- if the BRFPlus expression is already developed you have to develop a BRFPlus function according to the AIF requirements (for input parameters) but you may need to go for a function with “Event mode” so you can map the AIF required input and output parameters to the existing expression within the BRFPlus Ruleset (assigned to the function)
In this article we will only concentrate on the first approach (so both the BRFPlus function and expression are new). The first step would be to create a BRFPlus function with required input parameters which need to can have names listed as per the figure below which would correspond to the fields (Field1-Field5) from the AIF structure mapping later on. The output value does not need to have any specific name.
Next we need to prepare the BRFPlus expression (for example decision table) which will be used in the scenario and assign it to the BRFPlus function. It would be wise to test the function from the BRFPlus workbench to see it working using the start simulation button.
The rest of the customizing steps can be done within AIF and we need to start by defining a new value mapping where we need to select which BRFPlus application and function we will be using as shown in the figure below.
In order to use the new value mapping you need to add it in the AIF structure mapping keeping in mind that selected source fields will be used by the BRFPlus function exactly as shown in figure below.
After all of the mentioned steps are done you can try and test the end to end scenario and if you did everything as explained the value from the AIF interface should get mapped using the BRFPlus.
BRFPlus can also be used in AIF structure mapping and AIF checks and not only with AIF value mapping.
Michał Krawczyk – SAP integration consultant since 2004. He has been recognized by SAP included becoming an SAP Mentor in 2007 and winning the top contributor/topic leader award from SDN (SAP Developer Network portal) in SAP PO/PI eight times. Michal is the author many SAP integration related books.