Web Services Using Standard Oracle EBS - Apps Associates · 2015-12-17 · Project Accounting...

Post on 06-Apr-2020

10 views 4 download

Transcript of Web Services Using Standard Oracle EBS - Apps Associates · 2015-12-17 · Project Accounting...

© Copyright 2015. Apps Associates LLC. 1

Web Services Using Standard Oracle EBS

Divya Kantem Senior Consultant Apps Associates LLC

December 14, 2015

© Copyright 2015. Apps Associates LLC. 2

Confidentiality Statement

The content of this document is proprietary, confidential information pertaining to Apps Associates’ products, services, solutions and methods. Information herein is intended for use by the client or prospective client only and must not be shared with any third party without consent from Apps Associates.

© Copyright 2015. Apps Associates LLC. 3

Agenda

• Introduction to Apps Associates

• Web Services – Overview

• Consume Web Services – Methods

• OANDA

• Expose Web Services

• Limitations of PL/SQL Web Services

• SOA gateway

• Oracle Integration Repository

• Q&A

© Copyright 2015. Apps Associates LLC. 4

About Apps Associates

• Global Reach, Broad Service Profile

– Founded in 2002, 650+ employees

– US, Europe, India, Middle East

– Service Offerings: Applications, CRM, Analytics, EPM, Cloud, Middleware, Application Development, Application and Infrastructure Managed Services

• Significant Capabilities

– Cloud (IaaS, PaaS, SaaS)

– Business Process and System Integration

– Analytics and Big Data

• Strategic Partnerships, Certifications, Credentials

– Oracle Platinum Partner

– AWS Advanced Consulting Partner

– Salesforce Cloud Alliance Partner

– MuleSoft Partner

© Copyright 2015. Apps Associates LLC. 5

Applications

Oracle EBS

Salesforce.com

Fusion Apps

Project Accounting

Business Intelligence / EPM

OBIEE/BI Apps

Hyperion/Essbase

Exalytics

Exadata

BICS, Endeca

Technology Services

Fusion Middleware

AIA/SOA

ADF

Microsoft Services

SharePoint

.NET Application Development

Infrastructure Services

DBA

Sys admin

Cloud Hosting

Middleware Admin

Security Solutions

High Availability

Product Development

Industry Solutions

ShipConsole

Freight Shopping

Customs Doc.

• Assessments, Implementations, Upgrades, Migrations Project Services

• Managed Services and Staff Augmentation Support Services

• PMF, CMMI Certification, ITIL Methodologies, SSAE16/SAS70 Type II Quality Assurance

Competencies and Capabilities

© Copyright 2015. Apps Associates LLC. 6

Multi-Pillar Competencies & Partnerships

Enterprise Applications

Analytics Integration & Custom Dev

Product Development

IaaS

• Our Products ShipConsole Photo capture app

• ERP • Planning

• BI • Big Data / High-

Volume Data Sets

• Dev to Client Reqs • Business Process

Integration

• Cloud Adoption • Managed Services

Strategic Partnerships & Certifications

2011 2015 2012 2014 2002

Centers of Excellence

© Copyright 2015. Apps Associates LLC. 7

Web Services

© Copyright 2015. Apps Associates LLC. 8

Web Services Overview

• Application-to-application interaction

• XML, SOAP, WSDL and UDDI

• Services in middle-tier application servers

© Copyright 2015. Apps Associates LLC. 9

Database Web Services

Two directions:

• Accessing database resources (database call-in)

– PL/SQL packages

– Java classes

• Consuming external Web services (database call-out)

– SQL engine

© Copyright 2015. Apps Associates LLC. 10

Database Call In

Examples:

• Online store

• Quotes to customers

© Copyright 2015. Apps Associates LLC. 11

Database Call Out

Examples:

• Inventory information from multiple suppliers

• OANDA

© Copyright 2015. Apps Associates LLC. 12

Consume Web Services

