Decoupling your Spring boot Microservices With an open source - - PowerPoint PPT Presentation

decoupling your spring boot microservices
SMART_READER_LITE
LIVE PREVIEW

Decoupling your Spring boot Microservices With an open source - - PowerPoint PPT Presentation

Decoupling your Spring boot Microservices With an open source workflow engine Orchestrating Spring Boot Microservices (In order to get coffee quickly) With an open source workflow engine Grifty Winters n a h e e D l l a i N 4 A


slide-1
SLIDE 1

With an open source workflow engine

Decoupling your Spring boot Microservices

slide-2
SLIDE 2

With an open source workflow engine

Orchestrating Spring Boot Microservices (In order to get coffee quickly)

slide-3
SLIDE 3

N i a l l D e e h a n Grifty Winters

slide-4
SLIDE 4

4

A Classic Distributed System

4

Service One Service Two Rest Response

slide-5
SLIDE 5

5

A Classic Distributed System

5

Service One Service Two Service Three Rest Response Rest Response

slide-6
SLIDE 6

6

Photo by John Ingle

slide-7
SLIDE 7

7

Photo by John Ingle

slide-8
SLIDE 8

8

slide-9
SLIDE 9

9

Photo by John Ingle

slide-10
SLIDE 10

Congratulations! You’ve got a coffee

10

Who’s next?

slide-11
SLIDE 11

11

Things to think about?

  • Barista takes a break
  • Order is taking while
  • “We don’t do mochachinos”
slide-12
SLIDE 12

12

Starbucks does not use two-phase commit

Gregor Hohpe

https://www.enterpriseintegrationpatterns.com/ramblings/18_starbucks.html

slide-13
SLIDE 13

13

Photo by John Ingle

slide-14
SLIDE 14

14

Photo by John Ingle

slide-15
SLIDE 15

15

The System of Kaffee und Kuchen

15

Cashier: Takes orders Order Sorter: Can get Cake! Barista: Makes Coffee Order Coffee Ready Coffee Complete

slide-16
SLIDE 16

Demo!

16

https://github.com/NPDeehan/kaffee-und-kuchen

slide-17
SLIDE 17

17

Lets Make some changes to our system

slide-18
SLIDE 18

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
slide-19
SLIDE 19

19

Live coding!

https://github.com/NPDeehan/kaffee-und-kuchen

slide-20
SLIDE 20

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!
slide-21
SLIDE 21

21

Things to think about?

  • Barista takes a break
  • Order is taking while
  • “We don’t do mochachinos”
slide-22
SLIDE 22

22

Live coding!

https://github.com/NPDeehan/kaffee-und-kuchen

slide-23
SLIDE 23

23

What did we Achieve

  • Better throughput
  • Better error handling
  • Scale better
  • Visualization
  • Timer(?)
  • Saga(?)
slide-24
SLIDE 24

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

slide-25
SLIDE 25

Visualization!

25

slide-26
SLIDE 26

26

start.camunda.com

slide-27
SLIDE 27

THE END

27