building beyond billions

16
Building Beyond Billions High Throughput Systems w/ Node.js

Upload: optic

Post on 06-Jan-2017

268 views

Category:

Technology


0 download

TRANSCRIPT

Building Beyond BillionsHigh Throughput Systems w/ Node.js

Overview

Where should we spend time?

10 principles of high throughput systems

Stress testing

An inside look into our system

Node.js pros and cons

104,000 reqs / sec

Augur 4,000 reqs / sec

Building Beyond Billions

almost … there...

# of consumer devices

2016

5 B

50 Billion

20202017 2018 2019

Web tracking, via API

Dieter RamsNawar Alsafar

Ten Principles of Good Design Software Architecture

Ten principles of good software architecture 1) Good architecture is embarrassingly parallel

2) Good architecture has known bounds

3) Good architecture has wire time bottleneck

4) Good architecture reduces cost

5) Good architecture uses application logic that is understandable and elementary in style

1) Good architecture self-heals

2) Good architecture is rapidly updated

3) Good architecture consistently performs

4) Good architecture is always communicating

5) Good architecture uses less memory

Ten principles of good software architecture Good architecture is embarrassingly parallel

Good architecture self-heals

Ten principles of good software architectureGood architecture has wiretime bottleneck

Good architecture consistently performs

Ten principles of good software architectureGood architecture has known bounds Good architecture is rapidly updated

Ten principles of good software architectureGood architecture reduces cost Good architecture is always

communicating

Ten principles of good software architectureGood architecture uses application logic that is understandable and elementary in style

Good architecture uses less memory

AugurArchitectural Digest

DNS

Pub / Sub

Web

iOS

Android

ClientsGloba

l LB

U.S.

API server

U.S.

E.U.

C.H.

Recon workers

Events

server

Analytics worker

ETL

Front-end

server

Site / web app

Firewall

C.H.E.U.

Aerospike clusters U.S.

Firewall

Google NoSQL

Firewall

Google Fiber requestNormal net

request

Concurrency model

Stack: context

Heap: mem. alloc.

Queue: things to do

Special properties

Run-to-completion

Non-blocking execution

JIT compiler

Full compiler

Optimized compiler

Node.js - under the hood

Node.js - pros / cons

ProsBiggest ecosystem

Fast, thanks to v8, crankshaft, turbofan

Getting faster every week

One language can be used for all web dev

ConsNo central memory share is available

GC could be better

Special knowledge needed to max perf