Serverless Flask and a tangent about the origin of the Power Rangers

A presentation at CodeDaze Vol 2 in September 2018 in Buffalo, NY, USA by Shy Ruparel

Slide 1

Slide 1

Serverless Python And a tangent about the secret origins of the Power Rangers By Shy Ruparel

Slide 2

Slide 2

Shy Ruparel Developer Evangelist | Contentful @ShyRuparel He/Him

Slide 3

Slide 3

serverless vs Serverless

Slide 4

Slide 4

Serverless Architectures

Slide 5

Slide 5

Source: https://martinfowler.com/bliki/Serverless.html

Slide 6

Slide 6

Why Serverless?

Slide 7

Slide 7

Pay for What you Use

Slide 8

Slide 8

1 Request = 1 Server

Slide 9

Slide 9

SERVERLESS Going serverless allows you to create and run applications and services without having to worry about servers - at least not servers that you have to maintain. Zero Downtime Zero Maintenance Pay for what you use Infinite Scaling

Slide 10

Slide 10

Please don’t fire your ops team

Slide 11

Slide 11

Let’s look at the state of serverless python

Slide 12

Slide 12

Serverless Chalice Zappa

Slide 13

Slide 13

WSGI Microservice

Slide 14

Slide 14

WSGI Microservice Serverless Zappa Serverless AWS Chalice Zappa

Slide 15

Slide 15

Vendor Lock-in

Slide 16

Slide 16

Slide 17

Slide 17

Let’s make a Microsite

Slide 18

Slide 18

But first it’s time for a small tangent

Slide 19

Slide 19

19 The Origin of Power Rangers

Slide 20

Slide 20

Slide 21

Slide 21

KYŌRYŪ SENTAI ZYURANGER MIGHTY MORPHIN POWER RANGERS 1992-1993 1993-1996

Slide 22

Slide 22

Slide 23

Slide 23

Slide 24

Slide 24

Slide 25

Slide 25

Ok. So I built a dumb Website about this.

Slide 26

Slide 26

www.contentful.com HENSHIN.RUPAREL.CO

Slide 27

Slide 27

80 LINE FLASK APP + CONTENTFUL

Slide 28

Slide 28

www.contentful.com CONTENTFUL

Slide 29

Slide 29

Slide 30

Slide 30

Let’s make it serverless

Slide 31

Slide 31

Slide 32

Slide 32

AWS Lambda + API Gateway

Slide 33

Slide 33

Slide 34

Slide 34

Content Infrastructure Me Writing Content and hoping my friends will share my weird hobbies and help me with this site Browser API Gateway AWS Lambda Zappa Me Writing Code

Slide 35

Slide 35

SERVERLESS FRAMEWORK

Slide 36

Slide 36

SERVERLESS FRAMEWORK CONFIG

Slide 37

Slide 37

www.contentful.com BOTH DEPLOYMENT FRAMEWORKS HANDLE AWS LAMBDA AND API GATEWAY

Slide 38

Slide 38

38 Let’s talk Metrics

Slide 39

Slide 39

30 ms RENDER TIME

Slide 40

Slide 40

$0.000000002/ms COST ON LAMBDA

Slide 41

Slide 41

3,200,000 FREE FUNCTION CALLS ON LAMBDA

Slide 42

Slide 42

$3.50 PER MILLION CALLS ON API GATEWAY

Slide 43

Slide 43

Basically no time TO GET UP AND RUNNING

Slide 44

Slide 44

Shy Ruparel Developer Evangelist | Contentful @ShyRuparel He/Him Slides -> GitHub.com/shy/talks Background Images -> wocintechchat.com