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
IO Insights
Search
Guillermo Rauch
October 23, 2012
Programming
3
750
IO Insights
Guillermo Rauch
October 23, 2012
Tweet
Share
More Decks by Guillermo Rauch
See All by Guillermo Rauch
The realtime web: HTTP/1.1 to WebSocket, SPDY & beyond
rauchg
6
1.6k
Socket.IO 1.0
rauchg
9
2.3k
The rise of server-side JavaScript
rauchg
4
280
Other Decks in Programming
See All in Programming
What you can do with Ruby on WebAssembly
kateinoigakukun
0
170
Jakarta EE meets AI
ivargrimstad
1
540
Rubyとクリエイティブコーディングの輪の広がり / The Growing Circle of Ruby and Creative Coding
chobishiba
1
270
Modern Angular with the NGRX Signal Store New Rules for Your Architecture @BASTA! 2024 in Mainz
manfredsteyer
PRO
0
160
Ruby Parser progress report 2024
yui_knk
2
230
Hermes: Better Performance with Bytecode Translation (React Universe 2024)
tmikov2023
0
100
Desafios e Lições Aprendidas na Migração de Monólitos para Microsserviços em Java
jessilyneh
2
150
Rubyのobject_id
qnighy
6
1.3k
Composing an API the *right* way (Droidcon New York 2024)
zsmb
2
140
Some more adventure of Happy Eyeballs
coe401_
2
190
あなたのアプリ、ログはでてますか?あるいはログをだしてますか? (Funabashi.dev用 軽量版)
uzulla
2
120
Lessons by WebAssembly app in production on CDN Edge Computing Service
tetsuharuohzeki
0
210
Featured
See All Featured
Design by the Numbers
sachag
277
19k
The Brand Is Dead. Long Live the Brand.
mthomps
53
38k
Optimising Largest Contentful Paint
csswizardry
31
2.8k
The Invisible Side of Design
smashingmag
296
50k
Being A Developer After 40
akosma
84
590k
YesSQL, Process and Tooling at Scale
rocio
167
14k
The Mythical Team-Month
searls
218
43k
Gamification - CAS2011
davidbonilla
79
5k
The Straight Up "How To Draw Better" Workshop
denniskardys
230
130k
Building Adaptive Systems
keathley
36
2.1k
Learning to Love Humans: Emotional Interface Design
aarron
270
40k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
123
18k
Transcript
IO Insights engine.io and socket.io analytics
About
Guillermo Rauch
@rauchg
devthought.com
learnboost.com
require(‘engine.io’)
var engine = require(‘engine.io’)(server); engine.on(‘connection’, function(socket){ socket.write(‘hello’); socket.on(‘data’, function(){}); });
require(‘socket.io’)
var io = require(‘socket.io’)(server); io.on(‘connection’, function(socket){ socket.emit(‘my’, { event: ‘data’
}); socket.on(‘random’, function(){}); }); io.of(‘/namespace’).on();
Data packets and events are the new currency
But all the tooling is oriented around REST
None
Server insight
1st strategy
Built-in instrumentation
require(‘debug’)(‘wat’)
None
2nd strategy
Meta events
socket.on(‘packet’, function(){}); socket.on(‘packetCreate’, function(){});
3rd strategy
Visualization!
require(‘engine.io-monitor’);
Captures and displays engine.io traffic
Like redis MONITOR
Realtime insight into transport usage
12% 13% 34% 41% polling-xhr polling-jsonp websocket flashsocket
Realtime insight into browser / device usage
Realtime insight into latency
None
Client insight
1st strategy
localStorage.debug
None
Looks awful
2nd strategy
Chrome extension
None
None
How?
None
What’s next?
More visualizations
Protocol analysis eg: display socket.io events differently
Custom protocols
Analyze and document performance implications
Thanks!