Tuesday, November 26, 2019

OIC - Create an Integration (Rest to DB data fetch)

Designer⇾Integrations⇾Create
 Select Basic Routing Style
 Provide the Name, package and description
 Integrations canvas opened
Drag the created DB Trigger and invoke type connection in target
Steps to create DB trigger and invoke connection oic-create-db-connection
Provide the name and Run a SQL Statement option.
Provide your SQL query to fetch the department name from department id.
 Validate SQL Query
 Next
 Target is ready
Now drag and drop created trigger rest connection.
Steps to create trigger rest connection oic-create-trigger-type-rest-connection
 Provide the details
 Provide the input field details
 here i selected JSON sample as response
 Provide the response JSON part
 Next
 Source and Target is ready
 Now map the inbound flow

 Map the outbound flow


 Provide Tracking details


 Activate



 Take the endpoint and create a rest project in SOAPUI
 Add the input parameters
 Add Authorization
 Test

OIC - Create Trigger type Rest connection

Designer⇾Connections⇾Create
 Select REST Adapter
 Provide Name and Role as Trigger type
 Test it
 Rest Trigger is created.

OIC - Create a DB connection - Trigger and Invoke Role Type

Go to Designer⇾Connections⇾Create
 Select the Oracle Database adapter
 Provide the Name, Role and description.
 Click Configure Connectivity
 Provide DB connection details
 Click Configure security
 Provide DB User and password
 Click Configure Agent and select agent needed.

 Now Test
 Save and Close


Oracle Integration Cloud (OIC) - Introduction

Introduction:
  • Oracle Integration Cloud (OIC) and Integration Cloud Service (ICS) are iPaaS offerings from Oracle. 
  • ICS was released back in 2015 has now been superseded by OIC. Customers on ICS can choose to be on ICS or migrate to OIC to take advantage of new features and services built into OIC.
  • It offers a user-friendly web-based interface enabling 'Integrators' to quickly perform some basic mapping and integration between (cloud) applications. with a growing number of available cloud applications(not only from oracle), customers face the challenge of keeping these solutions in sync, a challenge in which Oracle ICS can help us out.
  • Data Exchange between Cloud and On-Premise or 3rd Party applications.
  • The product comes with over 60 adapters.These adapters cover Oracle and non-Oracle SAAS and On-Premise apps as well as technology adapters such as SOAP and REST.
Benefits of using OIC:
  • A unified platform to automate processes
  • Integrate and create applications
  • Analyze results
  • Use Pre-build integrations or design your own integrations
  • No coding required
  • Interactive dashboard for real time insight of process flows
  • Monitor errors and take corrective actions
  • Minimize human error by automating the flows.
OIC in relation to Oracle SOACS:

Oracle SOA offers the SOA Suite as a cloud Service(SOACS) for solving the same integration issues as OIC does.SO why  also offer OIC?
  • Oracle ICS is positioned for the 'LOB Developer'(Line of Business Developer). The developer who actually functionally knows the application's being integrated. 
  • The developer who does not necessarily understand SOAP/REST/XML and other integration related technologies but does understand the underlying business entities, and which ones should be integrated between applications. 

Services available in Oracle Integration cloud:

Create and Manage Integrations(Integrations)  >> ICS / OIC
Launch the design-time environment for integrations. Create and activate integrations, as well as their connections and orchestrations. work with look ups, packages, agents, and  adapters.

Build Automated Process Applications(Process Biulder) >> PCS
Launch the design-time environment for process applications. Create process applications from scratch or by using quick start apps. Model processes in the process editor, and create web forms and decisions. Perform design-time administration such as playing, testing and deploying applications.

Develop Web & Mobile Applications(Visual Builder) >> VBCS
Create and publish web and mobile applications.

Use cases:
SAAS to SAAS:
All cases created in Salesforce are being synchronized with ServiceNow as incidents.

SAAS to On-Premise:

Update of opportunities in Salesforce propagated to on-premise Order Management.

Aspects of OIC Integrations:

Connections:
  • Connections define information about the instances of each configuration you are integrating. 
  • OIC includes a set of predefined adapters, which are the types of applications on which you can base your connections such as Oracle Sales Cloud, Oracle Right Now and others.
  • A connection is defined as any endpoint(Source or target) that is implemented within  an integration flow. These connections are based on  defined adapters.Adapters allows for easy connectivity to applications. insulating  the developer from complexities  that can occur when  interacting  with an application. 
  • OIC includes different kind of adapters like Oracle adapters, Non Oracle adapters, Technology specific adapters and social networking adapters etc.
Integrations:

  • Integrations are the main ingredient of a oracle integration cloud. An integration includes at least a trigger(source) connection (for requests sent to Oracle Integration Cloud) and invoke (target) connection (for requests sent from OIC to the target) and fields mapping between those two connections.
  • Integrations are processes that utilize connections to implement a business process. Using drag and drop capabilities, an integration can easily be defined. The functions defined within the VETO(validate, Enrich, transform and operation) integration design pattern are available for implementation.
