Monolithic Vs Microservices
Monolithic Vs Microservices
• Simple to develop.
• Simple to test. For example, you can implement end-to-end
testing by simply launching the application and testing the UI
with Selenium.
• Simple to deploy. You just have to copy the packaged
application to a server.
• Simple to scale horizontally by running multiple copies behind
a load balancer.
In the early stages of the project it works well and basically most of
the big and successful applications which exist today were started
as a monolith.
Microservices Architecture
The idea is to split your application into a set of smaller,
interconnected services instead of building a single monolithic
application. Each microservice is a small application that has its
own hexagonal architecture consisting of business logic along with
various adapters. Some microservices would expose a REST, RPC
or message-based API and most services consume APIs provided
by other services. Other microservices might implement a web UI.
Some APIs are also exposed to the mobile, desktop, web apps. The
apps don’t, however, have direct access to the back-end services.
Instead, communication is mediated by an intermediary known as
an API Gateway. The API Gateway is responsible for tasks such as
load balancing, caching, access control, API metering, and
monitoring.
The Microservice architecture pattern corresponds to the Y-axis
scaling of the Scale Cube model of scalability.