jBPM5 Community Training    Sponsored by Plugtree
Module 1: jBPM5 Introduction      jBPM5 Community Training        version: 1.0-SNAPSHOT       Release Date: 01/28/2011  Un...
Module 1: jBPM5 Introduction jBPM5 Community Training Course by Mauricio "Salaboy" Salatino is licensed under a Creative C...
AgendajBPM Project HistoryjBPM5 OverviewjBPM5 GoalsClassic BPMS vs jBPM5 architecture (Competitors)BPMN2 StandardjBPM5 fea...
jBPM Project HistoryjBPM 3.x borns as a BPMS (Business Process ManagementSystem)It was classified by JBoss as an integrati...
jBPM Project History (Drools)Drools was born as a Rule Engine.Mark Proctor is the current project leader.In Drools version...
jBPM Project HistoryDrools Flow 5.x was released back in 2009The rebranded version of Drools Flow, jBPM5 wasreleased on De...
jBPM Project HistoryThe main difference between jBPM5 and other BPMSs isthe fact that jBPM5 runs on top of Drools Expert (...
jBPM5 Overview
jBPM5 OverviewIt is a bridge between Business Analysts and DevelopersApache ASL LicensedCentral concept inside jBPM5: Busi...
Business Processhmm.. but wait a second, What is a business process?          "A sequence of activities,      performed by...
Business Process ExampleSimple Emergency Service Process
jBPM5 FeaturesIt provides you a flexible platform for designing andexecuting your business processesIt provides you an int...
jBPM5 competitors   Workflow          BPMS          BPMSExecution Engine   jBPM 3.x   jBPM 4.x / Activiti
OSWorkflowWorkflow wf = new BasicWorkflow(username);HashMap inputs = new HashMap();inputs.put("docTitle", request.getParam...
jBPM 3.xProcessDefinition processDefinition = ProcessDefinition                             .parseXmlResource("process-def...
jBPM 4.xProcessEngine processEngine = new Configuration()              .setResource(configurationResource)              . ...
Activiti5ProcessEngine processEngine = new ProcessEngineBuilder()          .configureFromPropertiesResource(configurationR...
Classic BPMS and Rule Engine Interaction
Classic BPMS and Rule Engine InteractionDrawbacks of the classic approach:   The Rule Engine and the BPMS uses different A...
Spaghetti BPEL of hell
Inversion of ControlBusiness Processes and Business Rules run on top of theRule Engine
Inversion of ControlBenefits:   Tightly coupled design   Process Centric vision for common branches   Exceptions are handl...
Once again, Business Process       "A sequence of activities,   performed by humans or systems     to complete a business ...
Business Process StructureDirected Graph Composed of:   Nodes (Activities)   Connections (SequenceFlows)       Outgoing an...
Business Process StructureInternal Structure:   Process      Node Container          Node
Simple Process (BPMN2)<process processType="executable" id="Sample" name="Sample Process" >  <!-- nodes -->  <startEvent i...
Business Process DefinitionsAt runtime jBPM5 load the XML process definitions toan Object Model that contains the process ...
Business Process RuntimeBased on the process structure that jBPM5 creates, wecan create new Processes InstancesThese Proce...
Developing ApplicationsFor developing applications with jBPM5 you will need toknow:   Project library dependencies   Under...
Project Dependencies   Maven project dependencies of jBPM5 can be   found at JBoss Maven Repositories:    <repositories>  ...
Project DependenciesThe jBPM artifacts that you must use in yourprojects are:   <dependency>       <groupId>org.jbpm</grou...
KBase and KSessionKnowledge Base: it will represent a compiled and staticrepresentation of our business assets. The knowle...
Basic APIsKnowledgeBuilder and KnowledgeBuilderFactoryKnowledgeBase and KnowledgeBaseFactoryStatefulKnowledgeSession
KnowledgeBuilderIt will compile our business assets into a binary andoptimized formatThis process is expensive and must be...
KnowledgeBaseIt will contain our Knowledge packagesIt represents a static version of our knowledge assetsUseful methods   ...
StatefulKnowledgeSessionEasy and cheap to createIt will represent our runtime environmentOur processes will run inside a S...
We have learned ...jBPM5 is a BPMS that runs on top of Drools Expert (RuleEngine)Knowing the project library dependencies ...
Next ModulesStay tuned for the next modules that will explain importanttopics such as:   The Business Process Management D...
Related LinksYou can find more information, examples, tutorials andmore in:   Official documentation      http://hudson.jb...
Enjoy! and be patient for the firstHands On Labs!
               Questions?
                          Contact us atwww.plugtree.com
Upcoming SlideShare
Loading in …5
×

JBPM5 Community Training Course - Module #1 Introduction

10,398 views

Published on

The first module of the jBPM5 Community Training Courses. For more information visit: http://salaboy.wordpress.com

0 Comments
7 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
10,398
On SlideShare
0
From Embeds
0
Number of Embeds
5,562
Actions
Shares
0
Downloads
408
Comments
0
Likes
7
Embeds 0
No embeds

No notes for slide

JBPM5 Community Training Course - Module #1 Introduction

  1. 1.    jBPM5 Community Training Sponsored by Plugtree
  2. 2. Module 1: jBPM5 Introduction jBPM5 Community Training version: 1.0-SNAPSHOT Release Date: 01/28/2011 Under The Creative Common License
  3. 3. Module 1: jBPM5 Introduction jBPM5 Community Training Course by Mauricio "Salaboy" Salatino is licensed under a Creative Commons Attribution 3.0 Unported License. Based on a work at salaboy.wordpress. com. Permissions beyond the scope of this license may be available at http: //salaboy.wordpress.com/.
  4. 4. AgendajBPM Project HistoryjBPM5 OverviewjBPM5 GoalsClassic BPMS vs jBPM5 architecture (Competitors)BPMN2 StandardjBPM5 featuresDeveloping Applications with jBPM5Conclusions
  5. 5. jBPM Project HistoryjBPM 3.x borns as a BPMS (Business Process ManagementSystem)It was classified by JBoss as an integration softwareUntil jBPM 4.x Tom Baeyens was in charge of the projectTom Baeyens quit JBoss and joins Alfresco
  6. 6. jBPM Project History (Drools)Drools was born as a Rule Engine.Mark Proctor is the current project leader.In Drools version 4.x a new module appear called DroolsFlow.The main idea behind Drools Flow was to provide BPMScapabilities on top of the Rule Engine.Kris Verlaenen, Phd was in charge of the Drools Flowinitiative, writing it from the scratch.The main goal of Drools is to provide a platform where rulesand business processes can live, coexist and collaborate asKnowledge Representations.
  7. 7. jBPM Project HistoryDrools Flow 5.x was released back in 2009The rebranded version of Drools Flow, jBPM5 wasreleased on December of 2010Provides a rock solid BPMS core and a flexiblemechanisms to implement the main stages of the BPMdisciplineTotally based on BPMN2jBPM5 was conceived having in mind the code base ofDrools Flow and covering all the functionality providedby jBPM 4.xjBPM 5.x is a mature code base with more than 3 years ofdevelopment and several testing.
  8. 8. jBPM Project HistoryThe main difference between jBPM5 and other BPMSs isthe fact that jBPM5 runs on top of Drools Expert (RuleEngine), providing amazing features like: The possibility of doing inferences over our business processes Handling process exceptional paths using business rules Mixing Complex Event Processing, Rules and Processes together without learning a new API for each topic
  9. 9. jBPM5 Overview
  10. 10. jBPM5 OverviewIt is a bridge between Business Analysts and DevelopersApache ASL LicensedCentral concept inside jBPM5: Business ProcessBPMS = BPM System Design / Model (Eclipse Plug in - Web Based Editor) Execute (runtime to execute our processes) Monitor / Optimize (BAM and Reporting tools)Tightly coupled with the rule engine allow us to represent complex situations (real life is complex)
  11. 11. Business Processhmm.. but wait a second, What is a business process? "A sequence of activities, performed by humans or systems to complete a business goal"
  12. 12. Business Process ExampleSimple Emergency Service Process
  13. 13. jBPM5 FeaturesIt provides you a flexible platform for designing andexecuting your business processesIt provides you an integrated set of APIs for the RuleEngine, Process Engine and the Complex Event ProcessingEngineIt provides you a platform to build our applications usingbusiness processes to guide the company workIt provides you an abstraction about how your companysactivities are orchestratedIt provides a simple and automated mechanism to handleinformation across activities
  14. 14. jBPM5 competitors Workflow BPMS BPMSExecution Engine jBPM 3.x jBPM 4.x / Activiti
  15. 15. OSWorkflowWorkflow wf = new BasicWorkflow(username);HashMap inputs = new HashMap();inputs.put("docTitle", request.getParameter("title"));wf.doAction(1, 1, inputs);
  16. 16. jBPM 3.xProcessDefinition processDefinition = ProcessDefinition .parseXmlResource("process-def.xml");ProcessInstance processInstance = new ProcessInstance(processDefinition);processInstance. signal();
  17. 17. jBPM 4.xProcessEngine processEngine = new Configuration() .setResource(configurationResource) . buildProcessEngine();ExecutionService executionService = processEngine .getExecutionService();executionService. startProcessInstanceByKey("simpleProcess");
  18. 18. Activiti5ProcessEngine processEngine = new ProcessEngineBuilder() .configureFromPropertiesResource(configurationResource) . buildProcessEngine();RuntimeService runtimeService = processEngine . getRuntimeService();runtimeService. startProcessInstanceByKey("simpleProcess");
  19. 19. Classic BPMS and Rule Engine Interaction
  20. 20. Classic BPMS and Rule Engine InteractionDrawbacks of the classic approach: The Rule Engine and the BPMS uses different APIs Sharing information between the Rule Engine and the BPMS becomes complicated and difficult to maintain Our Business Processes become very complex when we describe the exceptional paths using a process centric vision. We can leverage the declarative approach of business rules to describe exceptional situations.
  21. 21. Spaghetti BPEL of hell
  22. 22. Inversion of ControlBusiness Processes and Business Rules run on top of theRule Engine
  23. 23. Inversion of ControlBenefits: Tightly coupled design Process Centric vision for common branches Exceptions are handled in a cleaner way with rules Using a declarative approach No problems with communications and marshaling We dont need to learn different APIs
  24. 24. Once again, Business Process "A sequence of activities, performed by humans or systems to complete a business goal"
  25. 25. Business Process StructureDirected Graph Composed of: Nodes (Activities) Connections (SequenceFlows) Outgoing and Incoming
  26. 26. Business Process StructureInternal Structure: Process Node Container Node
  27. 27. Simple Process (BPMN2)<process processType="executable" id="Sample" name="Sample Process" > <!-- nodes --> <startEvent id="_1" name="StartProcess" /> <scriptTask id="_3" name="Hello World" > <script>System.out.println("Hello World!");</script> </scriptTask> <endEvent id="_2" name="End" > <terminateEventDefinition/> </endEvent> <!-- connections --> <sequenceFlow sourceRef="_3" targetRef="_2" /> <sequenceFlow sourceRef="_1" targetRef="_3" /></process>
  28. 28. Business Process DefinitionsAt runtime jBPM5 load the XML process definitions toan Object Model that contains the process structure
  29. 29. Business Process RuntimeBased on the process structure that jBPM5 creates, wecan create new Processes InstancesThese Processes Instances will represent living processexecutions
  30. 30. Developing ApplicationsFor developing applications with jBPM5 you will need toknow: Project library dependencies Understand the concept of KnowledgeBuilder, KnowledgeBase and KnowledgeSession Basic jBPM5 APIs
  31. 31. Project Dependencies Maven project dependencies of jBPM5 can be found at JBoss Maven Repositories: <repositories> <repository> <id>JBoss Maven Repo</id> <name>jboss</name> <url>https://repository.jboss.org/nexus/content/groups/public/</url> </repository> </repositories>
  32. 32. Project DependenciesThe jBPM artifacts that you must use in yourprojects are: <dependency> <groupId>org.jbpm</groupId> <artifactId>jbpm-flow</artifactId> <version>5.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.jbpm</groupId> <artifactId>jbpm-flow-builder</artifactId> <version>5.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.jbpm</groupId> <artifactId>jbpm-bpmn2</artifactId> <version>5.0-SNAPSHOT</version> </dependency>
  33. 33. KBase and KSessionKnowledge Base: it will represent a compiled and staticrepresentation of our business assets. The knowledge base isconstructured using a Knowledge Builder that will compile ourknowledge assets into knowledge packages. The knowledge basecan be composed of 1..N knowledge packages.Knowledge Session: it represent our runtime environment. Aknowledge session is created based on a knowledge base and it willcontain a living version (in memory) of our knowledge assets. Ourapplications will interact with it. It will contain our processes andrules running inside it.
  34. 34. Basic APIsKnowledgeBuilder and KnowledgeBuilderFactoryKnowledgeBase and KnowledgeBaseFactoryStatefulKnowledgeSession
  35. 35. KnowledgeBuilderIt will compile our business assets into a binary andoptimized formatThis process is expensive and must be avoided in productionsystemsWe usually build our packages once and then store thebinary result in a repository to reuse themUseful methods add(KnowledgeResource resource, ResourceType type) getErrors() getKnowledgePackages()
  36. 36. KnowledgeBaseIt will contain our Knowledge packagesIt represents a static version of our knowledge assetsUseful methods addKnowledgePackage(KnowledgePackage) newStatefulKnowledgeSession()
  37. 37. StatefulKnowledgeSessionEasy and cheap to createIt will represent our runtime environmentOur processes will run inside a StatefulKnowledgeSessionUseful methods startProcess(String processId, Map parameters) signalEvent(String eventId, Object event, Long processId) For rules, insert, update, retract, fireAllRules() For events: getWorkingMemoryEntryPoint(String name)
  38. 38. We have learned ...jBPM5 is a BPMS that runs on top of Drools Expert (RuleEngine)Knowing the project library dependencies and the jBPM5artifact dependencies we can create our first jBPM5 projectUsing the Basic APIs we can set up easily our runtimeenvironmentStay tuned for the next modules that will explain importanttopics such as: The Business Process Management Discipline The Business Process Modeling and Notation V2 Human Interactions inside our processes etc.
  39. 39. Next ModulesStay tuned for the next modules that will explain importanttopics such as: The Business Process Management Discipline The Business Process Modeling and Notation V2 Human Interactions inside our processes etc.
  40. 40. Related LinksYou can find more information, examples, tutorials andmore in: Official documentation http://hudson.jboss. org/hudson/job/jBPM5/lastSuccessfulBuild/artifact/ target/jbpm-5.0-SNAPSHOT-docs-build/jbpm- docs/html/index.html Blog Athico: http://blog.athico.com Salaboy Blog http://salaboy.wordpress.com Plug Tree Blog http://www.plugtree.com
  41. 41. Enjoy! and be patient for the firstHands On Labs!
  42. 42.    Questions?
  43. 43.     Contact us atwww.plugtree.com

×