© Copyright 2015. Apps Associates LLC. 13

Consume Web Services

• Using UTL_HTTP

– Communicate directly with the WebService and send and retrieve entire SOAP messages

• Develop Java Classes

– Consume the WebService and load these into the database wrapped with a PL/SQL package interface

• Using UTL_DBWS

– Allows generic WebService consumption from within PL/SQL

© Copyright 2015. Apps Associates LLC. 14

Method 1: UTL_HTTP

© Copyright 2015. Apps Associates LLC. 15

UTL_HTTP

• Makes HTTP callouts from SQL and PL/SQL

• Access data on the Internet

• Supports HTTPS

Common Procedure/Functions

BEGIN_REQUEST SET_HEADER

WRITE_TEXT GET_RESPONSE

READ_TEXT READ_LINE

SET_TRANSFER_TIMEOUT END_RESPONSE

© Copyright 2015. Apps Associates LLC. 16

UTL_HTTP

Sequence of steps

• l_http_request := UTL_HTTP.begin_request(url, method, http_version, request_context)

• UTL_HTTP.set_header(l_http_request, name, value)

• UTL_HTTP.write_text(l_http_request, l_param_list)

• l_http_response:=UTL_HTTP.get_response(l_http_request)

• UTL_HTTP.read_text(l_http_response, l_response_text)

• UTL_HTTP.end_response(l_http_response)

© Copyright 2015. Apps Associates LLC. 17

UTL_HTTP Example

Get Currency Exchange Rates

© Copyright 2015. Apps Associates LLC. 18

UTL_HTTP Example

Response from Web Service

© Copyright 2015. Apps Associates LLC. 19

OANDA Currency Exchange Rates

© Copyright 2015. Apps Associates LLC. 20

OANDA

OANDA Exchange Rates API

• RESTful API

• Access to OANDA’s daily exchange rate data

• Accessed via HTTP

• JSON, XML and CSV

© Copyright 2015. Apps Associates LLC. 21

Method 2: Java Classes

© Copyright 2015. Apps Associates LLC. 22

Java Classes

Develop Java Classes

• Web Service Wizards in JDeveloper

• Can be called like any normal PL/SQL procedure call

© Copyright 2015. Apps Associates LLC. 23

Java Classes

Using Jdev 10g create Java Client for Web service (Currency Exchange Rate)

• Using Jdev 10g create Java Client for Web service (Currency Exchange Rate)

• Create a new Application Workspace and Project

• New -> Business Tier -> Web Services -> Web Service Stub/Skeleton

• Enter the URL for the WSDL in the Wizard: http://www.xmethods.net/sd/2001/CurrencyExchangeService.wsdl

• Finish the Wizard

• Use CurrencyExchangeServiceStub class

© Copyright 2015. Apps Associates LLC. 24

Java Classes

Results in exchange rate

© Copyright 2015. Apps Associates LLC. 25

Java Classes – Deploy Web Service

Deploy Web Service client as Stored Java Procedure

• Create DB Schema

• Grant required privileges

© Copyright 2015. Apps Associates LLC. 26

Java Classes – Deploy Web Service

Create Deployment Profile

© Copyright 2015. Apps Associates LLC. 27

Java Classes – Deploy Web Service

Create Deployment Profile

© Copyright 2015. Apps Associates LLC. 28

Java Classes – Deploy Web Service

Deploy Deployment Profile to the Database Schema

© Copyright 2015. Apps Associates LLC. 29

Java Classes – Deploy Web Service

Test the Web Service

© Copyright 2015. Apps Associates LLC. 30

Method 3: UTL_DBWS

© Copyright 2015. Apps Associates LLC. 31

UTL_DBWS

UTL_DBWS

1. Provides Database Web Services

2. Provides a means of using a Dynamic Invocation Interface

Common Procedure/Functions

TO_QNAME CREATE_SERVICE

