Mentor SAP

Proxy Interfaces

 

As a prerequisite to creating an AIF interface for an inbound proxy, you need a service interface. The service interface is created in the ESR or MDR and is usually not the task of the AIF interface developer.

 

For this service interface, an inbound proxy class has to be generated in the back end system.

Another prerequisite is the destination structure. You have to create this structure. What the structure should look like depends on the BAPIs, function modules, and so on that should be called in the AIF action.

 

After the generation of the proxy, you have to implement it. You have to implement the proxy's method. Since you use AIF, the only thing you have to do is call AIF by calling /AIF/CL_ENABLER_PROXY=>PROCESS_MESSAGE. You have to pass the proxy method's input structure as well as the exception class' name.

 

An AIF interface has to be created. You have to specify the name of your inbound proxy class; the raw structure and the record type should then be inserted automatically. Furthermore, you have to specify the SAP structure (destination structure). The engines used for inbound proxy messages are the default ones, therefore, you do not have to change anything here.

 

The rest of the implementation can then be done in AIF Customizing. You can create structure mappings, value mappings, actions, and so on as for any other AIF interface.

 

 

As a prerequisite to creating an AIF interface for an outbound proxy, you need a service interface. The service interface is created in the ESR or MDR and is usually not the task of the AIF interface developer.

 

For this service interface, an outbound proxy class has to be generated in the back end system.

 

Another prerequisite is the source structure. You have to create this structure. What the structure should look like depends on the data that is available at the triggering place and that needs to be passed to AIF. You should consider that you do not have to pass all data that you want to be sent out to AIF; instead, you can derive the data from other fields within mapping in AIF.

 

Create an AIF interface. You have to specify the name of the outbound proxy class and the record type should then be inserted automatically. Furthermore, you have to specify the SAP structure (source structure).

 

AIF always displays the source data in Monitoring and Error Handling. However, this data is not usually stored anywhere for outbound proxy interfaces. Therefore, we use AIF's own persistence and runtime in order to enable the display of data and reprocessing and canceling of messages. Set the application and persistence engines to XML.

 

The rest of the implementation can then be done in AIF Customizing. You can create structure mappings, value mappings, actions, and so on as for any other AIF interface.

 

Furthermore, you have to create a report, function module, and so on, which trigger the sending of the message. Pass the necessary data to the interfaces source structure and call the /AIF/SEND_WITH_PROXY function module. Make sure to pass the correct namespace, interface name, and version to the function module. Furthermore, you have to pass the source data.

 

If you process a message, you are able to see the source structure content in Monitoring and Error Handling. Furthermore, you can do error handling, restart or cancel a message if it ran into an error in AIF.

 

The monitoring of inbound proxies that are synchronous makes it possible for you to see if proxies were called. The standard proxy runtime does not keep track of synchronous calls.