oracle developer daypeople.cs.ksu.edu/~hankley/d764/oracle/slides/j2ee... · 7 page 7 bpel –...

17
1 Page 1 Sponsored by: Sponsored by: Sponsored by: Sponsored by: Oracle Developer Day Track #1 - Session #4 BPEL Introduction Presenter Name Presenter Title

Upload: others

Post on 27-Jul-2020

4 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Oracle Developer Daypeople.cs.ksu.edu/~hankley/d764/Oracle/Slides/J2EE... · 7 Page 7 BPEL – Control Flow • BPEL provides the usual branching and looping control flow constructs

1

Page 1

Sponsored by:Sponsored by:Sponsored by:Sponsored by:

OracleDeveloper Day

Track #1 - Session #4

BPEL Introduction

Presenter NamePresenter Title

Page 2: Oracle Developer Daypeople.cs.ksu.edu/~hankley/d764/Oracle/Slides/J2EE... · 7 Page 7 BPEL – Control Flow • BPEL provides the usual branching and looping control flow constructs

2

Page 2

Agenda

• Orchestration

• What is BPEL ?

• BPEL Programming Language

• Steps to Build a Business Process

• Oracle BPEL Process Manager

Orchestration Requirements

?

Java Platform

Portal

ADF

Java Services (EJB)

Messaging Destinations (JMS)

User Tasks

Web Services (Sync and Async)

Legacy Applications (JCA, adapters)

Orchestration

ConnectivityHeterogenous Back Ends

Silos of API and mechanisms

Opaque/heterogeneous data definitionsSynchronizing multiple data stores

Flow ControlAsynchrony, Flow Coordination, Data

Transformation, Compensation, Version Control,

Auditing

ScalabilityUnpredictable loads

Asymmetric performance capabilities

Management and SecurityAccess control, Encryption, Logging, Metering

Independent of the service

Interaction/AccessCatalog, Customization, Access

Page 3: Oracle Developer Daypeople.cs.ksu.edu/~hankley/d764/Oracle/Slides/J2EE... · 7 Page 7 BPEL – Control Flow • BPEL provides the usual branching and looping control flow constructs

3

Page 3

Orchestrate Services

BPELBPEL

Credit RatingCredit Rating

WSDLWSDL

Service BusService Bus

Star LoanStar Loan

Order EntryOrder Entry United LoanUnited Loan

AADDAAPPTTEERR

AADDAAPPTTEERR

WWSSDDLL

FulfillmentFulfillment

AADDAAPPTTEERR

Application ServerApplication Server

What is BPEL?

Bad

Credit !

start

end

Markup language for composing a set of discrete

services into an end-to-end process flow

• 10+ years of R&D from

MSFT and IBM

• SOAP but also Java, JCA

• Rich Flow Semantics

• Optimized Bindings

• XPATH+XSLT+XQuery

• WS-Security

• A Process is a Service

Star LoanStar LoanUnited LoanUnited Loan

Credit CheckCredit Check

Page 4: Oracle Developer Daypeople.cs.ksu.edu/~hankley/d764/Oracle/Slides/J2EE... · 7 Page 7 BPEL – Control Flow • BPEL provides the usual branching and looping control flow constructs

4

Page 4

BPEL History

2000/05

XLang(Microsoft)

2001/03

BPML(Intallio et al)

2001/05

WSFL(IBM)

2001/06

BPSS(ebXML)

2002/03

BPEL4WS 1.0(IBM, Microsoft)

BPEL4WS 1.1

(OASIS)

2002/06 2003/04

WSCI(Sun et al)

WSCL(HP)

2002/08

Proprietary Standard

2005/2006

WS-BPEL 2.0(OASIS)

BPEL – Programming Language

• Variables

• Activities

• Control Flow

• Scope

• Fault Handling

• Event Handling

Page 5: Oracle Developer Daypeople.cs.ksu.edu/~hankley/d764/Oracle/Slides/J2EE... · 7 Page 7 BPEL – Control Flow • BPEL provides the usual branching and looping control flow constructs

5

Page 5

BPEL - Variables

• Used to store, reformat and transform messages

• Required to send and receive messages

• Each variable has a TypeExample:<variables>

<variable name="loanApplication" messageType="ns2:LoanServiceRequestMessage"/>

</variables>

BPEL - Activities

•Primitive Activities– <invoke>

– <receive>

– <assign>

– <reply>

– <throw>

– <terminate>

– <wait>

•Structured Activities– <sequence>

– <switch>

– <pick>

– <flow>

– <link>

– <while>

– <scope>

