Growing from 0 to 100 million users

36
Growing from 0 to 100 million users Andres Silva

Transcript of Growing from 0 to 100 million users

Page 1: Growing from 0 to 100 million users

Growing from 0 to 100 million

usersAndres Silva

Page 2: Growing from 0 to 100 million users

Monolithic architecture

Page 3: Growing from 0 to 100 million users

Decide which language is best for you!

Not all languages work the same way, and perhaps each approach specializes in certain aspects.

Prototype.Speed.Mathematical Processes.Access to database.Processing of queues.Synchronous.Asynchronous.RAM or CPU

Page 4: Growing from 0 to 100 million users
Page 5: Growing from 0 to 100 million users
Page 6: Growing from 0 to 100 million users

Our first million users

Page 7: Growing from 0 to 100 million users

Bottleneck

Page 8: Growing from 0 to 100 million users

Microservices

Page 9: Growing from 0 to 100 million users

Uber

“Postgres worked well for us at the beginning, but we ran into significant trouble scaling Postgres with our growth. Nowadays, we still keep Postgres at some instances, but the chunk of our databases are built on MySQL (typically using our Schemaless layer) or, in some specific cases, NoSQL databases like Cassandra. Overall, we are pretty happy with MySQL.”

Page 10: Growing from 0 to 100 million users

Postgres

Page 11: Growing from 0 to 100 million users

MySQL

Page 12: Growing from 0 to 100 million users

Databases

Page 13: Growing from 0 to 100 million users

Our case

36,000 Transactions per minute

52,000,000 Transactions per day

Microservice in Node js, with MYSQL

Page 14: Growing from 0 to 100 million users

Our solution

Auto Scaling

Microservices

RDS

Http to Web Sockets

Page 15: Growing from 0 to 100 million users

RDS

“ With Amazon Relational Database Service (Amazon RDS), it’s simple to configure, use

and scale a relational database in the cloud. It provides profitable capabilities of

customizable sizes and, at the same time, it manages the database’s tedious

administrative tasks, which allows for the focus to be placed on the app and the business.”

Page 16: Growing from 0 to 100 million users

RDS

Page 17: Growing from 0 to 100 million users

Protocols

Page 18: Growing from 0 to 100 million users

Auto Scaling

“ Auto Scaling allows you to keep your app’s availability and automatically increase or reduce Amazon’s EC2 capacity, based on the defined conditions. You can use Auto Scaling to make sure that you are executing the desired amount of Amazon EC2 instances. Auto Scaling can also automatically increase the number of Amazon EC2 instances during demand peaks, in order to maintain the performance and reduce capacity during slower periods to minimize costs. ”

Page 19: Growing from 0 to 100 million users

Auto Scaling

Page 20: Growing from 0 to 100 million users

Our 10 million users

Page 21: Growing from 0 to 100 million users

Costs

Page 22: Growing from 0 to 100 million users

Lambda

AWS Lambda allows you to run code without supplying or managing servers. You will only pay for the computing time you use- there is no charge when the code is not running. With Lambda, you can run code for almost any type of application or back-end service, without having to manage a single thing. You only have to load the code. Lambda will take care of everything you need to run and scale the code with high availability. You can configure the code to activate automatically from other AWS services or do it directly from any web or mobile application.

Page 23: Growing from 0 to 100 million users

Major Prosecutions

Page 24: Growing from 0 to 100 million users

Major Prosecutions

Page 25: Growing from 0 to 100 million users

Micro Deploy

Page 26: Growing from 0 to 100 million users

50 million users and we continue to

grow.

Page 27: Growing from 0 to 100 million users

Infrastructure as Code

Define infrastructure as code to increase operator productivity and transparency.

COLLABORATE & SHARE

Terraform configuration can be stored in version control, shared, and collaborated on by teams of operators.

EVOLVE YOUR INFRASTRUCTURE

Track the complete history of infrastructure versions.

AUTOMATION FRIENDLY

If it can be codified, it can be automated.

Page 28: Growing from 0 to 100 million users

Application Load Balancer

Page 29: Growing from 0 to 100 million users

Differences with elastic load balancer

Page 30: Growing from 0 to 100 million users

Maintaining Quality at Scale

Page 31: Growing from 0 to 100 million users

Maintaining Quality at Scale

Page 32: Growing from 0 to 100 million users

Micro Deploy

Page 33: Growing from 0 to 100 million users

Real Cases

Page 34: Growing from 0 to 100 million users

Netflix bandwidth usage climbs to nearly 37% of internet traffic at peak

hours.

Page 35: Growing from 0 to 100 million users
Page 36: Growing from 0 to 100 million users

Questions?