Monolithic vs Microservices Architecture
January 13, 2025•218 words
(Part I of the study notes for the DevOps Concepts course on DataCamp (link))
Imagine you are building a software. You could consider the monolithic architecture, which is basically a single unified software application that is self-contained and independent from other applications. A monolithic architecture may be suitable for small-scale projects, but most likely it gets clunky, unscalable, and almost impossible to maintain at a larger scale.
A good solution for large scale projects is the microservices architecture. It is basically a collection of loosely coupled, fine-grained smaller programs. Each microservice does their own job, and they communicate with each other via an Application Programming Interface (API). This is an attractive approach because changes / updates in one microservice won't affect another unless the API is somehow also modified.
There are also implications on data engineering when choosing between monolithic and microservices architectures. The following table extracted from the online course makes a brief comparison.
Monolithic Architecture | Microservices Architecture |
---|---|
A limited number of databases | A database for each microservice |
All applications use the same databases | Microservices must do API calls to reach another service's database. |
Could be a viable option for small scale applications | Effective in large organizations and complex products |