Page 6: Oracle Developer Daypeople.cs.ksu.edu/~hankley/d764/Oracle/Slides/J2EE... · 7 Page 7 BPEL – Control Flow • BPEL provides the usual branching and looping control flow constructs

6

Page 6

BPEL - Activities• <invoke>

– Invoke a service synchronouslyEx: Invoke Credit Service

• <receive>– Waits for the incoming message, either to start the process or for

a callbackEx: Wait for a message from United Loan

• <reply>– Return response for synchronous process, relate to initial

<receive>

• <assign>– Copy data between variables, expressions and endpoint

references– Used with XPath expressions and XSLT engine

Ex: Copy Loan Application from input payload to United Loan input

BPEL – Scope

• Scopes can be used to divide the business process into organized parts

• A <scope> is an execution context for the contained activities, and a process is, itself, a <scope>

• A <scope> defines local variables and can catch and handle either specific faults or all faults that occur with itEx: GetCreditRating Scope – Invoke Credit Service and catch exceptions

Page 7: Oracle Developer Daypeople.cs.ksu.edu/~hankley/d764/Oracle/Slides/J2EE... · 7 Page 7 BPEL – Control Flow • BPEL provides the usual branching and looping control flow constructs

7

Page 7

BPEL – Control Flow

• BPEL provides the usual branching and looping control flow constructs

• A <sequence> executes activities in serial order

• A <switch> executes at most one alternative based on expressions specified on child <case> elements with an optional <otherwise>Ex: Choose between United and Star loan offers based on lower APR

• A <while> loops through activities while a variable's value is true

• BPEL provides a parallel control construct through the <flow> activityEx: Invoke United and Star Loan services in parallel

Partner Links

• Links to all parties that process interacts

• Links can be to Web ServicesEx: CreditService, UnitedLoanService, StarLoanService

• Links can be to other BPEL processes as well

• PartnerLinkTypes– Declares how parties interact and what each

party offers

Page 8: Oracle Developer Daypeople.cs.ksu.edu/~hankley/d764/Oracle/Slides/J2EE... · 7 Page 7 BPEL – Control Flow • BPEL provides the usual branching and looping control flow constructs

8

Page 8

BPEL - Fault Handling

• Handle faults to enable completion of process using <faultHandlers>

• Use <catch> activity to handle specific

faultsEx: Catch bad credit exception and terminate the process

• Use <catchAll> to handle all other faults

Steps to Build Business Process

1. Define Public Interface1. Define Public Interface

2. Create Partner Dictionary2. Create Partner Dictionary

3. Create Message and Type Dictionary3. Create Message and Type Dictionary

4. Implement Transformation Logic4. Implement Transformation Logic

5. Implement Orchestration Logic5. Implement Orchestration Logic

6. Create a Test Environment6. Create a Test Environment

7. Iterate7. Iterate

8. Live Pilot8. Live Pilot

9. Fine9. Fine--tune Operations Taskstune Operations Tasks

Page 9: Oracle Developer Daypeople.cs.ksu.edu/~hankley/d764/Oracle/Slides/J2EE... · 7 Page 7 BPEL – Control Flow • BPEL provides the usual branching and looping control flow constructs

9

Page 9

Step 1: Define Public InterfaceDeliverables:

• WSDL description of the interface of the implemented BPEL process

LoanFlow.wsdl

WSDL

LoanFlow

initiate

onResult

Client

Callback

LoanRowBPEL Process

Step 2: Create Partner DictionaryDeliverables:• List of the WSDL of the services that will be invoked as part of the BPEL Process

• For each partner, document the order in which operations will be invoked (choreography)

• Make sure that each use case describes both positive and negative use cases

bpel.xml

De

plo

ym

en

t D

es

cri

pto

rE

nd

po

int

refe

ren

ce

b

ind

ing

LoanFlow.wsdl

WSDL

LoanFlow

initiate

onResult

Client

Callback

LoanRowBPEL Process

Credit RatingCredit RatingWWSSDDLL

Web ServiceWeb Service

Start LoanStart LoanWWSSDDLL

Web ServiceWeb Service

United LoanUnited LoanWWSSDDLL

Web ServiceWeb Service

Page 10: Oracle Developer Daypeople.cs.ksu.edu/~hankley/d764/Oracle/Slides/J2EE... · 7 Page 7 BPEL – Control Flow • BPEL provides the usual branching and looping control flow constructs

10

Page 10

Step 3: Create Message and Type Dictionary

Deliverables:

• A set of XML Schema files that describe the type of the messages and XML documents used as part of the BPEL process.

bpel.xml

De

plo

ym

en

t D

es

