Microservices: Why So Serious?

CodeX Developer
3 min readJan 18, 2022

In the last couple of years, the word microservices becomes a hot topic among software developers as this is one of the most reliable techniques to build large scale distributed systems. Even in the current demand for skills, the microservice experience is one of the most desirable skills that any developer can have. So let’s understand why we should get serious about the microservice.

Microservice are a set of software that works together to serve a single purpose. Just like a cell phone or a computer which helps us to solve multiple days to day tasks by a combination of some software, but combined it knows as one entity i.e laptop or mobile phone.

In the same manner when you want to build a software that has a large functionality set then we have two approaches either we go for a normal(and older technique) monolithic and we go for a microservice way. In terms of benefits, microservices gave us a large variety of benefits as compared to monolithic services. Here are some of them

Can Scale Independently: Microservices are a set of services that works together to serve a purpose but internally they are self stand-alone software that can run, perform and scale independently. If I have software with 40 microservices and out of the 10 services are heavily loaded with traffic then I am not bound to scale my complete software I just can scale those 10 microservices and we are good to go

Reduced Downtime: With microservices, we can reduce the downtime of our software to almost ZERO. Let's take the above example, if out of 40 microservices if my 4 services are down, in that case, I can either apply the circuit-breaker pattern or I just easily can re-direct the traffic and respond back to the user with some default response code, and once the 4 services are up I can process those request. This gives the user a faultless and issue-free experience while using the web application.

Easy to understand: Being new to the software, it takes time to understand the complete software but if you are given a small service that serves a few types of requests that would be easy to understand.

Faster Development: With microservices, multiple developers can work independently on the same software. Like Mr X can work on frontend, Mr Y can work on API development, Mr Z can work on the scheduling part and so on there is no dependency of one another at the time of development as the information is shared normally in for of JSON, a developer can work on their service without even bothering others

Easy to Test: A small service is easy to test than to test everything on a large scale distributed system.

Data Isolation: Each and every microservice is separated from others, thus this gives us the flexibility to build software that can maintain and isolate the data from others. In many software, there are different types of data that are not required to share even with other teams in the same company. Earlier it was quite tough to manage this because everyone works on a single software but with microservices, it can be easily achievable using service-specific data and database.

Use of Technology as per Need: Let’s suppose you have software that is completely written in python, now you want to use the executed framework of java, how will you do that? …And the answer is microservices, using microservices you can easily build software that can have multiple languages, multiple DB, multiple caches and message brokers etc. These are microservices are connected using a common medium, which is a contract between all the services. After that, it doesn't matter if you build the service-1 in Golang, service-2 in Kotlin and service-3 java.

If you also think that microservices are better than monolithic, then like and share this article if don’t then wait for the next article to know WHY YOU SHOULD NOT USE MICROSERVICES.

--

--