IBM BPM, V8.0.1, All platforms > Authoring services in Integration Designer > Services and service-related functions > Access external services with adapters > Configure and using adapters > IBM WebSphere Adapters > SAP Software > SAP interfaces > BAPI interfaces

Coordinating BAPI transactions and passing values between BAPI invocations

The transaction capability of IBM BPM or WebSphere Enterprise Service Bus can be used in a scenario where multiple BAPI requests are to be executed in an atomic fashion.

You can use the built-in transaction capabilities of IBM BPM or WebSphere Enterprise Service Bus in scenarios where chained BAPI invocation requests are to be executed in an atomic fashion.

To coordinate several BAPI requests, the various adapter outbound operations need to be joined in a transaction. To do this, set the Join Transaction Quality Of Service Qualifier value to True for the appropriate interfaces.

Figure 1. Join transaction Quality of Service Qualifier

The outbound calls can be made from either a Java component or a Mediation module. Once the interfaces are joined in a transaction, set the value of the Transaction Quality of Service Qualifier to Global for the appropriate Java component or Mediation module implementation in IBM Integration Designer. With this setting, IBM BPM or WebSphere Enterprise Service Bus ensures that all the BAPI calls execute successfully or all of them fail.

The whole transaction is committed after all the BAPI executions complete successfully. Any exceptions raised during the execution of the BAPIs will result in a rollback of all changes made by the previous requests.

Figure 2. Transaction Quality of Service Qualifier

In order to achieve chaining of BAPIs in sequence (output of one BAPI becomes the input of the other), you can use the Interface and Data mapping features available in IBM BPM or WebSphere Enterprise Service Bus.

You can find the transaction qualifiers for setting the Join transaction and Global transaction in the Qualifiers tab in Details section of the properties.

The BAPI interfaces