BPMN for REST

5,742 views

Published on

BPMN for REST paper presented at the 3rd International Workshop on BPMN, 21.11.2011, Luzerne, Switzerland

Published in: Technology
1 Comment
8 Likes
Statistics
Notes
No Downloads
Views
Total views
5,742
On SlideShare
0
From Embeds
0
Number of Embeds
132
Actions
Shares
0
Downloads
0
Comments
1
Likes
8
Embeds 0
No embeds

No notes for slide

BPMN for REST

  1. 1. BPMN for RESTCesare PautassoFaculty of Informatics, USI Lugano, Switzerlandc.pautasso@ieee.orghttp://www.pautasso.info@pautasso21.11.2011
  2. 2. BPM REST©2010 - Cesare Pautasso 3
  3. 3. Business RESTful Process Web Services Management©2010 - Cesare Pautasso 4
  4. 4. WS-* Standards Stack©2009-2010 - Cesare Pautasso - 30.6.2010 5
  5. 5. WS-* Standards Stack BPM Management Interoperability Metadata Reliability Transactions Security State Messaging©2009-2010 - Cesare Pautasso - 30.6.2010 6
  6. 6. BPM Management Interoperability Metadata Reliability Transactions Security State Messaging Can you do it with REST?©2010 - Cesare Pautasso 7
  7. 7. RESTful APIs…©2011 - Cesare Pautasso 8
  8. 8. RESTful APIs…©2011 - Cesare Pautasso 9
  9. 9. From REST-* “ We believe there is huge potential to marrying REST with workflow and BPM. http://www.jboss.org/reststar/specifications/workflow.html […] Combined with the architecture of the Web, a workflow service can provide both a truly simple, portable, and flexible way to build workflow driven integrations and ” applications.©2011 - Cesare Pautasso 10
  10. 10. BPM REST resource resource©2010 - Cesare Pautasso 11
  11. 11. REST in one slide  Web Services expose their data and functionality trough PUT resources identified by URI R  Uniform Interface constraint: GET Clients interact with resources POST through a fix set of verbs. DELETE Example HTTP: GET (read), POST (create), PUT (update), DELETE  Multiple representations for the same resource  Hyperlinks model resource relationships and valid state transitions for dynamic protocol description and discovery©2011 - Cesare Pautasso 12
  12. 12. From REST-* “ We believe there is huge potential to marrying REST with workflow and BPM. http://www.jboss.org/reststar/specifications/workflow.html  The HATEOAS (hypermedia and linking) principal of REST is logically a dynamic state machine and fits very well with how workflow and BPM systems are designed.  Combined with the architecture of the Web, a workflow service can provide both a truly simple, portable, and flexible way to build workflow driven integrations and applications.©2011 - Cesare Pautasso 13
  13. 13. BPMN Levels From Bruce Silver 1.Descriptive Modeling 2.Analytical Modeling 3.Executable Modeling©2011 - Cesare Pautasso 14
  14. 14. BPMN Primitives Web Service Service Task Web Service Send/Receive Task©2011 - Cesare Pautasso 15
  15. 15. REST as a new connector RPC BUS Publish/Subscribe Call REST/HTTP Get/Put/Post/Delete©2010 - Cesare Pautasso 16
  16. 16. Outline 1. Goal: use a business process model to:  orchestrate a set of distributed resources  specify the behavior of stateful resources 2. BPMN for REST Extension  Resource Symbol  Invoking external resources  Publishing process elements as resources 3. Examples©2011 - Cesare Pautasso 17
  17. 17. Modeling questions  Which are the resources that a process depends upon for a successful execution?  Which are the resources that are affected by the execution of a process?  Can we reason about the behavior of stateful resources using a process model?  Which are the tasks of a process that have been made accessible to clients as a resource?  Which are the possible requests that can be sent to a resource whose behavior is specified by a process?©2011 - Cesare Pautasso 18
  18. 18. BPMN 2.0 Notation©2011 - Cesare Pautasso 19
  19. 19. REST Triangle Resources Representations (Multiple,(Multiple, Negotiable)Globally Addressable) R (Fixed, Uniform Interface) Verbs©2011 - Cesare Pautasso 20
  20. 20. Resource Icon R©2011 - Cesare Pautasso 21
  21. 21. Resource Icon and Tasks Task published as a resource©2011 - Cesare Pautasso 22
  22. 22. Resource Icon and Events Resource Request Event Signal (BPMN for REST) (BPMN 2.0)©2011 - Cesare Pautasso 23
  23. 23. Resource Icon and Data External Resource (RESTful Datastore)©2011 - Cesare Pautasso 24
  24. 24. Invoking External Resources GET PUT DELETE POST Message Flows (Visualize the semantics of the HTTP method) External Resources: (Resource lifecycle is independent of process instance)©2011 - Cesare Pautasso 25
  25. 25. Abstraction GET message flow Synchronous RPC with external resource with participant lane (BPMN for REST) (BPMN)©2011 - Cesare Pautasso 26
  26. 26. Publishing X as Resources Process Task published as resource published as resource©2011 - Cesare Pautasso 27
  27. 27. Publishing X as Resource SubProcess published as resource©2011 - Cesare Pautasso 28
  28. 28. Publish Process as Resource List the GET /process deployed Get a form processes describing how GET /process/name to start the process Start a new POST /process/name process instance Check what is the state GET /process/name/instance of the instance DELETE /process/name/instance Clean up (once it is done)©2010 - Cesare Pautasso 29
  29. 29. Publish Task as Resource List links to the active tasks GET /task instances Get a form describing how GET /task/name/instance to interact with the task Complete a PUT /task/name/instance task Retrieve final GET /task/name/instance state of task©2010 - Cesare Pautasso 30
  30. 30. Publishing X as Resource©2011 - Cesare Pautasso 31
  31. 31. Handling Resource Requests The event models the arrival of a specific resource request method©2011 - Cesare Pautasso 32
  32. 32. Local Search Mashup©2011 - Cesare Pautasso 33
  33. 33. Loan Approval Example©2011 - Cesare Pautasso 34
  34. 34. RESTBucks Example ©2011 - Cesare Pautasso 35
  35. 35. Conclusion  RESTful business process can be modeled using our simple BPMN for REST notation extension  Processes interact with external resources (e.g., Web 2.0 APIs) which are fully decoupled from their lifecycle  Processes publish their state as a resource:  Entire Tasks and SubProcesses  Use Events to model Resource Requests  The graphical syntax and extended semantics of BPMN for REST was only informally sketched, more work is needed to specify the XML meta- model for the extension and its formal semantics©2011 - Cesare Pautasso 36
  36. 36. 10th International Conference on Business Process Management (BPM 2012) September 3-6 2012, Tallinn, Estonia http://bpm2012.ut.ee©2010 - Cesare Pautasso 37
  37. 37. 16-20 April 2012, Lyon, France http://ws-rest.org/2012©2010 - Cesare Pautasso 38
  38. 38. PhD Positions Available Cesare Pautasso http://www.pautasso.info/ @pautasso©2011 Cesare Pautasso 39
  39. 39. Raj Balasubramanians, Benjamin Carlyle, Thomas Erl, Cesare Pautasso, SOA with REST, Prentice Hall, 2012 http://soabooks.com/rest/©2011 - Cesare Pautasso 40

×