Migrating data-intensive
microservices from Python to Go
Nikolay Stoitsev
Engineering Manager @ Uber
Slide 3
Slide 3 text
Early years
Dispatch API Storage
Slide 4
Slide 4 text
Early years
Dispatch API Storage
Python
Node.js
Slide 5
Slide 5 text
Invoice
Generation
Service
Slide 6
Slide 6 text
Background
Legal document
Slide 7
Slide 7 text
Background
Legal document
Vary by country
Slide 8
Slide 8 text
Background
Legal document
Vary by country
Vary by business line
Slide 9
Slide 9 text
Background
Legal document
Vary by country
Vary by business line
Triggered after every trip or food
delivery
Slide 10
Slide 10 text
Sample architecture
Money
System
Cassandra
Kafka Preprocess Render
Kafka
Consumer
Object Store
Slide 11
Slide 11 text
More than 30 upstream systems
Large Scale
Slide 12
Slide 12 text
More than 30 upstream systems
More than 100 TBs of data stored
Large Scale
Slide 13
Slide 13 text
More than 30 upstream systems
More than 100 TBs of data stored
Running on 400 containers
in multiple DCs
Large Scale
Slide 14
Slide 14 text
More than 30 upstream systems
More than 100 TBs of data stored
Running on 400 containers
in multiple DCs
Running for 5 years
Large Scale
Slide 15
Slide 15 text
More than 30 upstream systems
More than 100 TBs of data stored
Running on 400 containers
in multiple DCs
Running for 5 years
99.999% availability for last 6 months
Large Scale
Slide 16
Slide 16 text
More than 30 upstream systems
More than 100 TBs of data stored
Running on 400 containers
in multiple DCs
Running for 5 years
99.999% availability for last 6 months
Implemented in Python
Large Scale
Slide 17
Slide 17 text
Sample architecture
Money
System
Cassandra
Kafka Preprocess Render
Kafka
Consumer
Object Store
Web API
Hive
Slide 18
Slide 18 text
Building blocks
http://flask.pocoo.org
Slide 19
Slide 19 text
Flask Example
Slide 20
Slide 20 text
Flask Usage
Slide 21
Slide 21 text
MVCS
Slide 22
Slide 22 text
MVCS
Controller
Mapper
Service Entities
External
Services
Database
Slide 23
Slide 23 text
Building blocks
https://uwsgi-docs.readthedocs.io/
What we need for each language?
Training / Best practices /
Documentation / Experts
Slide 30
Slide 30 text
What we need for each language?
Training / Best practices /
Documentation / Experts
Project template /
Bootstrapping
Slide 31
Slide 31 text
What we need for each language?
Training / Best practices /
Documentation / Experts
Project template /
Bootstrapping
Configuration
Slide 32
Slide 32 text
What we need for each language?
Training / Best practices /
Documentation / Experts
Project template /
Bootstrapping
Configuration
Debuggers
Slide 33
Slide 33 text
What we need for each language?
Training / Best practices /
Documentation / Experts
Project template /
Bootstrapping
Configuration
Debuggers
Profilers
Slide 34
Slide 34 text
What we need for each language?
Training / Best practices /
Documentation / Experts
Project template /
Bootstrapping
Configuration
Debuggers
Profilers
Building, Packaging,
Deploying