cri

pto

rE

nd

po

int

refe

ren

ce

b

ind

ing

LoanFlow.wsdl

WSDL

LoanFlow

initiate

onResult

Client

Callback

Credit RatingCredit RatingWWSSDDLL

Web ServiceWeb Service

Start LoanStart LoanWWSSDDLL

Web ServiceWeb Service

United LoanUnited LoanWWSSDDLL

Web ServiceWeb Service

LoanRowBPEL Process

Schedule Response

variablesvariablesSchedule Request

Exchange Request

more…

Step 4: Transformation LogicDeliverables:

• A set of XSLT and XQuery files that encapsulate mapping information

across the various types used in the BPEL process

bpel.xml

De

plo

ym

en

t D

es

cri

pto

rE

nd

po

int

refe

ren

ce

b

ind

ing

LoanFlow.wsdl

WSDL

LoanFlow

initiate

onResult

Client

Callback

Credit RatingCredit RatingWWSSDDLL

Web ServiceWeb Service

Start LoanStart LoanWWSSDDLL

Web ServiceWeb Service

United LoanUnited LoanWWSSDDLL

Web ServiceWeb Service

LoanRowBPEL Process

Schedule MapSchedule MapXSLTXSLT

WWSSDDLL

transformationtransformation

variablesvariablesloanApplication

crInput

crOutputmore…

Page 11: Oracle Developer Daypeople.cs.ksu.edu/~hankley/d764/Oracle/Slides/J2EE... · 7 Page 7 BPEL – Control Flow • BPEL provides the usual branching and looping control flow constructs

11

Page 11

Step 5: Orchestration LogicDeliverables:

• Implement the workflow that ties the interactions across partners into an end-to-end business process.

• Make sure that all exceptions and timeouts are managed properly

Select Lowest Offer

Negative Credit

faultHandler

Synchronous

<invoke>

<receive>

<invoke>

<process>

?

<receive>.

<invoke> <invoke>

Get Rating

Send LoanApplication

Receive Loan Offer <receive>.

Receive Loan Offer

Send LoanApplication Star LoanStar Loan

Credit RatingCredit Rating

United LoanUnited Loan

Step 6: IterateDeliverables:• Add incrementally new partners

• Keep on improving exception management

• Create automated test and regression framework

LoanFlow.wsdl

WSDL

LoanFlow

initiate

onResult

Client

Callback

orchestration

bpel.xml

De

plo

ym

en

t D

es

cri

pto

rE

nd

po

int

refe

ren

ce

b

ind

ing

Credit RatingCredit RatingWWSSDDLL

Web ServiceWeb Service

Start LoanStart LoanWWSSDDLL

Web ServiceWeb Service

United LoanUnited LoanWWSSDDLL

Web ServiceWeb Service

LoanRowBPEL Process

variablesvariablesloanApplication

crInput

crOutputmore…

Schedule MapSchedule MapXSLTXSLT

WWSSDDLL

transformationtransformation

Page 12: Oracle Developer Daypeople.cs.ksu.edu/~hankley/d764/Oracle/Slides/J2EE... · 7 Page 7 BPEL – Control Flow • BPEL provides the usual branching and looping control flow constructs

12

Page 12

Step 7: Create test environmentDeliverables:

• Implement dummy test services for each end point

(could be BPEL or your favorite Web services publishing technology)• Create test scenario for each positive and negative use cases

• Crash test, longevity test (integrity/reliability)

• Performance test, stress test

Dummy Test Services

LoanFlow.wsdl

WSDL

LoanFlow

initiate

onResult

Client

Callback

orchestration

bpel.xml

De

plo

ym

en

t D

es

cri

pto

rE

nd

po

int

refe

ren

ce

b

ind

ing

Credit RatingCredit RatingWWSSDDLL

Web ServiceWeb Service

Start LoanStart LoanWWSSDDLL

Web ServiceWeb Service

United LoanUnited LoanWWSSDDLL

Web ServiceWeb Service

LoanRowBPEL Process

variablesvariablesloanApplication

crInput

crOutputmore…

Schedule MapSchedule MapXSLTXSLT

WWSSDDLL

transformationtransformation

Step 8: Live PilotDeliverables:

• Wire BPEL process to real end points

• Run regression tests

Integration over internet/intranet

LoanFlow.wsdl

WSDL

LoanFlow

initiate

onResult

Client

Callback

orchestration

bpel.xml

De

plo

ym

en

t D

es

cri

pto

rE

nd

po

int

refe

ren

ce

b

ind

ing

Credit RatingCredit RatingWWSSDDLL

