An Example of Using a Java REST Service as an Invoke (Target) Connection in an Integration

Sample Business Scenario

An Application Module Service, a subtype of Java interface, called "Self-Service HR” is used to explain how to obtain available absence details from Oracle E-Business Suite through the invocation of a Java REST service.

In this example, the REST Adapter is used as a trigger (source) connection and the Oracle E-Business Suite Adapter is used as invoke (target) connections to invoke the “Get Person Absence Type Balances” (getPersonAbsenceBalanceDtls) REST service operation contained in the “Self-Service HR” Java API.

At runtime when the integration is triggered, the Oracle E-Business Suite Adapter receives a request with input payload from the trigger (source) connection, invokes the getPersonAbsenceBalanceDtls REST service operation to obtain data. Once the integration is executed and completed successfully, the available person absence data is retrieved and returned as part of the JSON response message.

Prerequisites:

Before creating the integration in Oracle Integration, you need to ensure the following tasks are in place:

  • The "Self-Service HR” is deployed as a REST service with alias sshr. All included service operations are selected and deployed as REST service operations.


    Description of javarest.gif follows
    Description of the illustration javarest.gif

    Record the following REST service endpoint from the WADL:

    https://<host>:<port>/webservices/rest/<alias>/getPersonAbsenceBalanceDtls/

    Replace <alias> with sshr in this example. You will use this service endpoint later when you create a REST connection in Oracle Integration.

  • Security grants are created for the bpalmer user.

Based on the integration scenario, the sample tasks for using an Oracle E-Business Suite Java REST service in an integration are included in the Topics section:

Topics:

  1. Establish the Connections for Oracle E-Business Suite and REST Services

  2. Create an Integration

  3. Add the REST Adapter as a Trigger (Source) Connection

  4. Add the Oracle E-Business Suite Adapter as an Invoke (Target) Connection

  5. Create Mappings

  6. Assign Business Identifier for Tracking

  7. Activate and Test the Integration