The Mess We’re (Still) In 🌈🧘 Unbounded Parallelism, True Names, & Keeping CALM 🎱✨
Slide 2
The Mess We’re (Still) In
Slide 3
The Mess We’re (Still) In
A distributed system is one in which the failure of a computer you didn’t even know existed can render your own computer unusable — Leslie Lamport
@FissionCodes Brooklyn Zelenka
Quinn Wilton
@expede
@wilton_quinn
•
CTO at Fission
•
Applied Researcher at Fission
•
Distributed auth, data, compute, and discovery
•
Building a planetary scale database for local-first apps
•
Author of Witchcraft, Algae, Exceptional, &c
•
Contributed to Lumen, Gleam, Burrito, Witchcraft, &c
Slide 24
@FissionCodes Brooklyn Zelenka
Quinn Wilton
@expede
@wilton_quinn
•
CTO at Fission
•
Applied Researcher at Fission
•
Distributed auth, data, compute, and discovery
•
Building a planetary scale database for local-first apps
•
Author of Witchcraft, Algae, Exceptional, &c
•
Contributed to Lumen, Gleam, Burrito, Witchcraft, &c
Slide 25
So Many
Problems 🪨🪐 🌌
Slide 26
Problems 🪨🪐🌌
High Level
Slide 27
Problems 🪨🪐🌌
High Level
Massive State Space
Slide 28
Problems 🪨🪐🌌
High Level
Massive State Space 2. Place Oriented Programming
Slide 29
Problems 🪨🪐🌌
High Level
Massive State Space 2. Place Oriented Programming 3. Dependencies, Limited APIs, Inconsistency
Slide 30
Problems 🪨🪐🌌
State Space is Big
Slide 31
Problems 🪨🪐🌌
State Space is Big Five 32-bit Numbers 32 5
(2 ) ≈ 10
48
Slide 32
Problems 🪨🪐🌌
State Space is Big Five 32-bit Numbers 32 5
48
(2 ) ≈ 10
🌍
atoms on Earth
Slide 33
Problems 🪨🪐🌌
State Space is Big Five 32-bit Numbers 32 5
48
(2 ) ≈ 10
🌍
atoms on Earth
Six 32-bit Numbers 32 6
(2 ) ≈ 10
57
Slide 34
Problems 🪨🪐🌌
State Space is Big Five 32-bit Numbers 32 5
48
(2 ) ≈ 10
Six 32-bit Numbers 32 6
57
(2 ) ≈ 10
🌍 🌞 🪐
🌍
🌒
atoms on Earth
atoms in solar system
Slide 35
Problems 🪨🪐🌌
State Space is Big Five 32-bit Numbers 32 5
48
(2 ) ≈ 10
Six 32-bit Numbers 32 6
57
(2 ) ≈ 10
🌍 🌞 🪐
🌍
🌒
atoms on Earth
atoms in solar system
Single Receiver (2
32+1 6
) × 6! ≈ 10
62
Slide 36
Problems 🪨🪐🌌
State Space is Big Five 32-bit Numbers 32 5
48
(2 ) ≈ 10
Six 32-bit Numbers 32 6
57
(2 ) ≈ 10
Single Receiver 32+1 6
(2
) × 6! ≈ 10
🌍 🌞 🌌 🪐
🌍
🌒
atoms on Earth
atoms in solar system
62
atoms in Milky Way
Slide 37
Problems 🪨🪐🌌
State Space is Big Five 32-bit Numbers 32 5
48
(2 ) ≈ 10
Six 32-bit Numbers 32 6
57
(2 ) ≈ 10
32+1 6
(2
🌍 🌞 🌌 🌍
🌒
atoms in solar system
62
) × 6! ≈ 10
🪐
atoms on Earth
Two Receivers
Single Receiver
atoms in Milky Way
((2
32+1 6
2
) × 6!) ≈ 10
124
Slide 38
Problems 🪨🪐🌌
State Space is Big Five 32-bit Numbers 32 5
48
(2 ) ≈ 10
Six 32-bit Numbers 32 6
57
(2 ) ≈ 10
Two Receivers
Single Receiver 32+1 6
(2
) × 6! ≈ 10
62
32+1 6
((2
2
124
) × 6!) ≈ 10
🌍 🌞 🌌 🤯 🪐
🌍
🌒
atoms on Earth
atoms in solar system
atoms in Milky Way
More than observable universe
Slide 39
Problems 🪨🪐🌌
Slide 40
Problems 🪨🪐🌌
Distributed systems introduce significant nondeterminism to our programs. Sources of non-determinism include unsynchronized parallelism, unreliable components, and networks with unpredictable delays. As a result, a distributed program can exhibit a large space of possible behaviors on a given input. — Hellerstein & Alvaro, Keeping CALM: When Distributed Consistency is Easy
Slide 41
Problems 🪨🪐🌌
The Great 73-Hour Roblox Outage of 2021
https://blog.roblox.com/2022/01/roblox-return-to-service-10-28-10-31-2021/ https://www.theverge.com/2021/10/30/22754107/roblox-down-outage-chipotle-server-issues-status
Slide 42
Problems 🪨🪐🌌
The Great 73-Hour Roblox Outage of 2021
https://blog.roblox.com/2022/01/roblox-return-to-service-10-28-10-31-2021/ https://www.theverge.com/2021/10/30/22754107/roblox-down-outage-chipotle-server-issues-status
Slide 43
Problems 🪨🪐🌌
The Great 73-Hour Roblox Outage of 2021
https://blog.roblox.com/2022/01/roblox-return-to-service-10-28-10-31-2021/ https://www.theverge.com/2021/10/30/22754107/roblox-down-outage-chipotle-server-issues-status
Slide 44
Problems 🪨🪐🌌
The Great 73-Hour Roblox Outage of 2021
👀
https://blog.roblox.com/2022/01/roblox-return-to-service-10-28-10-31-2021/ https://www.theverge.com/2021/10/30/22754107/roblox-down-outage-chipotle-server-issues-status
Slide 45
Problems 🪨🪐🌌
The Great 73-Hour Roblox Outage of 2021
🧨 👀
https://blog.roblox.com/2022/01/roblox-return-to-service-10-28-10-31-2021/ https://www.theverge.com/2021/10/30/22754107/roblox-down-outage-chipotle-server-issues-status
Slide 46
Problems 🪨🪐🌌
And Yet…
Slide 47
Problems 🪨🪐🌌
And Yet…
These metastable failures have caused widespread outages at large internet companies, lasting from minutes to hours. Paradoxically, the root cause of these failures is often features that improve the efficiency or reliability of the system. – Bronson et al, Metastable Failures in Distributed Systems
Slide 48
Problems 🪨🪐🌌
Metastable Mechanism
Slide 49
Problems 🪨🪐🌌
Metastable Mechanism
Slide 50
Problems 🪨🪐🌌
Metastable Mechanism
⚡
⚖
Slide 51
Problems 🪨🪐🌌
Metastable Mechanism
⚡
⚖
Slide 52
Problems 🪨🪐🌌
Metastable Mechanism
⚡
⚖
Slide 53
Problems 🪨🪐🌌
Metastable Mechanism
⚡
⚖
Slide 54
Problems 🪨🪐🌌
Metastable Mechanism
⚡
⚖
Slide 55
Problems 🪨🪐🌌
Metastable Mechanism
⚡
⚖
Slide 56
Problems 🪨🪐🌌
Metastable Mechanism
⚡
⚖
Slide 57
Problems 🪨🪐🌌
Metastable Mechanism
⚡
⚖
Slide 58
Problems 🪨🪐🌌
Metastable Mechanism
⚡
🛑
⚖
Slide 59
Problems 🪨🪐🌌
Metastable Mechanism
⚡
🛑
• Retries / let it crash • Work amplification
⚖
• General thrash 🫡
Slide 60
Problems 🪨🪐🌌
Places Fight
Light 💫🤺
Slide 61
Problems 🪨🪐🌌 Places Fight Light 💫🤺
Slide 62
Problems 🪨🪐🌌 Places Fight Light 💫🤺
The limitation of local knowledge is the fundamental fact about the setting in which we work, and it is a very powerful limitation – Nancy Lynch, A Hundred Impossibility Proofs for Distributed Computing
Slide 63
Problems 🪨🪐🌌 Places Fight Light 💫🤺
Sending a “Direct” Message
Slide 64
Problems 🪨🪐🌌 Places Fight Light 💫🤺
Sending a “Direct” Message
Slide 65
Problems 🪨🪐🌌 Places Fight Light 💫🤺
Sending a “Direct” Message
Problems 🪨🪐🌌 Data Behind Walls 🏰
Dependencies & Integration Bob’s Photo Gallery 🖼
💿
💾 Alice’s Music Player 🎶
📀 Carol’s Videogame 👾
Slide 74
Problems 🪨🪐🌌 Data Behind Walls 🏰
Inconsistency
Slide 75
Problems 🪨🪐🌌 Data Behind Walls 🏰
Inconsistency
• Even with FOSS!
Slide 76
Problems 🪨🪐🌌 Data Behind Walls 🏰
Inconsistency
• Even with FOSS! • Annual migration to the latest hipster HTTP client • HTTPotion → HTTPoison → Hackney → Tesla → Finch → Req
Slide 77
Problems 🪨🪐🌌 Data Behind Walls 🏰
Slide 78
Problems 🪨🪐🌌 Data Behind Walls 🏰
If people in a few hundred years from now want to see what their ancestors wrote, what will they find, a mess of badly formatted crap?! — Joe Armstrong, Why Markdown Sucks
Mental Framework 🏗🧠
What is the family of problems that can be consistently computed in a distributed fashion without coordination, and what problems lie outside that family? —Hellerstein & Alvaro, Keeping CALM: When Distributed Consistency is Easy
Slide 90
Mental Framework 🏗🧠
Gossiping Out of Order 🙊
Slide 91
Mental Framework 🏗🧠
Gossiping Out of Order 🙊
t→
🎨
Slide 92
Mental Framework 🏗🧠
Gossiping Out of Order 🙊 🟢
🎨
🔴
🟡
🔴
t→
🟢
🟢
🟡
Slide 93
Mental Framework 🏗🧠
Gossiping Out of Order 🙊 🟢
🎨
🔴
🟡
🔴
t→
🟢
🟢
🟡
Slide 94
Mental Framework 🏗🧠
Gossiping Out of Order 🙊 🟢
🎨
🔴
🟡
🔴
t→
🟢
🟢
🟡
Slide 95
Mental Framework 🏗🧠
Gossiping Out of Order 🙊 🟢
🎨
🔴
🟡
🔴
t→
🟢
🟢
🟡
Slide 96
Mental Framework 🏗🧠
Gossiping Out of Order 🙊 🟢
🎨
🔴
🟡
🔴
t→
🟢
🟢
🟡
Slide 97
Mental Framework 🏗🧠
Gossiping Out of Order 🙊 🟢
🎨
🔴
🟡
🔴
t→
🟢
🟢
🟡
❎
Towards a Solution ⚗✨
Evolving Toolbox Serverless Networked Data Cloud Commons Networks Local-First Blockchain
O
ffl
P2P
ine
Slide 120
Towards a Solution ⚗✨
Evolving Toolbox Serverless Networked Data
Radical shifts how we think about auth, locality of reference, ownership, and reliability
Cloud Commons Networks Local-First Blockchain
O
ffl
P2P
ine
Slide 121
Towards a Solution ⚗✨
Mutable Pointers send(:example@42.123.45.6, :ping) %{node_id => %{path => content}}
• Single-source server/client • DNS: hostname → IP address • PIDs: number → address • Focused: physical network
ff
• Referential opacity (same PID, di erent data)
Slide 122
Towards a Solution ⚗✨
Mutable Pointers send(:example@42.123.45.6, :ping) %{node_id => %{path => content}}
• Single-source server/client • DNS: hostname → IP address • PIDs: number → address
P H Y S I C A L L O C AT I O N 🗺
• Focused: physical network
ff
• Referential opacity (same PID, di erent data)
Slide 123
Towards a Solution ⚗✨
Mutable Pointers send(:example@42.123.45.6, :ping) %{node_id => %{path => content}}
• Single-source server/client • DNS: hostname → IP address • PIDs: number → address
V I R T UA L A D D R E S S 📬 P H Y S I C A L L O C AT I O N 🗺
• Focused: physical network
ff
• Referential opacity (same PID, di erent data)
Slide 124
Towards a Solution ⚗✨
Consistent Keys
%{hash(content) => content}
• Above virtual address • Focused: data itself • Same for everyone & everywhere • Perfect for caching • Immutable data++ • Consistent pointers → consistent data
V I R T UA L A D D R E S S 📬 P H Y S I C A L L O C AT I O N 🗺
Slide 125
Towards a Solution ⚗✨
Consistent Keys
%{hash(content) => content}
• Above virtual address • Focused: data itself • Same for everyone & everywhere • Perfect for caching • Immutable data++ • Consistent pointers → consistent data
CONTENT ID ☃ V I R T UA L A D D R E S S 📬 P H Y S I C A L L O C AT I O N 🗺
Slide 126
Towards a Solution ⚗✨
Hash-Based Relationships
Slide 127
Towards a Solution ⚗✨
Hash-Based Relationships
{
}
CID ~ Data PID Qm123456…: { data: nil, links: [ {name: “company”, hash: Qmabc…} {name: “industry”, hash: Qmzyx…} ] }
Towards a Solution ⚗✨
Decoupling, Abundance, Redundancy
Slide 132
Towards a Solution ⚗✨
Decoupling, Abundance, Redundancy
🖼
99.99999%
Slide 133
Towards a Solution ⚗✨
Decoupling, Abundance, Redundancy
🖼
99.99999%
🖼 99.0%
🖼
99.99%
🖼
99.999%
Slide 134
Towards a Solution ⚗✨
Decoupling, Abundance, Redundancy
🖼
99.99999%
🖼 99.0%
🖼
99.99%
🖼
99.999%
Slide 135
Towards a Solution ⚗✨
Decoupling, Abundance, Redundancy
🖼
99.99999%
👩🎤
🖼 99.0%
🖼
99.99%
🖼
99.999%
Slide 136
Towards a Solution ⚗✨
Decoupling, Abundance, Redundancy
🖼
99.99999%
👩🎤
🖼 99.0%
🖼
99.99%
🖼
99.999%
👩🎤 🧑🎤
Slide 137
Towards a Solution ⚗✨
Decoupling, Abundance, Redundancy
🖼
99.99999%
👩🎤
🖼 99.0%
🖼
99.99%
🖼
99.999%
👩🎤 🧑🎤
Slide 138
Towards a Solution ⚗✨
Decoupling, Abundance, Redundancy
🖼
99.99999%
👩🎤
🖼 99.0%
🖼
99.99%
🖼
99.999%
11-nines
👩🎤 🧑🎤
Slide 139
Towards a Solution ⚗✨
Reliability from Unreliable Components
Slide 140
Towards a Solution ⚗✨
Reliability from Unreliable Components
1
2
3
4
5
6
7
8
9
10
Slide 141
Towards a Solution ⚗✨
Downtime per Year (linear scale)
Reliability from Unreliable Components
1
2
3
4
5
6
#Independent Machines
7
8
9
10
Slide 142
Towards a Solution ⚗✨
Downtime per Year (linear scale)
Reliability from Unreliable Components 87 hours
1
2
3
4
5
6
#Independent Machines
7
8
9
10
Slide 143
Towards a Solution ⚗✨
Downtime per Year (linear scale)
Reliability from Unreliable Components 87 hours
52 mins
1
2
3
4
5
6
#Independent Machines
7
8
9
10
Slide 144
Towards a Solution ⚗✨
Downtime per Year (linear scale)
Reliability from Unreliable Components 87 hours
52 mins 32 sec
1
2
3
4
5
6
#Independent Machines
7
8
9
10
Slide 145
Towards a Solution ⚗✨
Downtime per Year (log scale)
Reliability from Unreliable Components 87 hours 103s 1s
10-6s 316 fs 10-12s
1
2
3
4
5
6
#Independent Machines
7
8
9
10
Slide 146
Towards a Solution ⚗✨
Downtime per Year (log scale)
Reliability from Unreliable Components 87 hours 103s 1s
10-6s 316 fs 10-12s
1
2
3
4
5
6
#Independent Machines
7
8
9
10
Slide 147
Towards a Solution ⚗✨
Downtime per Year (log scale)
Reliability from Unreliable Components 87 hours 2O
103s
rde
rs M agn itud
e/
1s
Ma chi n
e
10-6s 316 fs 10-12s
1
2
3
4
5
6
#Independent Machines
7
8
9
10
Slide 148
Towards a Solution ⚗✨
Why Sync Whole Tables?
Slide 149
Towards a Solution ⚗✨
Why Sync Whole Tables? user_id
username
company
start_date
inserted_at
1
expede
Fission
AUG-2019
FEB-2020
2
bmann
—
OCT-2020
Slide 150
Towards a Solution ⚗✨
Why Sync Whole Tables? user_id
username
company
start_date
inserted_at
1
expede
Fission
AUG-2019
FEB-2020
2
bmann
Towards a Solution ⚗✨
Relationships XYZ
Name: @expede
From JAN-2000
🔒 Work: Fission
From AUG-2019
KEB
🔒 Red Switches
Switches: Blue
From JAN-2020
From FEB-2020
Wireless
Slide 156
Towards a Solution ⚗✨
Relationships XYZ
Name: @expede
From JAN-2000
🔒 Work: Fission
From AUG-2019
KEB
🔒 Red Switches
Switches: Blue
From JAN-2020
From FEB-2020
Wireless
Slide 157
Towards a Solution ⚗✨
A Sequel to SQL: Nonlinear DBs XYZ
Name: @expede
From JAN-2000
ABC
Name: @bmann
From DEC-1999
KEB
Type: Wireless
Always
🔒
XYZ
Work: Fission
From AUG-2019
🔒
KEB
Switches: Red
From JAN-2020
KEB
Owner:XYZ
From JAN-2020
KEB
Switches: Blue
From FEB-2020
Slide 158
Towards a Solution ⚗✨
A Sequel to SQL: Nonlinear DBs XYZ
Name: @expede
From JAN-2000
ABC
Name: @bmann
From DEC-1999
KEB
Type: Wireless
Always
🔒
XYZ
Work: Fission
From AUG-2019
🔒
KEB
Switches: Red
From JAN-2020
KEB
Owner:XYZ
From JAN-2020
KEB
Switches: Blue
From FEB-2020
Slide 159
Towards a Solution ⚗✨
A Sequel to SQL: Nonlinear DBs XYZ
Name: @expede
From JAN-2000
ABC
Name: @bmann
From DEC-1999
KEB
Type: Wireless
Always
🔒
XYZ
Work: Fission
From AUG-2019
🔒
KEB
Switches: Red
From JAN-2020
KEB
Owner:XYZ
From JAN-2020
KEB
Switches: Blue
From FEB-2020
Slide 160
Towards a Solution ⚗✨
A Sequel to SQL: Nonlinear DBs XYZ
Name: @expede
From JAN-2000
ABC
Name: @bmann
From DEC-1999
KEB
Type: Wireless
Always
🔒
XYZ
Work: Fission
From AUG-2019
🔒
KEB
Switches: Red
From JAN-2020
KEB
Owner:XYZ
From JAN-2020
KEB
Switches: Blue
From FEB-2020
Slide 161
Towards a Solution ⚗✨
A Sequel to SQL: Nonlinear DBs XYZ
Name: @expede
From JAN-2000
ABC
Name: @bmann
From DEC-1999
KEB
Type: Wireless
Always
🔒
XYZ
Work: Fission
From AUG-2019
🔒
KEB
Switches: Red
From JAN-2020
KEB
Owner:XYZ
From JAN-2020
KEB
Switches: Blue
From FEB-2020
🏢
Slide 162
Towards a Solution ⚗✨
A Sequel to SQL: Nonlinear DBs XYZ
Name: @expede
From JAN-2000
ABC
Name: @bmann
From DEC-1999
KEB
Type: Wireless
Always
🔒
XYZ
Work: Fission
From AUG-2019
🔒
KEB
Switches: Red
From JAN-2020
KEB
Owner:XYZ
From JAN-2020
KEB
Switches: Blue
From FEB-2020
👩🚀📱
🏢
Slide 163
Towards a Solution ⚗✨
A Sequel to SQL: Nonlinear DBs XYZ
Name: @expede
From JAN-2000
ABC
Name: @bmann
From DEC-1999
KEB
Type: Wireless
Always
🔒
XYZ
Work: Fission
From AUG-2019
🔒
KEB
Switches: Red
From JAN-2020
👨🍳💻
KEB
Owner:XYZ
From JAN-2020
🏢
KEB
Switches: Blue
From FEB-2020
👩🚀📱
Slide 164
Towards a Solution ⚗✨
A Sequel to SQL: Nonlinear DBs ➡⬅
XYZ
Name: @expede
From JAN-2000
ABC
Name: @bmann
From DEC-1999
KEB
Type: Wireless
Always
🔒
XYZ
Work: Fission
From AUG-2019
🔒
KEB
Switches: Red
From JAN-2020
👨🍳💻
KEB
Owner:XYZ
From JAN-2020
🏢
KEB
Switches: Blue
From FEB-2020
👩🚀📱
Slide 165
Towards a Solution ⚗✨
Slide 166
Towards a Solution ⚗✨
With over 1.5 million publications per year and more than 50 million total peer-reviewed articles, the rate and volume of novel discoveries has surpassed our ability to fully utilize and understand what is known – William E. Byrd et al, mediKanren: a System for Biomedical Reasoning
Slide 167
Towards a Solution ⚗✨
Standardized Knowledge Graphs
Slide 168
Towards a Solution ⚗✨
Data Integration
Slide 169
Towards a Solution ⚗✨
Data Integration
Slide 170
Towards a Solution ⚗✨
Data Integration
Slide 171
Towards a Solution ⚗✨
Data Integration
Slide 172
Towards a Solution ⚗✨
Data Integration
Slide 173
Towards a Solution ⚗✨
Data Integration
Slide 174
Towards a Solution ⚗✨
Data Integration
Slide 175
Towards a Solution ⚗✨
Data Integration
A ‘high-speed Dr. House’ for medical breakthroughs – University of Alabama News, on mediKanren
Slide 176
Your Turn
Call to Action 🦸
Slide 177
Call to Action 🦸
Slide 178
Call to Action 🦸
We have a system that applies cutting edge CS research to tackle day-to-day problems in the applications we all write. Phoenix Presence - has no single point of failure - has no single source of truth -[…] - self heals ~ Chris McCord, “What Makes Phoenix Presence Special”
Slide 179
Call to Action 🦸
Next Steps
Slide 180
Call to Action 🦸
Next Steps 1. Embrace the distributed nature of the network 🫂
Slide 181
Call to Action 🦸
Next Steps 1. Embrace the distributed nature of the network 🫂 2. Put data into interoperable forms
Slide 182
Call to Action 🦸
Next Steps 1. Embrace the distributed nature of the network 🫂 2. Put data into interoperable forms 3. Better living through replication