In this presentation by Jonas Bonér, creator of Akka and founder/CTO of Lightbend, we review a set of eight Reactive Principles that enable the design and implementation of Cloud Native applications–applications that are highly concurrent, distributed, performant, scalable, and resilient, while at the same time conserving resources when deploying, operating, and maintaining them.
10. Addresses the challenges of distributed systems directly
in its abstractions, programming/data models,
protocols, interaction schemes, and error handling
Reactive shows the way
The Reactive Application
11. Addresses the challenges of distributed systems directly
in its abstractions, programming/data models,
protocols, interaction schemes, and error handling
Not as an afterthought
not as operational or infrastructure problems
that are dealt with via increasingly complex tech stacks,
wrappers, workarounds, and leaky abstractions
Reactive shows the way
The Reactive Application
17. Introducing the
Reactive Principles
I. Stay Responsive
II. Accept Uncertainty
III. Embrace Failure
IV. Assert Autonomy
https://principles.reactive.foundation
18. Introducing the
Reactive Principles
I. Stay Responsive
II. Accept Uncertainty
III. Embrace Failure
IV. Assert Autonomy
V. Tailor Consistency
https://principles.reactive.foundation
19. Introducing the
Reactive Principles
I. Stay Responsive
II. Accept Uncertainty
III. Embrace Failure
IV. Assert Autonomy
V. Tailor Consistency
VI. Decouple Time
https://principles.reactive.foundation
20. Introducing the
Reactive Principles
I. Stay Responsive
II. Accept Uncertainty
III. Embrace Failure
IV. Assert Autonomy
V. Tailor Consistency
VI. Decouple Time
VII. Decouple Space
https://principles.reactive.foundation
21. Introducing the
Reactive Principles
I. Stay Responsive
II. Accept Uncertainty
III. Embrace Failure
IV. Assert Autonomy
V. Tailor Consistency
VI. Decouple Time
VII. Decouple Space
VIII. Handle Dynamics
https://principles.reactive.foundation
24. It’s easy to stay responsive
during “Blue sky” scenarios
25. But it’s equally important to
stay responsive in the face of
failures, communication outages,
and unpredictable workloads
27. “An escalator can never break:
it can only become stairs.
You should never see an
Escalator Temporarily Out Of Order sign,
just Escalator Temporarily Stairs.
Sorry for the convenience.”
- Mitch Hedberg
37. We Need To Model and manage
Uncertainty
Directly In The Application Architecture
38. “In a system which cannot count
on distributed transactions, the
management of uncertainty must be
implemented in the business logic.”
- Pat Helland
Life Beyond Distributed Transactions - An Apostate’s Opinion, Pat Helland (2007)
We Need To Model and manage
Uncertainty
Directly In The Application Architecture
47. Decoupling in space
allows the failure to be kept inside
designated failure zones (bulkheads)
Decoupling in time
enables other components to reliably detect
and handle failures even when they cannot
be explicitly communicated
48. Failures Need To Be
1. Contained—Avoid cascading failures
2. Reified—as values
3. Signalled—Asynchronously
4. Observed—by 1-N
5. Managed—Outside failed Context
55. A system of distributed services is a
never-ending stream towards convergence
56. A system of distributed services is a
never-ending stream towards convergence
Always in the process of convergence
Never reaching the state of convergence
57. There Is No Now
A system of distributed services is a
never-ending stream towards convergence
Always in the process of convergence
Never reaching the state of convergence
58. Think In Terms Of Consistency Boundaries
Small islands of strong consistency in a
river of constant change and uncertainty
59. Data on the inside vs Data on the outside - Pat Helland
60. Inside Data
Our current present state
Data on the inside vs Data on the outside - Pat Helland
61. Inside Data
Our current present state
Outside Data
Blast from the past facts
Data on the inside vs Data on the outside - Pat Helland
62. Inside Data
Our current present state
Outside Data
Blast from the past facts
Between Services
Hope for the future commands
Data on the inside vs Data on the outside - Pat Helland
63. “Autonomy makes information local,
leading to greater certainty and stability.”
- Mark Burgess
In Search of Certainty - Mark Burgess
88. Embrace The Network
✓Make distribution first class
• Avoid the mistakes of EJB, CORBA,
or Network Attached Disks
89. Embrace The Network
✓Make distribution first class
• Avoid the mistakes of EJB, CORBA,
or Network Attached Disks
✓Go Async
• Use Asynchronous IO
• Use Message-Passing
90. Embrace The Network
✓Make distribution first class
• Avoid the mistakes of EJB, CORBA,
or Network Attached Disks
✓Go Async
• Use Asynchronous IO
• Use Message-Passing
✓Leverage Location Transparency
• Mobility, Virtual Addressing
100. The Reactive Principles
I. Stay Responsive
II. Accept Uncertainty
III. Embrace Failure
IV. Assert Autonomy
V. Tailor Consistency
VI. Decouple Time
VII. Decouple Space
VIII. Handle Dynamics
101. Reactive Patterns
1. Partition State
2. Communicate Facts
3. Isolate Mutations
4. Coordinate Dataflow
5. Localize State
6. Observe Communications
7. TBD (help out)
We also have a growing catalog of