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
Building a Firehose with NodeJS
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Luca Grulla
April 23, 2012
Technology
140
1
Share
Building a Firehose with NodeJS
August 2011 Forward First Tuesday - building a firehose in nodeJS
Luca Grulla
April 23, 2012
More Decks by Luca Grulla
See All by Luca Grulla
JavaScriptTesting
lucagrulla
1
1.2k
Il grande bluff delle stime
lucagrulla
0
350
Other Decks in Technology
See All in Technology
Rapid Start: Faster Internet Connections, with Ruby's Help
kazuho
2
740
AWS Transform CustomでIaCコードを自由自在に変換しよう
duelist2020jp
0
110
ぼくがかんがえたさいきょうのあうとぷっと
yama3133
0
200
LLM時代の検索アーキテクチャと技術的意思決定
shibuiwilliam
3
1.4k
扱える不確実性を増やしていく - スタートアップEMが考える「任せ方」
kadoppe
0
320
AgentCore Managed Harness を使ってみよう
yakumo
2
170
AI: Making Admin and Users, Lives Better
kbmsg
0
110
[OAWTT26][THR1028] Oracle AI Database 26ai へのアップグレード:ベストプラクティスと最新情報
oracle4engineer
PRO
1
110
Do Vibe Coding ao LLM em Produção para Busca Agêntica - TDC 2026 - Summit IA - São Paulo
jpbonson
3
150
Expiration of Secure Boot Certificates for vSphere Virtual Machines
mirie_sd
0
110
AI時代における技術的負債への取り組み
codenote
1
1.7k
Shipping AI Agents — Lessons from Production
vvatanabe
0
280
Featured
See All Featured
Rebuilding a faster, lazier Slack
samanthasiow
85
9.5k
Stewardship and Sustainability of Urban and Community Forests
pwiseman
0
180
HU Berlin: Industrial-Strength Natural Language Processing with spaCy and Prodigy
inesmontani
PRO
0
320
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
38
2.8k
A designer walks into a library…
pauljervisheath
211
24k
Money Talks: Using Revenue to Get Sh*t Done
nikkihalliwell
0
210
Primal Persuasion: How to Engage the Brain for Learning That Lasts
tmiket
0
320
Building Applications with DynamoDB
mza
96
7k
Principles of Awesome APIs and How to Build Them.
keavy
128
17k
Kristin Tynski - Automating Marketing Tasks With AI
techseoconnect
PRO
0
230
Git: the NoSQL Database
bkeepers
PRO
432
67k
Jamie Indigo - Trashchat’s Guide to Black Boxes: Technical SEO Tactics for LLMs
techseoconnect
PRO
0
110
Transcript
Firehose Building a real-‐1me data stream with NodeJS
Luca Grulla@Forward London, 2/8/2011
Introduc1on Or what we wanted to build
We like to have a (near) real-‐1me view of
the data stream
Resilient
Scalable
Accurate (but not necessarily precise)
None
Verse and Chorus Or how we built it
Stack • NodeJS (0.4.9) • CoffeeScript •
ZeroMQ
Architecture
Interlude Or joys and pi4alls of building a tail
library for node
Living the asynchronous dream
Living the asynchronous dream • Error manifests itself
only at high throughput (7MB/secs) • The few implementa1ons you can find around are wrong (including Log.io – we are planning to contribute back)
Breathing in an asynchronous way
Learnings • You need to think asynchronous to write
asynchronous code • Dispatch internal events if you need to keep control of the flow • “Internal queues” to scale(up to a certain limit)
Performance • Beyond 5MB we start to fill the
internal queue • We are limited by IO, not from CPU/memory • Consistent throughput
Solo Or a short rant on declara<ve vs
impera<ve style
Event-‐driven approach • Event-‐driven is implicitly declara1ve – You
tell to the world that something just happened and do not care of what next • Fire events instead of passing around states – It’s cleaner – It’s simpler to maintain – It’s idioma1c
None
Ques1ons ?
References • npm install tail • hhps://github.com/forward/node-‐tail