Web ServiceWeb Service

Start LoanStart LoanWWSSDDLL

Web ServiceWeb Service

United LoanUnited LoanWWSSDDLL

Web ServiceWeb Service

LoanRowBPEL Process

variablesvariablesloanApplication

crInput

crOutputmore…

Schedule MapSchedule MapXSLTXSLT

WWSSDDLL

transformationtransformation

Page 13: Oracle Developer Daypeople.cs.ksu.edu/~hankley/d764/Oracle/Slides/J2EE... · 7 Page 7 BPEL – Control Flow • BPEL provides the usual branching and looping control flow constructs

13

Page 13

Step 9: Fine-tune Operation Tasks

Deliverables:

• Exception Management

• Integration with Web Service Management Framework

• Security

• Archiving

Oracle BPEL Process Manager

Enterprise-strength infrastructure for designing, deploying and

managing BPEL business processes

• Comprehensive and nativeBPEL implementation

• Easy-to-use modeling tool

• Scalable and reliable engine

• Flexible binding framework

• Rich management and monitoring

• Get up and running in less than 15 minutes!

BAMBAM

Application Server Application Server ( Oracle, BEA, JBoss, IBM)( Oracle, BEA, JBoss, IBM)

TransformationTransformation CorrelationCorrelation

WSIF BindingWSIF Binding QueuingQueuing

SAPSAP EBSEBS DBDB FileFile ……

XSLTXSLTMapperMapper

AdapterAdapterFactoryFactory

BPELBPELConsoleConsole

BPELBPELDesignerDesigner

WorkflowWorkflow RuleRule

BPEL EngineBPEL Engine

Dehydration Store

(Oracle Database)

Oracle BPEL Process ManagerOracle BPEL Process Manager

Page 14: Oracle Developer Daypeople.cs.ksu.edu/~hankley/d764/Oracle/Slides/J2EE... · 7 Page 7 BPEL – Control Flow • BPEL provides the usual branching and looping control flow constructs

14

Page 14

Cross Platform

Application Server

• Oracle Application Server

• WebLogic Server

• WebSphere

• JBoss

Database

• Oracle Database

• SQL Server

• Oracle Lite

• Sybase

• Pointbase

IDE

• JDeveloper

• Eclipse

Operating Systems

• Linux

• Window XP/2003

• Solaris

• HP UX

• zOS

BPEL Console

KEY FEATURES

• Visual Monitoring

• Auditing

• BPEL Debugging

• In-flight Instance

Administration

• Performance Tuning

• Partitioning/Domains

Page 15: Oracle Developer Daypeople.cs.ksu.edu/~hankley/d764/Oracle/Slides/J2EE... · 7 Page 7 BPEL – Control Flow • BPEL provides the usual branching and looping control flow constructs

15

Page 15

D E M O N S T R A T I O N

Join Over 4,500,000 Developers!Join Over 4,500,000 Developers!Join Over 4,500,000 Developers!Join Over 4,500,000 Developers!

Free Software DownloadsFree Software DownloadsFree Software DownloadsFree Software DownloadsFree Technical AdviceFree Technical AdviceFree Technical AdviceFree Technical Advice

www.oracle.com/technology/products/www.oracle.com/technology/products/www.oracle.com/technology/products/www.oracle.com/technology/products/jdevjdevjdevjdevotnotnotnotn.oracle.com/tech/.oracle.com/tech/.oracle.com/tech/.oracle.com/tech/webserviceswebserviceswebserviceswebservices

otnotnotnotn.oracle.com/tech/java.oracle.com/tech/java.oracle.com/tech/java.oracle.com/tech/javaotnotnotnotn.oracle.com/.oracle.com/.oracle.com/.oracle.com/bpelbpelbpelbpel

Page 16: Oracle Developer Daypeople.cs.ksu.edu/~hankley/d764/Oracle/Slides/J2EE... · 7 Page 7 BPEL – Control Flow • BPEL provides the usual branching and looping control flow constructs

16

Page 16

Learn Oracle From Oracle

•Instructor led training

•Self-Study

•Online learning

•Oracle Certification

•Oracle iLearning

•Oracle Tutor

oracle.com/education

AQ&Q U E S T I O N SQ U E S T I O N S

A N S W E R SA N S W E R S

Page 17: Oracle Developer Daypeople.cs.ksu.edu/~hankley/d764/Oracle/Slides/J2EE... · 7 Page 7 BPEL – Control Flow • BPEL provides the usual branching and looping control flow constructs

17

Page 17

Sponsored by:Sponsored by:Sponsored by:Sponsored by:

OracleDeveloper Day