πŸ“šWhat is Microservice ?

Describe about Microservice

This is the most popular concept that all of the developer team followed in present. Monolith is the concept that we designed our system to be single application and has only one centralized. For this concept, It is hard to scale the application when it is big and hard for new joiner to understand the system. Microservice is the concept that distribute the system to multiple service or it call modular. Each services will be responsible for their own. It will have serparate Database and team owner. Advantage

  1. Easy for scalability because the team owner will be responsible for that.

  2. Easy to understand business concept because we seperate each business logic to each specific domain.

  3. Can use different stack for each team

Drawbacks

  1. Need to think about eventual consistency

  2. Since we distribute the system then we need to handle for failure case and understand the design.

  3. Reduce availability because when service A is running , service B can be down so we need to think about fallback case.

Since the system is loosely couple and distribute so It will has a lot of problems. There are a lot of patterns that you need to learn to handle these problems.

Pattern

  1. Saga

  2. Command Side Replica

  3. API Composition

  4. Messaging

  5. API Gateway

  6. Circuit breaker

Last updated