Upload
others
View
9
Download
0
Embed Size (px)
Citation preview
With an open source workflow engine
Decoupling your Spring boot Microservices
With an open source workflow engine
Orchestrating Spring Boot Microservices(In order to get coffee quickly)
Niall Deehan Grifty Winters
4
A Classic Distributed System
4
Service One Service TwoRest
Response
5
A Classic Distributed System
5
Service One Service Two Service ThreeRest
Response
Rest
Response
6Photo by John Ingle
7Photo by John Ingle
8
9Photo by John Ingle
Congratulations! You’ve got a coffee
10
Who’s next?
11
Things to think about?
• Barista takes a break• Order is taking while• “We don’t do mochachinos”
12
Starbucks does not use two-phase commit
Gregor Hohpehttps://www.enterpriseintegrationpatterns.com/ramblings/18_starbucks.html
13Photo by John Ingle
14Photo by John Ingle
15
The System of Kaffee und Kuchen
15
Cashier:Takes orders
Order Sorter:Can get Cake!
Barista:Makes Coffee
Order
Coffee Ready
Coffee
Complete
Demo!
16
https://github.com/NPDeehan/kaffee-und-kuchen
17
Lets Make some changes to our system
18
What needs to change?
18
Cashier:Takes orders
Order Sorter:Can get Cake!
Barista:Makes Coffee
Order
Coffee Ready
Coffee
Complete
We Need to Hold State
● Retry● Timeout● Callback to Cashier● Versioning● Error Handling
19
Live coding!
https://github.com/NPDeehan/kaffee-und-kuchen
20
Lets deal with the issues
• What happens if the barista is taking a quick break?• Hold State until the barista is back
• What happens if the order is taking too long?• Let the customer know we’re still working on it
• What happens if the order can’t be completed for business reasons - not technical reasons?• BPMN Error event!
21
Things to think about?
• Barista takes a break• Order is taking while• “We don’t do mochachinos”
22
Live coding!
https://github.com/NPDeehan/kaffee-und-kuchen
23
What did we Achieve
• Better throughput• Better error handling• Scale better• Visualization• Timer(?)• Saga(?)
24
What needs to change?
24
Cashier:Takes orders
Order Sorter:Can get Cake!
Barista:Makes Coffee
Order
Coffee Ready
Coffee
Complete
● Retry● Timeout● Callback to Cashier● Versioning● Error Handling
We Need to Hold State
Visualization!
25
26
start.camunda.com
THE END
27