SlideShare a Scribd company logo
Firehose
Building a real-time data stream with NodeJS

             Luca Grulla@Forward
               London, 2/8/2011
Introduction

Or what we wanted to build
We like to have a (near) real-time view
          of the data stream
Resilient
Scalable
Accurate
(but not necessarily precise)
Firehose
Verse and Chorus

  Or how we built it
Stack
• NodeJS (0.4.9)
• CoffeeScript
• ZeroMQ
Architecture
Interlude

Or joys and pitfalls 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 implementations 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
Questions ?
References
• npm install tail
• https://github.com/forward/node-tail

More Related Content

PDF
Re-Think of Virtualization and Containerization
PPTX
Let's build a PaaS platform, how hard could it be?
PPTX
Introduction to NodeJS
PDF
PDF
Developing Serverless Microservice in Rust
PPTX
Realtime web2012
PPTX
Domain's Robot Army
Re-Think of Virtualization and Containerization
Let's build a PaaS platform, how hard could it be?
Introduction to NodeJS
Developing Serverless Microservice in Rust
Realtime web2012
Domain's Robot Army

What's hot (19)

KEY
MongoDB on CloudFoundry
ODP
Beyond Xen: A look into the Xen Cloud Platform
PPT
Ruby eventmachine pres at rubybdx
PPTX
Hang fire
PDF
Cassandra Development Nirvana
PDF
Writing your own browser reload functionality
PDF
BBC's GraphDB (formerly Owlim) AWS Cloud Migration
PPT
Docker Practical Use Cases
PDF
MPI, Erlang and the web
PPTX
Designing a Docker Stack for Symfony apps: lessons learned
PDF
Build App with Nodejs - YWC Workshop
PPTX
Boulder JS meet up presentation for April 16
PPTX
Anton Cherednikov "Modules and Artifacts in NPM"
PPT
OpenNebula Administrator View
PPTX
MobX intro
PDF
Travel with your mock server
ODP
Openvz booth
PDF
OpenShift on IBM Cloud BMS
PDF
How to make your ruby code faster with multithreading
MongoDB on CloudFoundry
Beyond Xen: A look into the Xen Cloud Platform
Ruby eventmachine pres at rubybdx
Hang fire
Cassandra Development Nirvana
Writing your own browser reload functionality
BBC's GraphDB (formerly Owlim) AWS Cloud Migration
Docker Practical Use Cases
MPI, Erlang and the web
Designing a Docker Stack for Symfony apps: lessons learned
Build App with Nodejs - YWC Workshop
Boulder JS meet up presentation for April 16
Anton Cherednikov "Modules and Artifacts in NPM"
OpenNebula Administrator View
MobX intro
Travel with your mock server
Openvz booth
OpenShift on IBM Cloud BMS
How to make your ruby code faster with multithreading
Ad

Viewers also liked (7)

PPT
Hose reel in fire fighting system
PPT
Hose reel systems
PDF
Il grande bluff delle stime
PDF
Build your own trello witihin 100 LOC (with Meteor)
PDF
Embracing Clojure: a journey into Clojure adoption
PPT
Fire alarm system (sistem penggera kebakaran)
PPT
Sistem pencegah kebakaran
Hose reel in fire fighting system
Hose reel systems
Il grande bluff delle stime
Build your own trello witihin 100 LOC (with Meteor)
Embracing Clojure: a journey into Clojure adoption
Fire alarm system (sistem penggera kebakaran)
Sistem pencegah kebakaran
Ad

Similar to Firehose (20)

