Advantages of Microservices

In comparison to monolithic and SOA, choosing the microservices architecture would reap the following advantages:

  1. Cost-effective to scale: You don’t need to invest a lot to make the entire application scalable. In terms of a shopping cart, we could simply load balance the product search module and the order-processing module while leaving out less frequently used operational services, such as inventory management, order cancellation, and delivery confirmation.
  2. Clear code boundaries: The code should match an organization’s departmental hierarchies. With different departments sponsoring product development in large enterprises, this can be a huge advantage.
  3. Easier code changes: The code is done in a way that is not dependent on the code of other modules and only achieves isolated functionality. If done right, then the chances of a change in a microservice affecting another microservice are minimal.
  4. Easy deployment: Since the entire application is more like a group of ecosystems that are isolated from each other, deployment can be done one microservice at a time, if required. Failure in any one of these would not bring the entire system down.
  5. Technology adaptation: You could port a single microservice or a whole bunch of them overnight to a different technology, without your users even knowing about it. One just need to remember to maintain those service contracts.
  6. Distributed system: The meaning is implied here, but a word of caution is necessary. Make sure that your asynchronous calls are used well and synchronous ones are not really blocking the whole flow of information. Use data partitioning well. We will come to this a little later, in the Data partition section of this chapter, so don’t worry for now.
  7. Quick market response: The world being competitive is a definite advantage. Users tend to quickly lose interest if you are slow to respond to new feature requests or the adoption of new technology within your system.

You might be interested in the following courses:

Course Category

Back to: Microservices with C#, .NET Core and Azure > Introduction