Media.net venturing to private cloud arrow_forward
The rocky road from monolithic to microservices architecture
Submitted by Srinivasan Rangarajan (@cnu) on Friday, 27 October 2017
Technical level: Intermediate
Delivering Artificial Intelligence/Machine Learning products at scale is hard, especially when each user wants a personalized experience.
Vue.ai is an AI Platform which has different products built on top of it to automate the retail domain. It started out as a non-scalable prototype with a small set of features and grew to the current version with multiple microservices serving millions of users every day.
Today, there are separate microservices to handle catalog ingestion, image processing, image search, apply ML models on user event data (page view, buy, add to cart) and serve personalized results via REST APIs.
During the process of building this platform we learnt a lot of lessons, including where to use asynchronous vs synchronous, why caching can’t help you everytime, and why you should always have immutable microservices.
When it was a monolithic architecture, we used the EC2 servers as plain linux boxes without any ability to automatically scale. One of the main advantages we got out of the rearchitecture is the use of multiple managed services available in AWS and the stability. We also made sure things can scale and we started using cost effective components like serverless lambda functions, docker containers, etc.
- Explanation about the monolithic v0.1
a. Problems we faced
- Microservices and how it all ties together
- Advantages, including how personalization is now possible.
- Mistakes we made, especially in infra/resource allocation.
- Improvements that are still needed.
- Things to remember when you make the shift to microservices.
Srini has been helping startups build scalable and distributed systems for the past 10+ years. Currently he is scaling AI to millions of retail consumers all over the world by making sure the Engineering team builds and delivers the best AI products at Mad Street Den.