Prebuild Integrations:
Apart from developing your own integrations in Oracle ICS, one can also leverage integrations build by others.

Lookups:

  • Use lookups in your integrations to create reusable tables that map the different terms used to describe the same item across your applications.
  • A bit like DVMs in SOA Suite, can cross-reference values of the same attribute/element when mapping from one system to another.

Packages:
Packages allow for grouping of integrations,providing the abilities to import and export packages between environments.

Agents:
Agents are used to connecting to On-premise applications, For example, if you are using On-premise systems like ERP/SAP and also using Oracle OIC in the same implementation, you would have to use an agent to connect to the OIC application. Two types of ageents arw available:
  1. Connectivity agent
  2. Execution agent
Libraries:
Libraries is a file or a collection of multiple files bundled in a JAR containing JavaScript functions. Library is used within an Integration and is executed by a JavaScript engine on the server as a part of integration flow.
Adapters:
Use an adapter to connect to an application in your integration. Oracle adapters are ready to use and pre-built block of code for the specific technology. 

Basic Integration flow:

Integration Workflow


Integration patterns or styles:

App Driven Orchestration
Create an integration that uses an event or a business object to trigger the integration. For example, you create an integration with an Oracle RightNow Adapter as a trigger and an Oracle Engagement Cloud Adapter as an invoke. The Oracle RightNow Adapter subscribes to an event from the Oracle RightNow application to trigger the integration.
Orchestration integrations include features such as the following:

  • Switch activities to create multiple routing expressions.
  • For-each activities for looping over repeating elements.
  • Assign activities for assigning values to scalar variables.
  • Ad-hoc mappings on switch branches.
  • Callback activities (to end a process and respond back to the sender) and end activities (to end a process without responding back to the sender) in asynchronous integrations.

Scheduled Orchestration
Create an integration that uses a schedule to trigger the integration instead of an adapter. For example, you add an initial invoke adapter to read a trigger file and a second FTP adapter to download the file for further processing. After designing this integration, you schedule when to run it.
File Transfer
Create an integration to move files across a network.
Basic Routing
Create an integration with a blank trigger and invoke in which to add your own adapters. You can also create a single routing expression and request and response enrichments, as needed. You cannot create multiple routing expressions. If your integration requires this feature, create an orchestrated integration.
Publish to OIC
Create an integration in which you add a trigger adapter to publish messages to Oracle Integration through a predefined Oracle Integration Messaging invoke. No configuration of the invoke subscriber is required.The publisher and subscribers participating in this integration pattern can be activated and deactivated independently of each other.
Subscribe to OIC
Create an integration in which you add an invoke adapter to subscribe to messages from Oracle Integration through an Oracle Integration Messaging trigger. You are prompted to select the publisher to which to subscribe. You must have already created a publisher to which to subscribe. The publisher does not need to be active, but must already be completely configured.

Any business identifiers defined on fields in the published integration are copied to the subscriber. Any changes made to the published integration’s business identifiers after copying are not reflected in the subscriber. The publisher and subscribers participating in this integration pattern can be activated and deactivated independently of each other.

Mapper:

A Visual Mapper is provided that enables you to map fields between applications with different data structures by dragging source fields onto target fields.

Monitoring:
OICS dashboard displays information about the current sate of all running integrations, successful messages ratio, connections etc.


Check all Oracle Services:

https://www.oracle.com/cloud/free/

Register for oracle cloud:

https://myservices.us.oraclecloud.com/mycloud/signup

With Oracle subscription:
  • 30 days free trial having $300free credits.
  • Access to  a wide range of Oracle cloud services for 30 days including database, analytics compute and container engine for kubernates
  • up to eight instances across all available services.
  • up to 5 TB of storage,
  • Autonomous transaction processing or autonomous data warehouse 2 database total each with 1OCPU and 20 GB storage.
  • 2 block volumes 100 GB total, 10 GB object storage 10 GB Archive storage,

Wednesday, November 20, 2019

12c SOA - how to specify Inline schemas within a WSDL file

Inline Schemas are a way of including the schema within a WSDL file rather than specifying that it be imported.

There are two ways of including a schema within a WSDL file.
  • One way is to specify that it be imported; that is, the schema is a separate file. Its highly reusable.
  • Another way, called inline schemas, is to include the schema inline with the file. Its only used in one WSDL file and to use in another WSDL, have to copy the inline schema from the existing WSDL file to the new WSDL file
Suppose we have the following XSD.

Simple Dept Schema:
<?xml version="1.0" encoding="windows-1252" ?>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.dept.poc"
            targetNamespace="http://www.dept.poc" elementFormDefault="qualified">
  <xsd:element name="Process">
    <xsd:complexType>
      <xsd:sequence>
        <xsd:element name="DeptId" type="xsd:string"/>
      </xsd:sequence>
    </xsd:complexType>
  </xsd:element>
    <xsd:element name="ProcessRes">
    <xsd:complexType>
      <xsd:sequence>
        <xsd:element name="DeptName" type="xsd:string"/>
      </xsd:sequence>
    </xsd:complexType>
  </xsd:element>
