70
BUILDING HIGH SCALE SYSTEM USING SERVERLESS ARCHITECTURE FOR A BURNING MAN EVENT Jonathann Zenou DevOps Days Tel Aviv 2017

Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

Embed Size (px)

Citation preview

Page 1: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

BUILDING HIGH SCALE SYSTEM USING SERVERLESS ARCHITECTURE

FOR A BURNING MAN EVENTJonathann Zenou

DevOps Days Tel Aviv 2017

Page 2: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

DISCLAIMER

• This is not a serverless introduction

• This is about replacing

• This is a not a complicated solution

Page 3: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

HELLO WORLD

• Jonathann Zenou

• Tel Aviv

• DevOps Engineer @ Oracle

Page 4: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 5: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 6: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 7: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 8: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 9: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 10: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 11: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 12: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

MIDBURN.ORG

Page 13: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

NUMBERS• Since 2014

• 3rd biggest

• 11000 participants

• 2500 volunteers

• 30 departments

Page 14: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

MIDBURN TECH

• 50 yearly volunteers

• Perks of being a Non-Profit organisation

• Open source

• Crucial

Page 15: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

TECHNOLOGY

• Production and Rnd in AWS

• SCM in Github (Open source !)

• Ruby, NodeJS and Java

Page 16: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

SYSTEMS• volunteers system

• profile system

• gate system

• …

• ticket selling queue system

Page 17: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

PROBLEMATIC

Page 18: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

TICKETS SELLING SYSTEM• Sold out

• Very high demand in very short time

• Lottery ?

• 2 flash events

• FIFS

Page 19: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

1ST ITERATION

• 2014

• Drupal + php + MySQL

• Management of the whole tickets process from Drupal

Page 20: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

BUT

Page 21: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 22: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

1 ST OUTAGE

• ~5000 concurrent users

• ~20 sessions by user

Page 23: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 24: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

REMODELLING

Page 25: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 26: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 27: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

REMODELLING

• One queuing system

• One selling system

Page 28: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

2ND ITERATION

• 2015

• Backend : Heroku + Reddis + Ruby

• Frontend : Javascript + S3

Page 29: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

Frontend

CSV

Page 30: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 31: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 32: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 33: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

2015

Page 34: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 35: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

2016

Page 36: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 37: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 38: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

2ND OUTAGE

Page 39: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 40: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 41: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 42: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 43: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 44: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

• a lot of users enter the system

• Backend is swamped

• Users hit “refresh”

• Backend is even more swamped

Page 45: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

WHAT WE UNDERSTOOD ?

Page 46: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 47: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 48: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

REMODELLING

Page 49: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

3RD ITERATION

• 2017

• Frontend : still Javascript + S3

• Backend : …

Page 50: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 51: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

CREATE AN API GATEWAY API AS AN AMAZON KINESIS

PROXYhttp://docs.aws.amazon.com/apigateway/latest/developerguide/

integrating-api-with-aws-services-kinesis.html

Page 52: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 53: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

Amazon API Getaway

Page 54: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

Amazon Kinesis Firehose

Page 55: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 56: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 57: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

S3 STATIC SITE LOGIC

is the opened queue page up

?

No

wait 5 seconds and retry

Page 58: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 59: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 60: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

TESTING

Page 61: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

CROSSING FINGERS2nd sale of the year

Page 62: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 63: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 64: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 65: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

NUMBERS• 15 minutes

• 3315 users

• 300 lucky users

• 4 seconds

• 3 000 000 requests

• 0 errors

Page 66: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

–Itamar Cohen, Midburn's COO

The Midburn community is composed of thousands of people.Not everyone can get a ticket and people can

get angry and frustrated from it . With this new system we ensure that at least if someone does not

get a ticket it’s not because of a technical issue .

Page 67: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 68: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017
Page 70: Building High Scale Systems Using Serverless Architecture for a Burning Man Event - Jonathan Zenou - DevOpsDays Tel Aviv 2017

QUESTIONS ?