Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Level Triggered and Reconciled: How Kubernetes ...
Search
James Bowes
May 16, 2018
Technology
0
110
Level Triggered and Reconciled: How Kubernetes Manages its State
James Bowes
May 16, 2018
Tweet
Share
More Decks by James Bowes
See All by James Bowes
Write Once, Compile Lots, Run Anywhere
jbowes
0
170
A Token Of Respect: Implementing Microservice Identity And Access Management In Go
jbowes
0
210
Shattered Mirror: An Introduction to Reflect and Unsafe
jbowes
0
36
Shattered Mirror: An Introduction to Reflect and Unsafe
jbowes
0
1.4k
Cloud Jumping With Kubernetes
jbowes
0
89
Building APIs for an unreliable world
jbowes
0
57
API Design Lessons From Kubernetes
jbowes
0
89
CL_Eye-Catching_User_Interfaces.pdf
jbowes
0
47
Higher-Order Deployments: Reducing Boilerplate With Kubernetes Custom Resource Definitions
jbowes
0
49
Other Decks in Technology
See All in Technology
20250705 Headlamp: 專注可擴展性的 Kubernetes 用戶界面
pichuang
0
240
生成AI時代 文字コードを学ぶ意義を見出せるか?
hrsued
1
810
マネジメントって難しい、けどおもしろい / Management is tough, but fun! #em_findy
ar_tama
7
910
モバイル界のMCPを考える
naoto33
0
420
Flutter向けPDFビューア、pdfrxのpdfium WASM対応について
espresso3389
0
130
面倒な作業はAIにおまかせ。Flutter開発をスマートに効率化
ruideengineer
0
210
CursorによるPMO業務の代替 / Automating PMO Tasks with Cursor
motoyoshi_kakaku
2
930
改めてAWS WAFを振り返る~業務で使うためのポイント~
masakiokuda
2
240
React開発にStorybookとCopilotを導入して、爆速でUIを編集・確認する方法
yu_kod
1
230
Lambda Web Adapterについて自分なりに理解してみた
smt7174
6
160
Understanding_Thread_Tuning_for_Inference_Servers_of_Deep_Models.pdf
lycorptech_jp
PRO
0
180
KubeCon + CloudNativeCon Japan 2025 Recap by CA
ponkio_o
PRO
0
290
Featured
See All Featured
Product Roadmaps are Hard
iamctodd
PRO
54
11k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
138
34k
VelocityConf: Rendering Performance Case Studies
addyosmani
332
24k
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
3.9k
The Pragmatic Product Professional
lauravandoore
35
6.7k
Practical Orchestrator
shlominoach
188
11k
Done Done
chrislema
184
16k
Mobile First: as difficult as doing things right
swwweet
223
9.7k
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
35
2.4k
Faster Mobile Websites
deanohume
307
31k
The Cost Of JavaScript in 2023
addyosmani
51
8.5k
A Tale of Four Properties
chriscoyier
160
23k
Transcript
@jrbowes Level-Triggered and Reconciled How Kubernetes Manages its State
@jrbowes @jrbowes Photo by Stefan Steinbauer on Unsplash STUDY TIME
@jrbowes https://www.manifold.co Say hi at our booth! James Bowes Technical
Lead
@jrbowes @jrbowes Photo by Maximilian Weisbecker on Unsplash KUBERNETES?
@jrbowes @jrbowes
@jrbowes @jrbowes
@jrbowes @jrbowes
@jrbowes @jrbowes
@jrbowes @jrbowes Photo by Gamze Bozkaya on Unsplash THE CLIENT
API
@jrbowes @jrbowes
@jrbowes @jrbowes
@jrbowes @jrbowes
@jrbowes @jrbowes Photo by Jakob Owens on Unsplash PATCHING
@jrbowes JSON Merge Patch • Plain JSON document only containing
changes • Declarative and simple • RFC 7386
@jrbowes JSON Merge Patch ... metadata: labels: service: worker app:
marketplace spec: containers: - image: manifold/worker:1.31.18 name: worker
@jrbowes JSON Merge Patch metadata: labels: service: billing-worker spec: containers:
- image: manifold/sidecar:1.0.0 name: metrics
@jrbowes JSON Merge Patch ... metadata: labels: service: billing-worker app:
marketplace spec: containers: - image: manifold/sidecar:1.0.0 name: metrics
@jrbowes JSON Merge Patch ... metadata: labels: service: billing-worker app:
marketplace spec: containers: - image: manifold/sidecar:1.0.0 name: metrics
@jrbowes JSON Merge Patch • Objects are always merged •
Arrays are always replaced • No explicit null See also JSON Patch (RFC 6902) - Verbose and complex
@jrbowes Strategic Merge Patch • Adds replace, merge, delete for
objects and arrays • Merge keys for array elements • Schema defined defaults • Client directive overrides
@jrbowes Strategic Merge Patch ... metadata: labels: service: worker app:
marketplace spec: containers: - image: manifold/worker:1.31.18 name: worker
@jrbowes Strategic Merge Patch spec: containers: - image: manifold/sidecar:1.0.0 name:
metrics
@jrbowes Strategic Merge Patch ... spec: containers: - image: manifold/worker:1.31.18
name: worker - image: manifold/sidecar:1.0.0 name: metrics
@jrbowes Strategic Merge Patch ... spec: containers: - image: manifold/worker:1.31.18
name: worker - image: manifold/sidecar:1.0.0 name: metrics
@jrbowes Strategic Merge Patch spec: containers: - image: manifold/sidecar:1.0.0 name:
metrics - $patch: replace
@jrbowes lastAppliedConfiguration PROVIDES RICH CONTEXT
@jrbowes PRESERVE THE INTENT OF EVERY CLIENT
@jrbowes @jrbowes Photo by Gamze Bozkaya on Unsplash THE INTERNAL
MODEL
@jrbowes @jrbowes
@jrbowes @jrbowes
@jrbowes @jrbowes
@jrbowes @jrbowes
@jrbowes @jrbowes Photo by David Kovalenko on Unsplash LOST DATA
@jrbowes @jrbowes
@jrbowes @jrbowes
@jrbowes @jrbowes
@jrbowes @jrbowes
@jrbowes @jrbowes Photo by Fabrizio Verrecchia on Unsplash SLOW REACTIONS
@jrbowes @jrbowes
@jrbowes @jrbowes
@jrbowes @jrbowes Photo by Matt Artz on Unsplash PREVENTION AND
REPAIR
@jrbowes Lost Intermediate Data • Edge triggered ◦ Track last
seen revision number ◦ Perform a resync on missing version • Not an issue for level triggered
@jrbowes Stale Data • Heartbeat • Periodic resync (done in
Kubernetes)
@jrbowes Slow Reactions • Edge triggered ◦ Keep state for
last value ◦ Compute change to apply with real value, last seen, and changed • Not an issue for level triggered
@jrbowes @jrbowes
@jrbowes KEEP THE CONSUMER LOGIC SIMPLE
@jrbowes @jrbowes Photo by Hans-Peter Gauster on Unsplash PIECING IT
TOGETHER
@jrbowes Controllers are Clients, too • resourceVersion is used for
watching • Controllers may implement their own lastAppliedConfiguration • Different annotations allow unique targeting
@jrbowes TCP implementations should follow a general principle of robustness:
be conservative in what you do, be liberal in what you accept from others. - Jon Postel, RFC 761
@jrbowes be exhaustive in what you send, be explicit in
what you receive from others.
@jrbowes @jrbowes Photo by Annie Spratt on Unsplash WRAPPING UP
@jrbowes @jrbowes Photo by Michael Hoyt on Unsplash COLOCATE COMPLEX
LOGIC WITH STATE
@jrbowes @jrbowes Photo by Roman Koester on Unsplash IDENTIFY THE
AUDIENCE AND BUILD FOR THEM
@jrbowes @jrbowes Photo by Andrés Canchón on Unsplash MAKE IT
HARD FOR THE AUDIENCE TO FAIL
@jrbowes Thank you!