123.8. Example 1: Reading Data from SAP

Overview

This example demonstrates a route which reads FlightCustomer business object data from SAP. The route invokes the FlightCustomer BAPI method, BAPI_FLCUST_GETLIST, using an SAP synchronous RFC destination endpoint to retrieve the data.

createFlightCustomerGetListRequest bean

The createFlightCustomerGetListRequest bean is responsible for building an SAP request object in its exchange method that is used in the RFC call of the subsequent SAP endpoint . The following code snippet demonstrates the sequence of operations to build the request object:

returnFlightCustomerInfo bean

The returnFlightCustomerInfo bean is responsible for extracting data from the SAP response object in its exchange method that it receives from the previous SAP endpoint . The following code snippet demonstrates the sequence of operations to extract the data from the response object: