Living with microservices at Pipedrive
-
Upload
renno-reinurm -
Category
Engineering
-
view
3.504 -
download
2
Transcript of Living with microservices at Pipedrive
![Page 1: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/1.jpg)
Living with microservices@Pipedrive
Renno ReinumA developer’s best friend
![Page 2: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/2.jpg)
KerberosThe Guard of Underworld
Deploy or not to deploy
That is the question
![Page 3: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/3.jpg)
● Pipedrive helps small businesses control the complex selling process
● Founded in 2010● 30,000 paying customers worldwide● 170+ employees● Office in Tallinn and Tartu
New York, NY
![Page 4: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/4.jpg)
● 20,000+ simultaneous online users
![Page 5: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/5.jpg)
● 20,000+ simultaneous online users
● 800+ API req/sec
![Page 6: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/6.jpg)
● 20,000+ simultaneous online users
● 800+ API req/sec
● 400,000+ incoming emails per day
![Page 7: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/7.jpg)
● 20,000+ simultaneous online users
● 800+ API req/sec
● 400,000+ incoming emails per day
● Started with Node.js based microservices, reactive
architecture in 2012
![Page 8: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/8.jpg)
● 20,000+ simultaneous online users
● 800+ API req/sec
● 400,000+ incoming emails per day
● Started with Node.js based microservices, reactive
architecture in 2012
● In total, 500+ VMs/hosts/instances
![Page 9: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/9.jpg)
● 20,000+ simultaneous online users
● 800+ API req/sec
● 400,000+ incoming emails per day
● Started with Node.js based microservices, reactive
architecture in 2012
● In total, 500+ VMs/hosts/instances
● More than 300 deploys per month
![Page 10: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/10.jpg)
Pipedrive helps small businesses control the complex selling process
![Page 11: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/11.jpg)
Evolution of the application
The birth of monolith: Only kanban board
![Page 12: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/12.jpg)
Evolution of the application
New features added:Monolith growing
![Page 13: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/13.jpg)
Evolution of the application
Bloated monolith:Application slowing down
![Page 14: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/14.jpg)
![Page 15: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/15.jpg)
Once upon a time
● We need to keep the pace of delivering services!
● Teams need to be independent of each other● How can we add new features daily basis and
still maintain it?● Lets split it into microservices
![Page 16: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/16.jpg)
Introduction to Microservice
Developers should write programs that can communicate easily with other programs.
Break down projects into small, simple programs rather than overly complex monolithic programs.
Eric Raymond - Unix Philosophy
![Page 17: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/17.jpg)
Monolith vs Microservices
● Microservices systems are more flexible, loosely-coupled and scalable● Easier to develop and easier to change● More tolerant of failure. In case of one mircoservice fails, others should be
operational
http://www.randomant.net/the-cloud-is-a-paradigm-shift-in-software-dev/
![Page 18: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/18.jpg)
And the new era begins
Deployment of new microservice
From idea to production - minimum 2 WEEKS
![Page 19: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/19.jpg)
Characteristics of microservices (by Martin Fowler)
● Componentization via services
● Organized around business capabilities
● Products not projects
● Smart endpoints & dumb pipes
● Decentralized governance● Design for failure
● Infrastructure automation
![Page 20: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/20.jpg)
![Page 21: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/21.jpg)
Virtual Machines vs Containers (Docker)
http://www.docker.com/what-docker
![Page 22: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/22.jpg)
Visibility
Management
Interface
![Page 23: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/23.jpg)
Visibility
Management
Interface
![Page 24: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/24.jpg)
How not to create microservices or any other automation flows
● CI job hell● Discovery● Configurations hell
![Page 25: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/25.jpg)
Mindshift of Developers
● Building● Testing● Discovery● Monitoring● Logging● Alerting● Dashboards
![Page 26: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/26.jpg)
Agile Culturein Pipedrive
Agile and lean means small and fast and independent and in Pipedrive we operate by small cross-functional teams which deliver regularly. Those teams win small battles every day but their operations are supported by different types of other troops.
![Page 27: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/27.jpg)
Devops Culture
in Pipedrive
![Page 28: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/28.jpg)
Mindshift of Developers -Now I master the Microservice concept
● Dockerfiles● Docker-compose● CI builds● Tests● Service discovery● From idea to production
1 DAY
![Page 29: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/29.jpg)
CI processes with Docker● Provisioning of build
environment● Pulling Docker images● Docker builds
xkcd.com
![Page 30: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/30.jpg)
CI processes with Docker● Whole CI process can take a 1 - 3
minutes
xkcd.com
![Page 31: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/31.jpg)
CI processes with DockerFeedback from Developers:
● It’s still too sl.oOW
xkcd.com
![Page 32: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/32.jpg)
CI processes with DockerFeedback from Developers:
● It’s still too sl.oOW● Make it slower, I can’t grab a
coffee
xkcd.com
![Page 33: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/33.jpg)
Service developer wants to run
Services we require to run on the server
![Page 34: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/34.jpg)
Challenges to be resolved
● Multi-datacenter/regions● Autoscaling of containers● Rollbacks● Secrets management● Development environment
![Page 35: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/35.jpg)
Beware of the Gold Fever
“To make error is human. To propagate error to all server in automatic way is #devops.”
![Page 36: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/36.jpg)
Final Thoughts
● Define the problem you need to solve● The right answer > 1
![Page 37: Living with microservices at Pipedrive](https://reader033.fdocuments.us/reader033/viewer/2022051520/58f9ad69760da3da068b97ee/html5/thumbnails/37.jpg)
Final Thoughts
● Define the problem you need to solve.● The right answer > 1
Thank you!
Feedback is highly encouraged :)
@rreinurm