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.js on Windows - jscamp.asia 2012
Search
Tomasz Janczuk
November 30, 2012
Technology
3
210
Node.js on Windows - jscamp.asia 2012
Tomasz Janczuk
November 30, 2012
Tweet
Share
Other Decks in Technology
See All in Technology
AI JIMY - 登壇(インストール編)
hanacchi
0
150
ハードウェアを動かすTypeScriptの世界
9wick
3
1.2k
大規模言語モデル (LLM)における低精度数値表現
pfn
PRO
3
780
CockroachDB はどのくらい「しぶとい」のか? / How tough is CockroachDB?
kota2and3kan
13
4.9k
「知的単純作業」を自動化する、地に足の着いた大規模言語モデル (LLM) の活用
nrryuya
8
8.1k
OPENLOGI Company Profile
hr01
0
45k
YJIT Makes Rails 1.7x faster / RubyKaigi 2024
k0kubun
0
110
社内での継続的な機械学習勉強会の開催のコツ
yudai00
2
380
RailsConf 2024 Keynote "Startups on Rails in 2024"
irinanazarova
0
730
cgroup v2 で何が変わったのか / TechFeed Experts Night #28
tenforward
2
150
Databricksの生成AI戦略
taka_aki
1
350
OPENLOGI Company Profile for engineer
hr01
1
2.1k
Featured
See All Featured
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
123
39k
The Straight Up "How To Draw Better" Workshop
denniskardys
228
130k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
23
1.7k
Docker and Python
trallard
35
2.7k
A Philosophy of Restraint
colly
197
16k
Unsuck your backbone
ammeep
664
57k
Thoughts on Productivity
jonyablonski
60
3.9k
Become a Pro
speakerdeck
PRO
13
4.6k
VelocityConf: Rendering Performance Case Studies
addyosmani
321
23k
RailsConf 2023
tenderlove
9
580
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
0
110
It's Worth the Effort
3n
180
27k
Transcript
Node.js on Windows. Undisclosured. Tomasz Janczuk Engineer,
Microso< @tjanczuk, github.com/tjanczuk, tomasz.janczuk.org jscamp.asia 2012
EvoluGon of node.js on Windows
Divine Comedy meets WebSockets
w3wp.exe node.exe node.exe Two ways to run
on Windows node.exe iisnode TCP libuv HTTP applicaGon TCP HTTP.SYS IIS iisnode named pipes libuv HTTP applicaGon
Windows Azure
Ways to run in Windows Azure Virtual Machine
Linux or Windows Hosted Service Managed applica;on with VM access on Windows Web Site Managed HTTP applica;on with Git, GitHub, FTP and TFS deployment Mobile Service Backend for Windows 8, Windows Phone or iPhone applica;on
Ways to run in Windows Azure Virtual Machine
Hosted Service Web Site Mobile Service node.exe iisnode
You don’t need Windows to run on Windows Azure
Web Site iisnode npm install azure
node.js + express on iisnode 320 machines 8
data centers 2 billion requests/day peak 45k requests/second peak kernel mode output caching Web Site iisnode
w3wp.exe node.exe node.exe Two ways to run
on Windows node.exe iisnode TCP libuv HTTP applicaGon TCP HTTP.SYS IIS iisnode named pipes libuv HTTP applicaGon
w3wp.exe node.exe node.exe Two Three ways to
run on Windows node.exe iisnode TCP libuv HTTP applicaGon TCP HTTP.SYS IIS iisnode named pipes libuv HTTP applicaGon node.exe TCP HTTP.SYS libuv applicaGon hIp.sys hZps://github.com/tjanczuk/hZpsys
Performance and output caching hZps://github.com/tjanczuk/hZpsys hZp://tomasz.janczuk.org/2012/08/the-‐hZpsys-‐stack-‐for-‐nodejs-‐apps-‐on.html
12461 17364 159902 0 40000 80000 120000 160000 node.js hZp.sys hZp.sys + output caching requests/second Throughput, 1 node.exe process
Output caching var hZp = require('hZpsys').hZp(); hZp.createServer(funcGon
(req, res) { res.writeHead(200); res.cacheDura;on = 60; // cache for 60s res.end(’Hello, world!'); }).listen(8080); hZps://github.com/tjanczuk/hZpsys
Port sharing var hZp = require('hZpsys').hZp(); hZp.createServer(funcGon
(req, res) { res.writeHead(200); res.end(’Second app!'); }).listen(‘hIp://*:80/second’); var hZp = require('hZpsys').hZp(); hZp.createServer(funcGon (req, res) { res.writeHead(200); res.end(’First app!'); }).listen(‘hIp://*:80/first’); hZps://github.com/tjanczuk/hZpsys
When a node app becomes a zombie while(true);
Tripwire to the rescue require('tripwire’).resetTripwire(2000);
while(true); // excep;on a[er 2000ms hZps://github.com/tjanczuk/tripwire
Tripwire to the rescue process.on('uncaughtExcepGon', funcGon (e) {
console.error(’Event loop was blocked!’); process.exit(1); }); require('tripwire’).resetTripwire(2000); while(true); // excep;on a[er 2000ms hZps://github.com/tjanczuk/tripwire
Open sourced and undisclosured npm install azure-‐cli hZps://windowsazure.com
github.com/tjanczuk github.com/windowsazure @tjanczuk `