CREATE_CALL SET_TARGET_ENDPOINT_ADDRESS

SET_PROPERTY INVOKE

© Copyright 2015. Apps Associates LLC. 32

UTL_DBWS

Sequence of steps

1. service_qname := utl_dbws.to_qname(namespace, name);

2. service := utl_dbws.create_service(service_qname);

3. call := utl_dbws.create_call(service);

4. utl_dbws.set_target_endpoint_address(call, endpoint);

5. utl_dbws.set_property( call, key, value);

6. response := utl_dbws.invoke(call, request);

© Copyright 2015. Apps Associates LLC. 33

UTL_DBWS Example

Get sum of two numbers

© Copyright 2015. Apps Associates LLC. 34

UTL_DBWS Example

Get sum of two numbers

© Copyright 2015. Apps Associates LLC. 35

Expose PL/SQL as Web Service

© Copyright 2015. Apps Associates LLC. 36

Expose PL/SQL as Web service

Sequence of steps in Jdeveloper

1. Create Application Workspace and Project

2. Create Database connection

3. Install pl/sql package

4. Publish pl/sql package

5. Deploy the web service

© Copyright 2015. Apps Associates LLC. 37

Expose Web Service Example – Step 1

Create Application Workspace and Project

© Copyright 2015. Apps Associates LLC. 38

Expose Web Service Example – Step 2,3,4

Create DB WS_LOCAL and compile APP_SALES package and Publish

© Copyright 2015. Apps Associates LLC. 39

Expose Web Service Example

Response

© Copyright 2015. Apps Associates LLC. 40

Limitations of PL/SQL Web Services

© Copyright 2015. Apps Associates LLC. 41

Limitations of PL/SQL Web Services

PL/SQL Web services cannot be created in below situations:

• Overloaded Program Units

• BFILE Type

• OUT and IN-OUT parameters

• PL/SQL Records

• Stored procedures of the same name which are accessible in more than one schema

• Ref cursors return types

• SYS schema

• PL/SQL nested tables

© Copyright 2015. Apps Associates LLC. 42

SOA Gateway

© Copyright 2015. Apps Associates LLC. 43

SOA Gateway

Oracle E-Business Suite Integrated SOA Gateway

• Exposing and providing out-of-the-box Web services from Oracle E-Business Suite

• Faster design-to-deploy integration flows

• Transform public interfaces into standard Web services

• Provides interoperability advantage for SOA-based Integration

• Native service invocation framework to invoke all 3rd party external Web services

© Copyright 2015. Apps Associates LLC. 44

Oracle Integration Repository

© Copyright 2015. Apps Associates LLC. 45

Oracle Integration Repository

• Ability to access an individual application through a business interface

• Interfaces can be used from application-to-application (A2A), or from business-to-business (B2B)

• Supports Interface Types

• What API would be suitable for a specific business process?

© Copyright 2015. Apps Associates LLC. 46

Oracle Integration Repository

• Like any other Oracle E-Business Suite application

• User with sufficient privileges

• Responsibility – Integrated SOA Gateway

• Browse Integration interfaces:

– Product family

– Business Entity/Interface Type/Integration Standard

© Copyright 2015. Apps Associates LLC. 47

Conclusion

• Introduction to Apps Associates

• Web Services – Overview

• Consume Web Services – Methods

• OANDA

• Expose Web Services

• Limitations of PL/SQL Web Services

• SOA Gateway

• Oracle Integration Repository

© Copyright 2015. Apps Associates LLC. 48

Connect with Us

Web: www.appsassociates.com

Email: marketing@appsassociates.com

YouTube: www.youtube.com/user/AppsAssociates

LinkedIn: www.us.linkedin.com/company/Apps-Associates

Twitter: www.twitter.com/AppsAssociates

Facebook: www.facebook.com/AppsAssociatesGlobal

Google+: www.plus.google.com/+AppsAssociatesGlobal/

Thank You!