Contact Free trial Login

Oracle E-Business Suite 12.2 Connector - Mule 4

Support Category: Premium

Oracle EBS 12.2 Connector v2.1

Anypoint Connector for Oracle E-Business Suite 12.2 (EBS 12.2 Connector) facilitates connections between Mule runtime engine (Mule) integration and Oracle E-Business Suite 12.2 applications.

About the Connector Architecture

Oracle EBS offers different technologies or products to address various types of integrations. The most widely used integrations for enterprise applications are:

  • Data-centric integration

  • Integration through Web Services using Oracle E-Business Suite Integrated SOA Gateway (ISG)

The following illustration shows the integration architecture of the MuleSoft Oracle EBS connector:

Oracle EBS 12.2 - Connector Architecture

Prerequisites

To use this connector, you must:

  • Be familiar with Oracle E-Business Suite, Anypoint Connectors, Anypoint Studio, Mule concepts, elements in a Mule flow, and global elements

  • Have Oracle EBS login credentials to test your connection to your target resource

For software requirements and compatibility information, see the Connector Release Notes.

POM File Information

<dependency>
  <groupId>com.mulesoft.connectors</groupId>
  <artifactId>mule-oracle-ebs-122-connector</artifactId>
  <version>RELEASE</version>
  <classifier>mule-plugin</classifier>
</dependency>

Mule converts RELEASE to the latest version. To specify a version, go to Oracle EBS 12.2 Connector in Anypoint Exchange and click Dependency Snippets.

Configure the Input Source Trigger in Design Center

You can use the connector as a trigger, or you can use HTTP Listener or Scheduler as a trigger.

Use the Connector as a Trigger

You can create a global element by using the connector as the trigger.

  1. In Design Center, click Create.

  2. Click Create new application to open Flow Designer.

  3. Specify a value for Project name, and click Create.

  4. Click Go straight to canvas to exit from Let’s get started.

  5. Click the trigger card.

  6. Search for the connector.

  7. Complete these fields for the connector:

    Field Description

    Name

    The name for this configuration. Connectors reference the configuration with this name.

    Connection

    The connection types to provide to this configuration

    Read Receive Timeout

    30000 by default

Use HTTP Listener as a Trigger

  1. Click the trigger card.

  2. Search for HTTP Listener.

  3. In the General tab, enter the relative path from the path set in the HTTP Listener configuration.

  4. Click Edit.

  5. In HTTP Listener Configuration, enter the configuration name and base path (where your Mule application listens for requests) for the HTTP Listener, then click Add connection.

  6. Enter the connection name and select the connection type.

  7. In Configure Connection, specify the values for the HTTP connection:

    HTTP Listener configuration
    Field Description

    Protocol

    HTTP or HTTPS protocol selected for the HTTP endpoint

    Host

    IP address where your Mule application listens for requests

    Port

    Port address where your Mule application listens for requests

  8. Click Save.

  9. Click the plus sign to add a component.

    50%
  10. Select the connector as a component.

  11. Configure the global element for the connector:

    config connector
    Field Description

    Host

    Host of the Oracle EBS instance

    Port

    Port of the Oracle EBS Web Services

    SSL enabled

    If checked, Web Services calls are attempted using HTTPS instead of HTTP

    Username

    Name to use to log in to Oracle EBS Web Services

    Password

    Password for the username

    Rest Service Locator alias

    Name assigned to the Web Service with Internal Name oracle.apps.fnd.rep.ws.service.EbsRestLocator when deployed

    FND Web Sec alias

    Name assigned to the PL/SQL Web Service with Internal Name FND_WEB_SEC when deployed

    Responsibility name

    Oracle EBS responsibility name that is needed to execute the operation. This field accepts responsibility_key.

    Responsibility application name

    Application short name that is needed to execute the operation

    Security group name

    (Optional) Security group key of the Oracle EBS instance (STANDARD by default)

    NLS language

    (Optional) NLS language of the Oracle EBS instance (AMERICAN by default)

    Org. ID

    (Optional) The organization ID of the Oracle EBS instance

  12. Choose the operation.

    connector Operation
    • PL/SQL
      Configure the WADL.

    • Operation
      Configure the operation.

  13. Click Test to test the connection.

Add the Connector to a Studio Project

Anypoint Studio provides two ways to add the connector to your Studio project:

  • From the Exchange button in the Studio taskbar

  • From the Mule Palette view

Add the Connector Using Exchange

  1. In Studio, create a Mule project.

  2. Click the Exchange icon (X) in the upper-left of the Studio task bar.

  3. In Exchange, click Login and supply your Anypoint Platform username and password.

  4. In Exchange, search for "ebs".

  5. Select the connector and click Add to project.

  6. Follow the prompts to install the connector.

