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
Node Boot Camp [under construction]
Search
VAN
April 19, 2012
Programming
1
170
Node Boot Camp [under construction]
PGCafe Nite @Mitaka 2012/4/17 (わけあって修正中。特に最後のページ)
VAN
April 19, 2012
Tweet
Share
Other Decks in Programming
See All in Programming
あまり知られていない MCP 仕様たち / MCP specifications that aren’t widely known
ktr_0731
0
220
React は次の10年を生き残れるか:3つのトレンドから考える
oukayuka
41
16k
AIのメモリー
watany
12
1.2k
中級グラフィックス入門~効率的なメッシュレット描画~
projectasura
4
2.4k
Vibe coding コードレビュー
kinopeee
0
400
はじめてのWeb API体験 ー 飲食店検索アプリを作ろうー
akinko_0915
0
180
Claude Code で Astro blog を Pages から Workers へ移行してみた
codehex
0
170
DMMを支える決済基盤の技術的負債にどう立ち向かうか / Addressing Technical Debt in Payment Infrastructure
yoshiyoshifujii
5
750
DynamoDBは怖くない!〜テーブル設計の勘所とテスト戦略〜
hyamazaki
0
180
Scale out your Claude Code ~自社専用Agentで10xする開発プロセス~
yukukotani
2
610
No Install CMS戦略 〜 5年先を見据えたフロントエンド開発を考える / no_install_cms
rdlabo
0
430
Advanced Micro Frontends: Multi Version/ Framework Scenarios
manfredsteyer
PRO
0
150
Featured
See All Featured
Imperfection Machines: The Place of Print at Facebook
scottboms
267
13k
Building Applications with DynamoDB
mza
95
6.5k
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
161
15k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
10
1k
Music & Morning Musume
bryan
46
6.7k
The Straight Up "How To Draw Better" Workshop
denniskardys
235
140k
How GitHub (no longer) Works
holman
314
140k
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
283
13k
Large-scale JavaScript Application Architecture
addyosmani
512
110k
Fantastic passwords and where to find them - at NoRuKo
philnash
51
3.4k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
44
2.4k
Adopting Sorbet at Scale
ufuk
77
9.5k
Transcript
VAN & Jack 12/04/19 1 Node Boot Camp!
ίʔν 12/04/19 Footer Text 2
͜ΕΛಡΊʂ • http://speakerdeck.com/u/badatmath/p/nodejs 12/04/19 Footer Text 3 以上。
ಛ • Single thread • Non-blocking I/O • JavaScript •
V8 12/04/19 Footer Text 4 以上。
ಛ܇ϝχϡʔ • なんでNodeなの? • どんなものなの? • どうやって使うの? 12/04/19 Footer Text
5
എܠ • クライントのスペック向上 • コンテンツのリッチ化 • 情報のリアルタイム化 12/04/19 Footer Text
6
ϦΞϧλΠϜWEB • じわじわと普及 o Google Docs o Twitter o Facebook
12/04/19 Footer Text 7 定量的なデータ
ϦΞϧλΠϜWEB • サーバからデータを送りたい!(PUSH) • ポーリングは非効率だなあ • 常時接続しちゃえ 12/04/19 Footer Text
8
The C10k Problem 12/04/19 Footer Text 9 e.g. Apache
HTTP HTML
The C10k Problem 12/04/19 Footer Text 10 e.g. Apache
Poling Ajax
The C10k Problem 12/04/19 Footer Text 11 Server Thread
Thread Thread e.g. Apache WebSocket SmartPhone
The C10k Problem 12/04/19 Footer Text 12 Server Thread
Thread Thread e.g. Apache WebSocket SmartPhone
The C10k Problem 12/04/19 Footer Text 13 Node.js WebSocket
SmartPhone Server Thread
γϯάϧεϨουͷฐ • 処理待ちが発生 • 複数コア使えない 12/04/19 Footer Text 14
I/Oって遅い CPU コア NW Storage HDD L2キャッシュ Memory L1キャッシュ 3
14 250 41,000,000 240,000,000 = 約地球一周 = 約地球六周 1CPUサイクルを1mとすると
ಛ • Single thread • Non-blocking I/O • JavaScript •
V8 12/04/19 Footer Text 16
JavaScript • 元々非同期処理 • クライアントサイドのリッチ化で流行 • みんな書ける(よね?) 12/04/19 Footer Text
17
γϯάϧϖʔδ ΣϒσβΠϯ 12/04/19 Footer Text 18 HTMLの表示 ビジネスロジック HTMLの構成
HTMLの構成 ビジネスロジック クライアント WEBサーバ Request HTML APIサーバ Request JSON
ߏ 12/04/19 Footer Text 19 Windows にて非同期対応するためにv0.6か ら導入された抽象化レイヤ I/O完了時にコールバック
I/Oのキューを受け付ける 大津さん、 パクリました
ಛ • Single thread • Non-blocking I/O • JavaScript •
V8 12/04/19 Footer Text 20 おさらい
12/04/19 Footer Text 21 それでは Jackコーチによる デモを御覧下さい