$30 off During Our Annual Pro Sale. View Details »
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
LWPG: The Future Is Realtime
Search
miksago
October 20, 2011
Programming
4
1k
LWPG: The Future Is Realtime
A slightly more technical version of the The Future Is Realtime talk I've been doing recently.
miksago
October 20, 2011
Tweet
Share
More Decks by miksago
See All by miksago
Introducing Realtime - Node.js Dublin
miksago
3
380
KRTConf: WebSockets & Sub-Protocols
miksago
1
740
Reject.js: The Future is Realtime
miksago
3
560
Cognac.js - Testing on the Rocks
miksago
2
170
London Ajax: The Future Is Realtime
miksago
3
180
LDNJS 05 - Node
miksago
6
290
Other Decks in Programming
See All in Programming
Why Kotlin? 電子カルテを Kotlin で開発する理由 / Why Kotlin? at Henry
agatan
2
7k
Microservices rules: What good looks like
cer
PRO
0
1.2k
sbt 2
xuwei_k
0
270
大体よく分かるscala.collection.immutable.HashMap ~ Compressed Hash-Array Mapped Prefix-tree (CHAMP) ~
matsu_chara
1
220
非同期処理の迷宮を抜ける: 初学者がつまづく構造的な原因
pd1xx
1
700
チームをチームにするEM
hitode909
0
310
dnx で実行できるコマンド、作ってみました
tomohisa
0
150
俺流レスポンシブコーディング 2025
tak_dcxi
14
8.6k
React Native New Architecture 移行実践報告
taminif
1
150
これだけで丸わかり!LangChain v1.0 アップデートまとめ
os1ma
6
1.8k
Socio-Technical Evolution: Growing an Architecture and Its Organization for Fast Flow
cer
PRO
0
320
【CA.ai #3】Google ADKを活用したAI Agent開発と運用知見
harappa80
0
300
Featured
See All Featured
Navigating Team Friction
lara
191
16k
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
12
970
The Straight Up "How To Draw Better" Workshop
denniskardys
239
140k
Faster Mobile Websites
deanohume
310
31k
The Cost Of JavaScript in 2023
addyosmani
55
9.3k
Imperfection Machines: The Place of Print at Facebook
scottboms
269
13k
Bootstrapping a Software Product
garrettdimon
PRO
307
120k
A Tale of Four Properties
chriscoyier
162
23k
Producing Creativity
orderedlist
PRO
348
40k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
55
3.1k
Context Engineering - Making Every Token Count
addyosmani
9
500
How to Ace a Technical Interview
jacobian
280
24k
Transcript
Micheil Smith - @miksago The future is realtime
I work at Pusher BUILDING THE REALTIME WEB
• Part 1: Background & History • Part 2: Using
the Realtime Web
• Part 1: Background & History • Part 2: Using
the Realtime Web
• Part 1: Background & History • Overview of the
past • The Shift to Realtime • Realtime Web in Action
• Overview of the past • The Shift to Realtime
• Realtime Web in Action
• Early web • PHP / LAMP Stack • MVC
• Social Web Overview of the past
http://www.mikealrogers.com/posts/a-new- direction-for-web-applications-.html Overview of the past
• Overview of the past • The Shift to Realtime
• Realtime Web in Action
The Shift to Realtime • The web has become more
interactive • Users expect things to be “now” • And why should they have to wait?
• We researched page-load time • We used AJAX to
decrease wait-time on interactions • We then tried to simulate “realtime” with AJAX and related technologies The Shift to Realtime
The Simulations of Realtime • HTTP Polling • LiveConnect •
Forever iFrame • XHR Long-polling • XHR Streaming
A more complete history http://blog.pusher.com/2011/8/10/what- came-before-websockets
Going Properly Realtime • HTML5 Introduces many new API’s •
One of those is WebSockets
What are WebSockets? • Bi-directional socket connection between browser and
server • API is fairly low level • Low-latency/high-frequency messaging
The Uses of WebSockets • Progressively Realtime Applications • Entirely
Realtime Applications • Multiplayer HTML5 Gaming
• Overview of the past • The Shift to Realtime
• Realtime in Action
Progressively Realtime Apps CloudApp Tastebuds
Collaborative Editing Codr.cc Google Docs
Realtime Analytics Guag.es
Realtime HTML5 Gaming Rawkets Metris
There’s a lot more uses...
...and even more that we haven’t thought of yet.
• Part 1: Background & History • Part 2: Using
the Realtime Web
var socket = new WebSocket('ws://localhost:8080/') socket.onopen = function() { /*...*/
}; socket.onmessage = function(messageEvent) { /*...*/ }; socket.onclose = function(closeEvent) { /*...*/ }; socket.onerror = function() { /*...*/ }; socket.send('my data'); The WebSocket API
var socket = new WebSocket(url, protocol) var socket = new
WebSocket(url, [protocol1, protocol2]) socket.addEventListener('open', function() { /*...*/ }); socket.addEventListener('message', /*...*/ ); socket.addEventListener('close', /*...*/ ); socket.addEventListener('error', /*...*/ ); The WebSocket API (alt)
WebSocket Servers • worlize/WebSocket-node • miksago/node-websocket-server • oberstet/Autobahn (python) •
igrigorik/em-websocket (ruby) • Jetty/7.5.2 (java) • ostinelli/misultin (erlang)
Warning! There are currently multiple versions of WebSockets supported by
Browsers, not all of the previously listed Servers support all the versions.
Extra’s!
Portland, OR 7th & 8th November http://krtconf.com Keeping It Realtime
Conference
Questions?
Thanks for listening! @miksago on Twitter / Github / Geekli.st