I’m a little hesitant to write this post as it might attract some criticism. Nonetheless, I told myself that there was nothing wrong with sharing my point of view (although it might not be well accepted). I would like to share my personal experience regarding yesterday’s monolithic architecture and today’s Microservice architecture in this article.
The monolithic application of yesterday
20 years ago, I started my career. At that time, I was working for a large financial firm in North America. The middleware platform of this financial institution was running CORBA, a C ++ platform. Since CORBA was phasing out at this time, the technology vendor decided to no longer support CORBA. It was a huge risk for the company to run its critical middleware platform on unsupported technology. Thus, management decided to port its middleware application to a platform independent technology stack: “SOAP” and “Java”, which was considered the cool kid of the time. There were about 500+ services running on this C ++, CORBA stack. They carried all these services in SOAP / Java technology. It was one of the biggest portages in the industry at the time. Since then, all the new services that they have developed to meet growing business demand have also been written on this new platform. So what is the relationship between this technological migration and this position? Have I gone too far? Not really…
Surprisingly, all of these 500+ services were built from a single codebase and deployed on a single JVM instance – perfectly meeting the current definition of “monolithic” architecture. But interestingly, all of those 500+ services were running on a JVM instance, which only had a memory size of 2 GB (-Xmx). When I tell a few millennial engineers this size of memory now, they can’t believe it. They ask “Are you sure? Are you getting too old? Is memory faded? »I am 100% sure my memory has not faded :-). However, they had multiple 2GB JVM instances to handle the inbound traffic. Many of these services are critical and sensitive transactions like “Transaction History List”, “Funds Transfer”, “Get Account Details”, “Get Client Details”…. This middleware platform handled millions of transactions / day beautifully with tight SLAs down to the millisecond level.
Now let’s move forward 20 years. We are now in the world 2021 Microservices, containers, kubernetes. In my personal career, after an incredible amount of struggle and pain, I have moved on to build a * small * profitable tech company. Our company specializes in building performance engineering tools (GCeasy, HeapHero, fastThread, yCrash). Glad to see the world’s largest companies using our tool sets. Due to this current role, I have the opportunity to see the architecture and deployments of large companies, which use our products. I noticed that several companies were considering switching to the “Microservices” architecture or were already in the process of switching to the “Microservices” architecture. We might also see a few companies that have already switched to Microservices architecture. But one specific observation is this: Many of the memory sizes for these microservice applications are quite large. They are in the range of 10 GB, 20 GB, … 100 GB. It is getting harder and harder to see modern business applications running under a 2 GB heap. On top of that, times response is also degraded, due to multiple network hops between Microservices and garbage collection.
Does this mean that modern apps consume more memory than its predecessors? Here’s a study we published earlier highlighting the the inefficiencies of one of the world’s most famous modern frameworks.
So, I ask myself the question: do modern applications / Microservice consume more resources than monolithic applications of yesterday? Is the road the industry we are taking in the right direction?
Please do not interpret that I am lobbying against the Microservice architecture. I can clearly see the advantages of the Microservice architecture: rapid development, decoupled deployments, reduced test cycles, multilingual programming … Here, I only express concerns about the size of the increasing memory, the response time and its cost. associated calculation, complexity. Do not hesitate to share your experiences / thoughts!