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
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
VAN
April 19, 2012
Programming
1
180
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
最初からAWS CDKで技術検証してもいいんじゃない?
akihisaikeda
4
170
AWS×クラウドネイティブソフトウェア設計 / AWS x Cloud-Native Software Design
nrslib
16
3.4k
Takumiから考えるSecurity_Maturity_Model.pdf
gessy0129
1
160
Windows on Ryzen and I
seosoft
0
360
AI時代のシステム設計:ドメインモデルで変更しやすさを守る設計戦略
masuda220
PRO
6
1.1k
PHPで TLSのプロトコルを実装してみる
higaki_program
0
420
Symfony + NelmioApiDocBundle を使った スキーマ駆動開発 / Schema Driven Development with NelmioApiDocBundle
okashoi
0
210
KagglerがMixSeekを触ってみた
morim
0
170
Goの型安全性で実現する複数プロダクトの権限管理
ishikawa_pro
2
1.2k
ポーリング処理廃止によるイベント駆動アーキテクチャへの移行
seitarof
3
1.3k
Ruby and LLM Ecosystem 2nd
koic
1
1.3k
Codex の「自走力」を高める
yorifuji
0
1.3k
Featured
See All Featured
Intergalactic Javascript Robots from Outer Space
tanoku
273
27k
Principles of Awesome APIs and How to Build Them.
keavy
128
17k
It's Worth the Effort
3n
188
29k
Making Projects Easy
brettharned
120
6.6k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
31
10k
Designing for Timeless Needs
cassininazir
0
170
Organizational Design Perspectives: An Ontology of Organizational Design Elements
kimpetersen
PRO
1
650
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
38
2.8k
Rails Girls Zürich Keynote
gr2m
96
14k
Paper Plane (Part 1)
katiecoart
PRO
0
5.8k
Leading Effective Engineering Teams in the AI Era
addyosmani
9
1.8k
<Decoding/> the Language of Devs - We Love SEO 2024
nikkihalliwell
1
160
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コーチによる デモを御覧下さい