Microservices Decomposition Pattern
DEEPANSHU JAIN
Director Of Engineering | Ex BlackRock | Ex Religare Health Insurance | Ex Shopclues
Decomposition is the crucial step in converting a monolithic Application to a system following Microservices Architecture.
Microservices Decomposition Pattern is a strategy used in software architecture to break down a monolithic application into smaller, more manageable microservices. This pattern aims to enhance the scalability, agility, and maintainability of the software system by dividing it into loosely coupled components, each responsible for a specific business function.
Before decomposing the microservices, there are some important things to consider.
Decomposition is done by following 2 strategies :
Decompose by Business Capability
This strategy suggests :
领英推荐
In simple terms, before splitting up microservices, make sure they each have a clear job to do and can work independently without causing problems for other services. Follow the pattern of breaking down by what the business needs, and ensure that each service adds value to the overall business goals.
Decompose by Sub-Domain
To use the "Decompose by Subdomain" model, we need to create services based on different parts of our business. We call these parts "subdomains." Think of a subdomain as a specific area within our business, like sales, inventory, or customer service. Each of these areas does something different and has its own set of tasks. So, we create services that match each of these subdomains. This helps us organize our software based on how our business works in real life.
To find out these different parts of our business, we need to know about two important things: DDD and Bounded Context patterns.
So, to figure out our business's different parts, we need to learn about DDD and Bounded Context. They help us see the big picture and break it down into smaller, understandable pieces.