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
Kuiperbelt - Asynchronous protocol proxy
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
mackee
November 21, 2015
Programming
84
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Kuiperbelt - Asynchronous protocol proxy
mackee
November 21, 2015
More Decks by mackee
See All by mackee
Go1.27で導入されるジェネリクスメソッドでできること
mackee
0
320
perlをWebAssembly上で動かすと何が嬉しいの??? / Where does Perl-on-Wasm actually make sense?
mackee
0
1.1k
Agentに至る道 〜なぜLLMは自動でコードを書けるようになったのか〜
mackee
6
6k
今!ソフトウェアエンジニアがハードウェアに手を出すには
mackee
14
7.2k
ワンバイナリWebサービスのススメ
mackee
10
8.9k
tanukistack ライブコーディング / tanukistack live-coding
mackee
0
730
range over funcの使い道と非同期N+1リゾルバーの夢 / about a range over func
mackee
0
1.2k
perl for shell, awk and sed programmers
mackee
3
2.9k
今更GoのWebフレームワークを作ろうとしているワケ / Why am I trying to create a Go web framework now?
mackee
1
1.1k
Other Decks in Programming
See All in Programming
えっ!!コードを読まずに開発を!?
hananouchi
0
220
Laravelで学ぶ Webアプリケーションチューニング入門/web_application_tuning_101
hanhan1978
4
960
そのテスト、説明できますか?~LWテスト戦略FW~のご紹介
nakahara
0
210
Hatena Engineer Seminar #37「言語モデルの活用に関する研究」
slashnephy
0
530
act2-costs.pdf
sumedhbala
0
120
AIを活用したE2Eテスト実装効率化のあゆみ / ebisu-mobile-14-kotetu
kotetuco
0
170
【やさしく解説 設計編・中級 #4】ルールの寿命と、システムの年輪
panda728
PRO
2
150
気圧・高度・GPSを記録&可視化するアプリ「Koudo」を作った話
hjmkth
1
360
Apache Hive: Toward a Cloud Native Lakehouse
okumin
0
140
PHP Application における Kubernetes 内 gRPC 通信
ganchiku
0
500
Generative UI & AI-Assistants for Your Angular Solutions
manfredsteyer
PRO
1
190
PHP に部分適用が来るぞ!……ところで何それ?おいしいの? #phpcon / phpcon-2026
shogogg
0
270
Featured
See All Featured
Noah Learner - AI + Me: how we built a GSC Bulk Export data pipeline
techseoconnect
PRO
0
220
Mind Mapping
helmedeiros
PRO
1
290
AI Search: Implications for SEO and How to Move Forward - #ShenzhenSEOConference
aleyda
1
1.3k
A Guide to Academic Writing Using Generative AI - A Workshop
ks91
PRO
1
350
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
49
10k
Leading Effective Engineering Teams in the AI Era
addyosmani
9
2.2k
Large-scale JavaScript Application Architecture
addyosmani
515
110k
The Illustrated Guide to Node.js - THAT Conference 2024
reverentgeek
1
410
Rebuilding a faster, lazier Slack
samanthasiow
85
9.6k
Lessons Learnt from Crawling 1000+ Websites
charlesmeaden
PRO
1
1.4k
Mozcon NYC 2025: Stop Losing SEO Traffic
samtorres
1
390
Applied NLP in the Age of Generative AI
inesmontani
PRO
4
2.4k
Transcript
Kuiperbelt Asynchronous protocol proxy for prefork backend.
Who am I ? • twitter: @mackee_w • PAUSE ID:
MACOPY • github: github.com/mackee • Yokohama.pm Co-mainterner(?)
What’s kuiperbelt? • Asynchronous protocol =WebSocket • Other protocols(not implement):
• HTTP2 MQTT memd(!?) etc…
What’s kuiperbelt? • kuiperbelt is… • WebSocket to HTTP1.x converter
• proxy, authentication mechanism and connection pooling
Motivation • Prefork(or blocking/synchronous) server has a problem of about
using websocket protocol. • Problems: • C10k • AnyEvent(Perl)/Eventmachine(Ruby) -> RDB Transaction • shared connection -> sticky session(?)
Conventional solution • Switch to a language that support concurrent
• code to trash!!! oh!!!! • pray and close eyes • C10k???? my code is not graceful but working now.
OTOH, Realtime application age • Server-side push • realtime paging????
huh????? • Planner’s imagination is infinite.
kuiperbelt flow: connection
Kuiperbelt flow: connection client kuipetbelt backend
Kuiperbelt flow: connection client kuipetbelt backend GET /connect with Upgrade
Kuiperbelt flow: connection client kuipetbelt backend proxy to endpoint
Kuiperbelt flow: connection client kuipetbelt backend authentication proxy query string
and header
Kuiperbelt flow: connection client kuipetbelt backend response with session key
header
Kuiperbelt flow: connection client kuipetbelt backend register session key
Kuiperbelt flow: connection client kuipetbelt backend upgrade to websocket
Kuiperbelt flow: server-side push
Kuiperbelt flow: server-side push client kuipetbelt backend POST /send with
session key header
Kuiperbelt flow: server-side push client kuipetbelt backend search session by
key
Kuiperbelt flow: server-side push client kuipetbelt backend write body to
connection
other features • server-side closing with message • close callback
to backend by client- side normally closing • switch binary/text frame
clusters • kuiperbelt is support single host application only. •
But does not mean there is no way. • Kuiperbelt server host name in header of /connect callback. • If you want to connection mapping to some kuiperbelt host, store this hostname in datastore.
implementation plan • (really) cluster support • Redis Pub/Sub or
MQTT backbone • DHT and sticky session? • documentation (oh…
Please try it!!! github.com/mackee/kuiperbelt
Thank you!