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 > Configure the module for deployment > Configure the module for outbound processing > Configure a module for the BAPI interface

Configure simple BAPI objects

To configure simple BAPI business objects, you specify information about the object (such as the name of the object and the operation associated with the object). If you are using the version of the adapter with transaction support, you also select the type of remote function call you want to make (Synchronous RFC, Asynchronous transactional RFC, or Asynchronous queued RFC).

If you want to use the Asynchronous Transactional RFC or Asynchronous Queued RFC choice, you must have installed IBM WebSphere Adapter for SAP Software with transaction support (CWYAP_SAPAdapter_Tx).

If you are sending the function call to a queue on the SAP server (so that an application on SAP server can process the BAPIs SAP server in order), make sure you have configured the queue on the SAP server.

To configure the business object, use the following procedure.


Procedure

For BAPI outbound processing, when you select the Generate business objects in SAP XI standard option in the Specify Discovery Properties window, the Generate BAPI business objects within a wrapper and Business object namespace options will not be displayed in the Specify Composite Properties window. The adapter will use the SAP XI standard business namespace in this case. Hence, go to Step 4.

  1. In the Configure Composite Properties window, select a name for the top-level business object.

  2. If you do not select the Generate BAPIs within Wrappers check box, top-level business objects are automatically generated for each BAPI selected. For each top-level business object generated, the adapter internally assigns the Execute operation to it. There is no limit on the number of BAPI's that you can configure.

    If you select the Generate BAPIs within Wrappers check box, top-level business objects are generated that contain a child business object for each BAPI selected. You can configure a maximum number of four BAPI's.

    Perform one of the following sets of tasks if you have selected Generate BAPIs within Wrappers check box:

    • If you are working with a single BAPI, click Add, select an operation (for example, Retrieve), and click OK.

      You can select only one operation per BAPI.

    • If you are working with multiple BAPIs, select, for each operation, the BAPI you want associated with that operation, as described in the following steps:

      1. Click Add, select the operation (for example, Create) from the list, and click OK.

      2. From the RFC function for selected operation list, select a BAPI to associate with the operation you selected in the previous step.

      3. For the second BAPI, click Add, select an operation (for example, Retrieve) from the list, and click OK.

      4. From the RFC function for selected operation list, select a BAPI to associate with the operation you selected in the previous step.

      5. For any subsequent BAPIs, repeat the previous two steps.

      You can select only one operation per BAPI.

  3. In the Business object namespace field, use the default namespace (http://www.ibm.com/xmlns/prod/websphere/j2ca/sap) except in the following circumstance. If you are adding the business object to an existing module and the module already includes that business object (from an earlier run of the external service wizard), change the namespace value.

    For example, you could change the namespace to http://www.ibm.com/xmlns/prod/websphere/j2ca/sap1.

  4. To indicate where the business object information should be stored, type the path to the location in the Folder field. This is an optional step.

    This field cannot be edited if you are modifying existing artifacts.

    If you are creating multiple adapter artifacts within a module, ensure that you specify different business object folders for each adapter within the module.

    For example, if you are creating artifacts for Oracle, JDBC, SAP, and JDE within a module, you need to create different relative folders for each of these adapters. If you do not specify different relative folders, the existing artifacts are overwritten when you generate new artifacts.

  5. If you want the BAPI or BAPIs to be enclosed within a business graph, leave Generate a business graph for each business object selected. Otherwise, remove the check.

  6. If you are using the version of the adapter with transaction support, you can select the type of remote function call you want to make.

    If you are using the version of the adapter without transaction support (CWYAP_SAPAdapter), this step does not apply. The BAPI or BAPIs are sent synchronously. Skip ahead to step 7

    If you are using the version of the adapter with transaction support (CWYAP_SAPAdapter_Tx) but do not select a type of remote function call, the default (Synchronous RFC) is used. In Synchronous RFC, the adapter calls the BAPI and then waits for the response from the SAP server.

    1. Select the arrow next to the SAP Remote Function Call (RFC) type list.

    2. Select one of the RFC types:

      • Select Synchronous RFC (the default) if you want the BAPI sent in a synchronous manner (the adapter calls the BAPI and then waits for the response from the SAP server). If that the receiving system must be available when you use Synchronous RFC.

      • Select Asynchronous Transactional RFC if you want the call to succeed regardless of whether the receiving system (the SAP server) is available.

        • If the event is successful, the adapter sends the transaction ID to the client.

        • If the event fails, the adapter returns an AbapException with the transaction ID to the adapter client. The adapter client can use this transaction ID to make the call again at a later time.

        When you use Asynchronous Transactional RFC, no data is returned to the client from the adapter.

      • Select Asynchronous Queued RFC if you want the BAPI or BAPIs delivered to a predefined queue on the SAP server. After you selectAsynchronous Queued RFC, select, from the list, the specific queue on the SAP server to which the BAPI or BAPIs will be delivered.

        If no queues exist on the SAP server, you can type the name of a queue. You can then create the queue on the SAP server after configuration.

        If you do not select a queue, the adapter will configure the object to use the Asynchronous Transactional RFC type.

  7. If you want to continue to process a BAPI even if the BAPI return object contains errors, select the Ignore errors in BAPI Return object check box.

    If you selected Asynchronous Transactional RFC or Asynchronous Queued RFC, this check box is not available.

  8. To enable the adapter to wait until all time critical updates to SAP database are completed before calling commit on it, select the Wait until commit call to SAP database is completed and returned check box. This option is only available if you are using the CWYAP_SAPAdapter.rar.

  9. Click Finish.


Results

You specified a name for the top-level business object, selected an operation for the BAPI or BAPIs, and indicated the type of remote function call. The Service Generation and Deployment Configuration window is displayed.


What to do next

Generate a deployable module that includes the adapter and the business objects.

Configure a module for the BAPI interface


Next topic: Setting deployment properties and generating the service