Saturday, October 12, 2019

Microservices

What do we understand by microservices?


Microservice is basically decoupling of entire application into small small services, like take example of Amazon,  in Amazon we'll have many partners like seller then we will have buyers and at the end we'll have persons from Amazon who will be managing all the applications or we'll be seeing the transactions and every other details so we will mention it as an admin. 


This is an entire application and say suppose it is written in Java so what happen is if I need to change something in buyer I need to  give an offer of 5% so what I need to do is to write the code and deploy the entire application. 


Instead of this we can use microservice based architecture where the seller will be a single application, buyer will be another application and the admin would be another application. So here what happen is if the admin is down or like if the server is down not the entire Amazon website is down. 




If admin is down people can use the buyer option or if the seller is down seller will not be able to add any further items to his store but the buyer can able to check out from his cart and or you can add anything from other sellers or which are already in the stores and if suppose I want to change something in seller and want to deploy, so I will just go and deploy this application which will not disturb admin or buyer.



Monolithic vs Micro services:






Advantages:


- Independently develop and deploy the services

- Isolation - If one service fails, the other service will continue to work
- Micro services of an application can be written in different languages
- Micro service architecture enables the continuous delivery
- Micro services are scalable and reusable
- Security monitoring will be simplified by using micro services.

2 comments:

Whats new in Angular 8

Angular 8 was released in May 2019 and  th e key features of angular 8 are as follows in brief, Differential loading Dynamic imports ...