Add the Connector in Studio

  1. In Studio, create a Mule project.

  2. In the Mule Palette view, click (X) Search in Exchange.

  3. In Add Modules to Project, type "ebs" in the search field.

  4. Click this connector’s name in Available modules.

  5. Click Add.

  6. Click Finish.

To Use the Connector

  1. Deploy the REST Service location so that you can later expose your PL/SQL services for the connector to consume. See the Oracle Developer’s Guide Tutorial link in the See Also section.

    The following steps describe the procedure to deploy the PL/SQL Adjustment API as a REST service. The same guide applies to any PL/SQL.

  2. Log in to the Oracle E-Business Suite as a user who has the Integration Administrator role.

  3. Select the Integrated SOA Gateway responsibility and the Integration Repository link from the navigation menu.

  4. In the Integration Repository tab, click Search to access the main Search page.

  5. Click Show More Search Options to display more search fields.

  6. Enter the following key search values as the search criteria:

    • Category: Interface Subtype

    • Category Value: PL/SQL

    • Internal Name: FA_ADJUSTMENT_PUB

      Deploy PL/SQL - Search
  7. Click Go to execute the search.

  8. Click the Adjustments API link to see the interface details.

    Deploy PL/SQL - Adjustment API
  9. Click the REST Service Locator interface name link to open the interface details page.

  10. In the REST Web Service tab, enter the following information:

    Deploy PL/SQL - Adjustment API Configuration

    Important: The alias of the deployed Web Service MUST be:
    1) The internal name.
    2) In lowercase. The alias information can be found under the Service Alias label. In this example, it is fa_adjustment_pub.

  11. Click Deploy to deploy the service to an Oracle E-Business Suite WebLogic environment.

    After the REST service successfully deploys, Deployed appears in the REST Service Status field along with the View WADL link.

  12. Click the View WADL link to view the deployed service WADL description.

    Deploy PL/SQL - Adjustment API Deployed

To Configure in Studio

  1. Drag a connector operation to the Anypoint Studio canvas.

  2. Configure the Global element for the connector.

    config connector
    Field Description

    Host

    Host of the Oracle EBS instance

    Port

    Port of the Oracle EBS Web Services

    SSL enabled

    If checked, the connector makes Web Services calls using HTTPS instead of HTTP

    Username

    Username to log in to Oracle EBS Web Services

    Password

    Password for the username

    Rest Service Locator alias

    Name assigned to the Web Service with the internal name oracle.apps.fnd.rep.ws.service.EbsRestLocator when deployed

    FND Web Sec alias

    Name assigned to the PL/SQL Web Service with the internal name FND_WEB_SEC when deployed

    Responsibility name

    Oracle EBS responsibility name that is needed to execute the operation. This field accepts responsibility_key.

    Responsibility application name

    Application short name that is needed to execute the operation

    Security group name

    (Optional) Security group key of the Oracle EBS instance (STANDARD by default)

    NLS language

    (Optional) NLS language of the Oracle EBS instance (AMERICAN by default)

    Org. ID

    (Optional) Organization ID of the Oracle EBS instance

Log Requests and Responses

To log requests and responses when using the connector, configure a logger by adding this line to the Loggers element of the log4j2.xml configuration file for the Mule app:

<AsyncLogger name="name="org.mule.service.http.impl.service.HttpMessageLogger" level="DEBUG"/>

The following example shows the Loggers element with the AsyncLogger line added:

<?xml version="1.0" encoding="UTF-8"?>
<Configuration status="WARN">
	<Appenders>
	    <Console name="Console" target="SYSTEM_OUT">
	    	<PatternLayout pattern="%d{HH:mm:ss.SSS} [%t] %-5level %logger{36} - %msg%n"/>
		</Console>
	</Appenders>
	<Loggers>
		<AsyncLogger name="org.mule.service.http.impl.service.HttpMessageLogger" level="DEBUG" additivity="false">
			<appender-ref ref="Console" level="debug"/>
		</AsyncLogger>
	</Loggers>
</Configuration>

You can view the app log in the following ways:

  • If you’re running the app from the Anypoint Platform, the output is visible in the Anypoint Studio console window.

  • If you’re running the app using Mule from the command line:

    • The app log is visible in your OS console.

    • Unless the log file path was customized in the app’s log file (log4j2.xml), you can also view the app log in this default location:

MULE_HOME/logs/<app-name>.log

For more information about the app log, see Configuring Logging.

Use Case: Create an Oracle EBS 12.2 Global Element

Follow the steps below to create an Oracle EBS 12.2 global element for Web Services and PL/SQL invocation:

