Monolithic Vs Microservice Architecture

Posted By : Manish Kumar Narang | 31-Dec-2017

Lately, we felt a need to migrate from Monothilic to Microservice Architecture. In this post, we will see the pros and cons of both architectural framework.

Monolithic Architecture is what we all are quite familiar with where basically we have one storing unit (Database) and all the application services use for storing and retrieving data. Now the pros of this architecture are quite straight forward. Since all the IDEs are designed to support single application, they are easy to develop and deploy on a server. They can be scaled easily by just having many copies to run with a load balancer. In the early phases of development, monolithic architecture works well but as the size of the application starts to grow and various modules are piled up, the limitation of this architecture shows up.  

 

The main drawback is that if the size of the application grows appreciably, it becomes very hard for a single developer to understand it. Also, its very difficult to include new innovations in the form of frameworks, languages etc. One gets stuck with the technologies and frameworks which were used in the beginning of the development of the project. Every time the whole application needs to be deployed on production even for minor changes in the code.  We briefly summaries the pros and cons of Monolithic Architecture.

 

Pros of Monolith Architecture -

  • Simplicity, for small codebases
  • Faster early development speed
  • Easy testing
  • IDE support

 

Cons of Monolith Architecture -

  • Not Ideal for growing codebases 
  • Slowing Iterations in the long term
  • Harder to Innovate
  • Steep code learning curve

 

One of the main motivations to research about Microservice architecture was that we wanted to make use of newer frameworks and languages which became available to us with time and not just stuck with the technologies which we used at the start of development of our application. We wanted to get rid of the technologies which have become obsolete so that people who are freshly hired can work on latest technologies and be more productive.

 

We know that a few companies like Amazon, eBay and Netflix have already made use of Microservice Architecture. The essential idea is to have many interconnected small service routines instead of a huge single application.  Though the servies are interconnected, they function independently and therefore one can have different services being developed in different frameworks and languages. Each service has its own designated database and a well defined boundry in the form of message driven API.  Due to such decomposition, each service is simple to develop and easy to understand for a single developer. Moreover, unlike monolithic architecture, if one service goes down, the other services keeps the application running. Each service therefore can be scaled differently. We briefly summaries the pros and cons of Microservice Architecture.

 

Pros of Microservice Architecture -

  • Better Architecture for large applications 
  • Better agility in the long term
  • Microservices : easy to learn
  • Isolation for scalability and damage control

 

Cons of Microservice Architecture -

  • More moving parts 
  • Complex infrastructure requirements
  • Consistency and Availability
  • Harder to test

 

About Author

Author Image
Manish Kumar Narang

Manish is an experienced Backend Developer with several years of industry experience in the IT field. He possesses a wide range of skills, including expertise in Backend languages like Core Java, J2EE, Hibernate, Spring/Spring Boot, and Python. Manish is also proficient in relational databases such as MySQL, PostgreSQL, and Oracle. He has hands-on experience in API implementations, web services development, testing, and deployments. Manish has contributed to various internal and client projects, including PMO, Catalyst, Communication-Scaffold, Oodles-Dashboard, and Devops Support, delivering significant business value. He is known for his innovative mindset and excellent problem-solving abilities. He keeps himself updated with new technologies by reading about them. He is skilled at collaborating closely with clients to define project scope and requirements, establish project timelines and milestones, and manage expectations. Manish conducts regular project status meetings, ensuring regular updates to clients and stakeholders regarding project progress, risks, and issues. Additionally, he serves as a mentor and coach to junior developers, offering guidance on project management best practices and fostering their skills development.

Request for Proposal

Name is required

Comment is required

Sending message..