PPTX
introduction to node.js
PDF
Nodejs a-practical-introduction-oredev
PDF
Nodejs - A quick tour (v6)
PDF
Matthew Eernisse, NodeJs, .toster {webdev}
PPT
Node js beginner
PDF
NodeJS for Beginner
KEY
Node.js - A practical introduction (v2)
KEY
Playing With Fire - An Introduction to Node.js
PDF
Node.js introduction
PDF
Node.js - async for the rest of us.
PDF
Nodejs - Should Ruby Developers Care?
PDF
Frontend Track NodeJS
PDF
Nodejs - A quick tour (v5)
KEY
NodeJS
PDF
Introduction to Node.js
PPTX
Introduction to node.js GDD
PPTX
Building and Scaling Node.js Applications
PDF
Node.js - A Quick Tour
PPTX
Introduction to Node (15th May 2017)
PDF
Node in Real Time - The Beginning
introduction to node.js
Nodejs a-practical-introduction-oredev
Nodejs - A quick tour (v6)
Matthew Eernisse, NodeJs, .toster {webdev}
Node js beginner
NodeJS for Beginner
Node.js - A practical introduction (v2)
Playing With Fire - An Introduction to Node.js
Node.js introduction
Node.js - async for the rest of us.
Nodejs - Should Ruby Developers Care?
Frontend Track NodeJS
Nodejs - A quick tour (v5)
NodeJS
Introduction to Node.js
Introduction to node.js GDD
Building and Scaling Node.js Applications
Node.js - A Quick Tour
Introduction to Node (15th May 2017)
Node in Real Time - The Beginning

More from Luca Grulla (8)

PDF
Change a gear up with Evolutionary Architecture
PPTX
Impact! Drive innovation from the front seat
PDF
Clojure's killer design decisions
PPTX
Transmitting Signal with Clojure
PDF
Innovation at speed
PPTX
Javascript testing IAD2010
PPT
Agile Estimating And Planning
PPT
Retrospectives Techniques
Change a gear up with Evolutionary Architecture
Impact! Drive innovation from the front seat
Clojure's killer design decisions
Transmitting Signal with Clojure
Innovation at speed
Javascript testing IAD2010
Agile Estimating And Planning
Retrospectives Techniques

Recently uploaded (20)

PDF
CIFDAQ's Market Insight: SEC Turns Pro Crypto
PDF
Dropbox Q2 2025 Financial Results & Investor Presentation
PDF
Empathic Computing: Creating Shared Understanding
PDF
Mobile App Security Testing_ A Comprehensive Guide.pdf
PDF
cuic standard and advanced reporting.pdf
PDF
NewMind AI Weekly Chronicles - August'25 Week I
PDF
Chapter 3 Spatial Domain Image Processing.pdf
PDF
Network Security Unit 5.pdf for BCA BBA.
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PDF
Modernizing your data center with Dell and AMD
PDF
KodekX | Application Modernization Development
PDF
Approach and Philosophy of On baking technology
PDF
Encapsulation theory and applications.pdf
PDF
NewMind AI Monthly Chronicles - July 2025
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PPTX
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
PDF
Shreyas Phanse Resume: Experienced Backend Engineer | Java • Spring Boot • Ka...
CIFDAQ's Market Insight: SEC Turns Pro Crypto
Dropbox Q2 2025 Financial Results & Investor Presentation
Empathic Computing: Creating Shared Understanding
Mobile App Security Testing_ A Comprehensive Guide.pdf
cuic standard and advanced reporting.pdf
NewMind AI Weekly Chronicles - August'25 Week I
Chapter 3 Spatial Domain Image Processing.pdf
Network Security Unit 5.pdf for BCA BBA.
The Rise and Fall of 3GPP – Time for a Sabbatical?
Modernizing your data center with Dell and AMD
KodekX | Application Modernization Development
Approach and Philosophy of On baking technology
Encapsulation theory and applications.pdf
NewMind AI Monthly Chronicles - July 2025
Reach Out and Touch Someone: Haptics and Empathic Computing
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
Advanced methodologies resolving dimensionality complications for autism neur...
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
Shreyas Phanse Resume: Experienced Backend Engineer | Java • Spring Boot • Ka...

Firehose

Editor's Notes

  • #4: Because you can do cool stuff with this !!Previous implementation was with Flume+zeroMQ..flume was unraliable