flow example
  1. Create a new Mule Project in Studio and select an HTTP Listener as a source in the new flow.

  2. Add a new HTTP Listener global element configuration.

    1. Specify the Host and Port parameters with the following values:

      Parameter Value

      Host

      0.0.0.0

      Port

      8081

    2. Click Save.

  3. Assign the new global configuration to your HTTP Listener.

  4. Specify the HTTP Listener path as the /start value.

  5. Drag a Transform Message element and add it the following code:

    %dw 2.0
    output application/xml
    ns ns0 http://xmlns.oracle.com/apps/per/rest/hr_location_api/create_location/
    ---
    {
      ns0#InputParameters: {
        ns0#P_VALIDATE: 0,
        ns0#P_EFFECTIVE_DATE: now,
        ns0#P_LOCATION_CODE: "HR- MuleSoft Office",
        ns0#P_DESCRIPTION: "Description Office"
      }
    }
  6. Drag a new Oracle E-Business Suite 12.2 component into the flow.

  7. In the General tab, configure the Oracle E-Business Suite 12.2 connector global element with its environment values.

  8. In the properties editor of Oracle E-Business Suite 12.2 connector, set PL/SQL to hr_location_api and Operation to CREATE_LOCATION:

    Oracle Create Location
  9. Copy the following content under the Message > Body section:

    #[payload]
  10. Save and run the project as a Mule application.

  11. Navigate to http://127.0.0.1:8081/start to test the application.

Use Case: XML

<?xml version="1.0" encoding="UTF-8"?>

<mule xmlns:oracle-ebs122="http://www.mulesoft.org/schema/mule/oracle-ebs122"
xmlns:ee="http://www.mulesoft.org/schema/mule/ee/core"
xmlns:http="http://www.mulesoft.org/schema/mule/http"
xmlns="http://www.mulesoft.org/schema/mule/core"
xmlns:doc="http://www.mulesoft.org/schema/mule/documentation"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.mulesoft.org/schema/mule/core
http://www.mulesoft.org/schema/mule/core/current/mule.xsd
http://www.mulesoft.org/schema/mule/http
http://www.mulesoft.org/schema/mule/http/current/mule-http.xsd
http://www.mulesoft.org/schema/mule/ee/core
http://www.mulesoft.org/schema/mule/ee/core/current/mule-ee.xsd
http://www.mulesoft.org/schema/mule/oracle-ebs122
http://www.mulesoft.org/schema/mule/oracle-ebs122/current/mule-oracle-ebs122.xsd">
		<configuration-properties file="mule-app.properties"/>

	<http:listener-config name="HTTP_Listener_config" doc:name="HTTP Listener config" basePath="/" >
		<http:listener-connection host="0.0.0.0" port="8081" />
	</http:listener-config>
	<oracle-ebs122:config name="Oracle_ebs122_Config" doc:name="Oracle-ebs122 Config" >
		<oracle-ebs122:plsql-connection host="${config.host}"
		port="${config.port}" username="${config.username}"
		password="${config.password}"
		restServiceLocatorAlias="${config.restServiceLocatorAlias}"
		fndWebSecAlias="${config.fndWebSecAlias}"
		responsibility="${config.responsibility}"
		respApplication="${config.respApplication}"
		securityGroup="${config.securityGroup}"
		nlsLanguage="${config.nlsLanguage}"
		orgId="${config.orgId}"/>
	</oracle-ebs122:config>
	<flow name="oracle-ebs122Flow">
		<http:listener doc:name="Listener" config-ref="HTTP_Listener_config"
		path=“/start”/>
		<ee:transform doc:name="Transform Message" >
			<ee:message >
				<ee:set-payload ><![CDATA[%dw 2.0
output application/xml
ns ns0 http://xmlns.oracle.com/apps/per/rest/hr_location_api/create_location/
---
{
	ns0#InputParameters: {
		ns0#P_VALIDATE: 0,
		ns0#P_EFFECTIVE_DATE: now,
		ns0#P_LOCATION_CODE: "HR- MuleSoft BA",
		ns0#P_DESCRIPTION: "Buenos Aires Office"
	}
}]]></ee:set-payload>
			</ee:message>
			<ee:variables >
				<ee:set-variable variableName="payload" ><![CDATA[%dw 2.0
output application/xml
ns ns0 http://xmlns.oracle.com/apps/per/rest/hr_location_api/create_location/
---
{
	    ns0#InputParameters: {
        ns0#P_VALIDATE: 0,
        ns0#P_EFFECTIVE_DATE: now,
        ns0#P_LOCATION_CODE: 'LocCode001’,
        ns0#P_DESCRIPTION: 'Location 001’
    }
}]]></ee:set-variable>
			</ee:variables>
		</ee:transform>
		<oracle-ebs122:invoke-pl-sql-rest-service
		doc:name="Invoke PL/SQL REST Service"
		config-ref="Oracle_ebs122_Config"
		operation="CREATE_LOCATION" plSql="hr_location_api">
			<oracle-ebs122:input ><![CDATA[#[payload]]]></oracle-ebs122:input>
		</oracle-ebs122:invoke-pl-sql-rest-service>
	</flow>
</mule>