</xsd:schema>

WSDL with imported xsd:
<?xml version= '1.0' encoding= 'UTF-8' ?>
<wsdl:definitions
     name="getDept"
     targetNamespace="http://xmlns.oracle.com/SOAApplication/PreferenceProject/getDept"
     xmlns:tns="http://xmlns.oracle.com/SOAApplication/PreferenceProject/getDept"
     xmlns:inp1="http://www.dept.poc"
     xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
    >
    <wsdl:types>
        <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
            <xsd:import namespace="http://www.dept.poc" schemaLocation="../Schemas/Dept.xsd"/>
        </xsd:schema>
    </wsdl:types>
    <wsdl:message name="requestMessage">
        <wsdl:part name="payload" element="inp1:Process"/>
    </wsdl:message>
    <wsdl:message name="replyMessage">
        <wsdl:part name="payload" element="inp1:ProcessRes"/>
    </wsdl:message>
    <wsdl:portType name="getDept_ptt">
        <wsdl:operation name="getDept">
            <wsdl:input message="tns:requestMessage"/>
            <wsdl:output message="tns:replyMessage"/>
        </wsdl:operation>
    </wsdl:portType>
</wsdl:definitions>

We can modify from imported to inline schema following the steps:
  • Add the target namespace of the XSD.
  • Instead of import statement, use the schema elements inside schema element.
WSDL with inline schema:
<?xml version= '1.0' encoding= 'UTF-8' ?>
<wsdl:definitions name="getDept" targetNamespace="http://xmlns.oracle.com/SOAApplication/PreferenceProject/getDept"
                  xmlns:tns="http://xmlns.oracle.com/SOAApplication/PreferenceProject/getDept"
                  xmlns:inp1="http://www.dept.poc" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
  <wsdl:types>
    <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.dept.poc">
      <xsd:element name="Process">
        <xsd:complexType>
          <xsd:sequence>
            <xsd:element name="DeptId" type="xsd:string"/>
          </xsd:sequence>
        </xsd:complexType>
      </xsd:element>
      <xsd:element name="ProcessRes">
        <xsd:complexType>
          <xsd:sequence>
            <xsd:element name="DeptName" type="xsd:string"/>
          </xsd:sequence>
        </xsd:complexType>
      </xsd:element>
    </xsd:schema>
  </wsdl:types>
  <wsdl:message name="requestMessage">
    <wsdl:part name="payload" element="inp1:Process"/>
  </wsdl:message>
  <wsdl:message name="replyMessage">
    <wsdl:part name="payload" element="inp1:ProcessRes"/>
  </wsdl:message>
  <wsdl:portType name="getDept_ptt">
    <wsdl:operation name="getDept">
      <wsdl:input message="tns:requestMessage"/>
      <wsdl:output message="tns:replyMessage"/>
    </wsdl:operation>
  </wsdl:portType>
</wsdl:definitions>


Monday, November 18, 2019

12c SOA - Modification of existing ESS scheduler

Sometimes we may need to modify the existing ESS schedulers due to Job execution time changes or day light saving time adjustment.

A scheduler can be modified in following 3 steps.

Step 1: Modification of existing scheduler.
Target navigation⇾Scheduling services⇾ESSAPP
Go to Scheduling servicesJob requestsDefine Schedules
Type the Job definition name and click go.
Your job will appear, select he job and click edit.
 Edit Schedule page will open. Click Change Frequency. It will display a warning message. Click yes.

Go to start dateclick the select date time button.
Here in this example we have increased 5 min.
Note: After modification of time always select next day else it will trigger all schedulers from the start day till current day.
In this example we have selected 14th because current day is 13th . If we select 13th and only change time then it will trigger all schedulers from 12th till 13th .
Click ok.
 Step 2: Submit the job request.
Now go to scheduling services⇾job reques⇾Submit job request.

Select the use existing schedule radio button. Enter the name of the schedule and click search icon.
Again enter the name of the schedule and click forward arrow to search. Your schedule will appear. Select your schedule and click ok.
Your schedule will appear with all its detailsclick ok to submit the schedule.
 Step 3: Delete the old parent of the scheduler.
Go to Scheduling service⇾job request⇾search job request
Select the All scheduling services sharing ESS repository radio button, enter your job definition name and un-check the succeeded checkbox in submitted tab.
Else it will give all the schedulers and we won’t find our specific scheduler.
Here our scheduler appears in the first line of search. The last line is n/a. n/a means parent of current scheduler. A scheduler can have only one parent. So select the old parent and cancel it.
In the following screen shot we have cancelled the old parent.

NOTE: It is a good practice to keep the definition name of the job different from schedule name.
Ex: Definition name: ApplicationName_AutomaticTrainingWelcomeEmail
       Scheduler name: ApplicationName_AutomaticTrainingWelcomeEmail_daily

Featured Post

11g to 12c OSB projects migration points

1. Export 11g OSB code and import in 12c Jdeveloper. Steps to import OSB project in Jdeveloper:   File⇾Import⇾Service Bus Resources⇾ Se...