Introduction to SKP's Microservices Masterclass Series
SKP's Microservices Masterclass is a Series of Articles on Microservices Architecture (MSA) - Starting with the Needs and Motivations of Microservices, Moving to the Shortcomings of Monolithic Architecture and Also Covering Microservices Design Patterns, Pitfalls of Microservices, Major Microservices Infrastructure Components - Description, Evaluation and Code Samples, Containers, Native Microservices, Cloud Platforms, Messaging Layers, Security and Logging. We will Provide the Readers with Obelix, A Microservices Architecture Reference Implementation! You May Use this as the Starting Point for your Microservices Architecture. You may Also Directly Use this as a Reference Implementation for your Microservices Strategy and/or as Code to Learn and Implement the Microservices Architecture for your Organization.
The Setup of Microservices Requires More Efforts as there a Lot of Infrastructural Architectural Pieces as part of a Complete Microservices Architecture. For Example - API Gateway, Circuit Breaker, Discovery Server, Config Server, Health Monitoring, Vault Service, Token Service, Logging & Auditing - These are Just a Few of the Initial Infrastructural Services Required to Correctly Implement a Complete Microservices Architecture in the Enterprise.
There is a High Skill Level Require Especially in Terms of Experienced Senior Architects, DevOps and Developers who can Now Understand the Change in Development Paradigm. Also, This May Either Increase the Development Time or Development Costs or Both.
One of The Most Important Disadvantages of Microservices is the Complexity Involved. Even Though the Point is Captured in the Above 2 Points - It Still Requires a Mention on its Own. The Interplay of the Plethora of Infrastructural Services along with the Actual Application Microservices may Create Unending Cycle(s) of Complexity.
During Development, the Architects and Lead Engineers may Need to Keep a Watch on Making Sure that there is No Duplication of Code, Configuration or any other Effort that may Already have been Developed by Another Team. This Starts Becoming a Greater Concern when there are Geographically Distributed Teams and Focussing Entirely on their Own Set of Business or Product Deliverables. Though some very Trivial Code Duplication may be Inevitable as far as Possible - Discipline will be Required to Isolate and Group Common Functionality or Code Together Correctly.
One of the Greatest Challenge is Data Duplication. Most Inexperienced Architects and Engineers may end up in Such Situations. It is because the Thought that was required to Build Monolith Data Access and Creation cannot Now be used for Microservices. The Mechanism to Maintain Data Integrity and Data Consistency in a Product to Make Sure that There Exits a Correct 'Single Version of Truth' Needs to be Planned, Architected and Infused into the Design.
The Communication Between External World and Microservices or within Microservices may Fail. This could be Due to Multiple Reasons Including Network Failure and Service Unavailability. In any Case, The Communication Between Microservices is Critical and is Tough to Setup and Maintain. It also Requires Constant Monitoring of Health and Performance of Each of the Microservices. Partial Failures is actually an Advantage of Microservices - But Still the Monitoring, Failure Detection, Failure Handling and Simply the Internal/External Communication can be Quite an Overhead in the Implementation of Microservices.
So, Once the Initial Part is Over - Even If the Microservices Strategy and Implementation Turns out to be a Success - It still Means a Heavy Hit on the Pocket for Maintenance. Even though all of the Current Generation Organizations Rely on an External Cloud Provider, It Still Means More Expenditure on Hardware, 'Software', Cloud, DevOps Engineers. Also, the Total Cost of Ownership of Such an Infrastructural Masterpiece is Only Bound to Increase as More Abstractions are Added Over Time - Also, The Maintenance Itself could be a Complicated Process.
FIG.4 : THE 2021 STATE OF MICROSERVICES REPORT (CREDITS TO www.jrebel.org - OBTAINED FROM GOOGLE SEARCH)