All modern system architectures follow two main patterns:
- The first pattern is microservices,
- The second pattern is being cloud-native.
To understand microservices, you must understand what a monolithic system is. A software system is “monolithic” if it has a monolithic architecture, in which functionally different aspects are all interwoven, packaged, and deployed as a whole, rather than containing architecturally separate components that deploy independently.
At first, monolithic systems are easy to develop, manage and deploy. An example can be a UI form to ingest data and persisted that data into a database. A small application is born.
Another client loving this solution ask for another form built to persist their data. We do have some standard routines that might leverage connecting and storing data in a database. The main difference between the new functionality and the preceding functionality is in the business logic of validating the form, so we decide to grow monolithically. After the first year, you have ten different clients and their UI forms in this monolith application.
As the popularity of the application grows, so will the functionality become rich. This ever-expanding functionality will make the monolithic architecture grow in size. Over time this is becoming unruly, and deployment times become longer and longer.
The challenge for new developers is to learn the whole code base and make changes without regression testing of all of the code. New developers are skeptical about making changes because of the uncertainty of breaking the entire code base. The application is seemingly brittle.
Any changes to a form for one client will mean that the application will need to be redeployed and impact all clients. If this application is scaled horizontally, the deployment Must happen on each node, and the deployment effort becomes heroic to ensure all clients are back to business as usual.
Another interesting challenge is that all the development is coded in one development language. The monolith needs to be compiled and packaged by the same compiler. A uni-compiler infrastructure may stunt the application’s growth if other staff members who are skilled in other languages are unable to contribute to the project.
Just based on these challenges of the monolith, we can see how microservices could be a solution. Microservices are initially more work to set up but will pay long-term dividends, Especially if more clients subscribe to the service.
Each service will run in its container and be developed in any language Independently of the other functionality. A multi-compiler architecture will mean that there’s less risk when changing any independent components. Functionality can support separate deployments and can more easily be regression tested. The services will communicate via APIs.
Microservices running in the cloud will make your application modern. I have written on why cloud architecture is relevant to modern architecture. You can see the details on this link.