Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Workshop WSO2 BPS 3.5.x - BPMN

487 views

Published on

This workshop is to demonstrate the basic BPMN capabilities inside WSO2 BPS 3.5.x

Published in: Technology
  • Be the first to comment

Workshop WSO2 BPS 3.5.x - BPMN

  1. 1. WSO2 BPS 3.5 Partner Foundations Workshop BPMN Chapter Edgar Silva @jedgarsilva
  2. 2. Foundation o WSO2 BPS 3.5 - BPMN Capabilities o Summary: o Rely on Apache project: Activiti BPMN o Historical background: o Tom Bayens (former jBPM founder/leader) o Supported as well for other organzations o Activiti on Steroids o Multitenant o Clustering o Rich REST API o etc
  3. 3. Installation o As easy as any WSO2 Product o Download o Unzip o Run (BPS_UNZIPED_FOLDER/bin/wso2server.sh)
  4. 4. Deployed applications o Carbon (Management Console) o Human Task Explorer o BPMN Explorer
  5. 5. Deployed applications o Carbon (Management Console)
  6. 6. Deployed applications o Human Task Explorer -https://127.0.0.1:9443/humantask-explorer
  7. 7. Deployed applications o BPMN Explorer : https://127.0.0.1:9443/bpmn-explorer
  8. 8. Deployed applications o BPMN Explorer : https://127.0.0.1:9443/bpmn-explorer
  9. 9. Deployed applications o BPMN Explorer : https://127.0.0.1:9443/bpmn-explorer
  10. 10. Creating your first workflow process
  11. 11. Before your start o You must have the latest Activiti Plugin installed into your eclipse: o http://activiti.org/designer/update/
  12. 12. Take a look on what we will do ….
  13. 13. A customer want to open a bank account Fulfil data (Form) check initial deposit > amount X Notify customer
  14. 14. Process Explanation 
 (When process is well designed, that is useless) o A customer want to open an account into our thin bank o According the initial process, that customer will be managed by a different customer level (platinum or standard). o In the end the customer will discover who is your account manager, that will be the responsible for the whole relationship o That last step/interaction will be made via e-mail
  15. 15. Create a new project 1. Create an Activiti Project called thinbank-bpm 2. Follow the basic instructions for creating the project (source destination, package etc) 3. Create an Activiti Diagram called open- account.bpmn 18
  16. 16. Configuring Process default metadata o Please click on the diagram and set the properties according the image on this slide. 19
  17. 17. Start Node o That is the first step in the process. o From the Palette, just add that start node o Click on the start node and set the following properties 20
  18. 18. Start Node o Now Click on the Form tab and add the following properties accordingly: 21
  19. 19. Checkpoint 1 : What had you made so far… o You configured which will be the initial variables available for instantiate a new process instance. o Those variables will be presented into a form, that can be rendered in WSO2 BPS 3.5.x
  20. 20. Basics : Process Instance o Class vs Object o Definition vs Instance 23 Process Definition Process Instances name: Jorge Santana name: Elvis Presley name: Mano Brown
  21. 21. Creating Sequence Flows o Between each step in the process, you will need a sequence-flow (arrow) representing the flow. o It might be added from the components palette o or: 24
  22. 22. Creating Sequence Flows o In the next step we will create an exclusive gateway node. o So click on exclusive and drag to your right in the canvas. 25
  23. 23. Creating Exclusive Gateway o Please add the following properties 26
  24. 24. Creating Exclusive Gateway o Please add the following properties 27
  25. 25. Creating Exclusive Gateway o An exclusive gateway defines the possible next steps, according some variable or event. o It is similar to a Case or IF according to the scenarios o In our sample, we will have 2 possible ways: o A Human Task for Default Account or o If the Initial Deposit Amount is larger than <A value> it goes to Premium Account o In that case we will 2 possible next steps according a variable 28
  26. 26. Creating the Default Account Human Task o Please fill the following properties: o Name: Default Account o Click on Main Config tab and add the following value on Candidate Group: “default- managers" o Click on Form Tab and add the the properties according next slide
  27. 27. Add the following Form Properties o Note: Just take a look on properties that are writable or not (read only props), that ones were informed by the “customer" in previous step.
  28. 28. Now: Creating the Premium Account Human Task o Name: Premium Account o Candidate Group: premium-managers o Here the form: 

  29. 29. From Exclusive Gateway, how the process knows to where navigate? o One of the sequence- flows will be the default one. o And the other will be activated/executed when and just when the (condition) variable initialDeposit is greater than 10,000
  30. 30. From Exclusive Gateway, how the process knows to where navigate? o One of the sequence-flows will be the default one. o And the other will be activated/executed when and just when the (condition) variable initialDeposit is greater than 10,000
  31. 31. From Exclusive Gateway, how the process knows to where navigate? o In that sequence flow that lands on Premium Account Human Task, you will add in the Main config tab the following condition: 
 ${initialDeposit>10000} o So based on the value on the initialDeposit process instance variable, we will go to Premium or Default Account.
  32. 32. Email Task o The step before finish that process sample is to send and email to the customer.
  33. 33. Email Task o The step before finish that process sample is to send and email to the customer. o Keep in mind that you have to configure BPS for sending e-mails: https:// docs.wso2.com/display/ BPS351/Working+with+the +Email+Task
  34. 34. Finish : End Node
  35. 35. Deploying Process
  36. 36. Exporting Process to an Archive (zip) o It will generate a zip file. o After that rename the file for .bar
  37. 37. Deploying Process in BPS Console
  38. 38. Process Instance
  39. 39. BPMN REST api
  40. 40. Accessing the whole process context via REST Testing via Postman https://192.168.1.135:9443/bpmn/runtime/process-instances https://<SEU IP>:<PORTA>/bpmn/runtime/process-instances 

  41. 41. Accessing the whole process context via REST Testing via Postman https://192.168.1.135:9443/bpmn/runtime/process-instances https://<SEU IP>:<PORTA>/bpmn/runtime/process-instances 

  42. 42. For more info on this o See that reference: o https://docs.wso2.com/display/BPS351/BPMN +REST+API
  43. 43. Comments, questions: @jedgarsilva More information: www.wso2.com

×