workflow, bpm and java

31
2005 JavaOne SM Conference | Session 7364 Workflow, BPM and Java Tom Baeyens Lead Developer JBoss TS-7364

Upload: lacey

Post on 08-Jan-2016

42 views

Category:

Documents


0 download

DESCRIPTION

Workflow, BPM and Java. Tom Baeyens Lead Developer JBoss. TS-7364. Speaker. Tom Baeyens Founder and project lead of JBoss jBPM Member of JCP expert groups JSR207 ‘Process Definition for Java’ JSR208 ‘Java Business Integration’. Agenda. Missing link in Java Workflow - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364

Workflow, BPM and Java

Tom Baeyens

Lead DeveloperJBoss

TS-7364

Page 2: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 2

• Tom Baeyens• Founder and project lead of JBoss jBPM• Member of JCP expert groups

• JSR207 ‘Process Definition for Java’• JSR208 ‘Java Business Integration’

Speaker

Page 3: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 3

Agenda

Missing link in Java• Workflow• Business Process Management (BPM)• Orchestration

Traditional ApproachGraph Oriented ProgrammingConclusion

Page 4: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 4

After all the trouble to make Java fast...

we’re going toadd wait states

Page 5: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 5

Workflow requirementsBPM requirements

Orchestration requirements

workflowsolutions BPM

solutions

orchestrationsolutions

Page 6: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 6

Suspending Path of Execution

System A System B

?

Page 7: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 7

Java’s Limitation

...sendMessageToSystemB();Response response = waitForResponseFromB();...

• Not persistable• No graphical representation

Page 8: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 8

Graphical Representation

• Analyst draws graphs that include wait states• Technical solution enables common language• Analysts do not create software

• Iterative refinement• Developer adds technical details• Analyst looks at projected view

Page 9: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 9

Agenda

Missing link in Java• Workflow• Business Process Management (BPM)• Orchestration

Traditional ApproachGraph Oriented ProgrammingConclusion

Page 10: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 10

Traditional Approach

• Define a set of constructs• That are the node-types in a graph• With a graphical representation• And a runtime behaviour• Set of constructs is process language

Page 11: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 11

Traditional Problems

• Monolithic systems• Process language is never powerfull enough• No modelling freedom• Turns into visual programming

Page 12: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 12

Agenda

Missing link in Java• Workflow• Business Process Management (BPM)• Orchestration

Traditional ApproachGraph Oriented ProgrammingConclusion

Page 13: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 13

Graph Oriented Programming

• Define a directed graph

to *arrivingTransitions

fromleavingTransitions

*Node Transition

Page 14: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 14

Graph Oriented Programming

• Define an executional model• A Token is a path of execution in a single system

System A System B

Token

Page 15: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 15

Graph Oriented Programming

• Define an executional model

Troot

Tshipping Tbilling

Token

children

parent

Node

Page 16: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 16

Graph Oriented Programming

• Define an executional model• A Signal is the trigger that resumes process execution

System A

Token

send message to System B

send a Signal to the Token

Page 17: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 17

Creating the ProcessInstance

ProcessInstance pi =

new ProcessInstance(pd);

Token token = pi.getRootToken();

token.signal();

// put process instance and token

// in the persistent store

// fetch the token from

// the persistent store

Token token = ...;

token.signal();

e.g. web app

e.g. MDB

Page 18: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 18

Graph Execution Algorithm

• Chain of Responsibility

Node+execute(Token)

+leave(Token,

Transition)

Transition

+take(Token)to

leavingTransitions

*

1

Page 19: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 19

Graph Execution Algorithm

• Algorithm is aligned with transactions• Client’s thread is used for calculation• No reinvention• Existing Java API’s are leveraged

• e.g. JMS for asynchronous communication

Page 20: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 20

Hiding Details with Actions

Page 21: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 21

Hiding Details with Actions

Page 22: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 22

Hiding Details with Actions

Token

Page 23: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 23

Graph Oriented Programming

GOP provides the meansto structure your software

around a graph

Page 24: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 24

Agenda

Missing link in Java• Workflow• Business Process Management (BPM)• Orchestration

Traditional ApproachGraph Oriented ProgrammingConclusion

Page 25: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 25

Graph Oriented Programming

• Simple API + chain of responsibility• replaces monolithic systems

• Inheriting from Node• gives ultimate process language power

• Adding ‘invisible’ Actions• give modelling freedom

• Process development cycle• replaces visual programming

Page 26: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 26

Building Blocks

Java

Graph Oriented Programming

TaskMgmt

Task User Interfaces

AsyncInvocation

Transport

BusinessIntelligence

BI User Interfases

Page 27: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 27

Summary

• Java has limited support for wait states• Graph Oriented Programming extends Java with

the ability to suspend and resume executions• Graph Oriented Programming is a building block • Workflow, BPM and orchestration functionalities

can be built on top of it

Page 28: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 28

Conclusion

• JBoss jBPM implements this technology• modular• with functional extensions

• Available as a POJO API in a plain .jar• Scales to enterprise

So you can stop writing home grown frameworks

Page 29: Workflow, BPM and Java

2005 JavaOneSM Conference | Session 7364 | 29

Next Steps

• Visit• http://jbpm.org• http://jboss.com

• JBoss jBPM userguide• Chapter “Graph Oriented Programming”

• Get involved• http://jbpm.org/forums• http://jbpm.org/wiki

• JBoss jBPM Training• http://jbpm.org/training

Page 30: Workflow, BPM and Java

2005 JavaOneSM Conference | Session XXXX | 30

Demo

Page 31: Workflow, BPM and Java

2005 JavaOneSM Conference | Session XXXX | 31

Q&A