<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Jayan on Medium]]></title>
        <description><![CDATA[Stories by Jayan on Medium]]></description>
        <link>https://medium.com/@jayank?source=rss-a823d9c1e833------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/2*c47yEWGVKre7HVJIXgkicg.jpeg</url>
            <title>Stories by Jayan on Medium</title>
            <link>https://medium.com/@jayank?source=rss-a823d9c1e833------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 27 Nov 2026 09:55:05 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@jayank/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Monolith vs Microservices: The Quintessential Dilemma]]></title>
            <link>https://medium.com/null-pointer/monolith-vs-microservices-the-quintessential-dilemma-694fe4613e43?source=rss-a823d9c1e833------2</link>
            <guid isPermaLink="false">https://medium.com/p/694fe4613e43</guid>
            <category><![CDATA[microservices]]></category>
            <category><![CDATA[hybrid]]></category>
            <category><![CDATA[monolith]]></category>
            <category><![CDATA[distributed-systems]]></category>
            <dc:creator><![CDATA[Jayan]]></dc:creator>
            <pubDate>Fri, 24 Apr 2020 10:00:42 GMT</pubDate>
            <atom:updated>2020-04-24T10:00:42.169Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="Photo by Magda Ehlers from Pexels" src="https://cdn-images-1.medium.com/max/1024/1*EDyDFf8swhnlJiRxoH1icg.jpeg" /></figure><p>Since the microservices architectural pattern started being viewed as the default or as one of the best development and deployment practice (for myriad of reasons), there have been strong opinions floating around the topic <strong>Monolith vs Microservices — which one to pick to start with</strong>?</p><p>The debate on this is as old as the advent of microservices and there are many articles &amp; discussions on the web emphasising the pros and cons. And in the last few weeks, we seen articles ([<a href="#46d6">1</a>][<a href="#3691">2</a>][<a href="#879e">3</a>]) mentioning the return of monoliths or emergence of new alternate patterns. While I agree that new pattern(s) will emerge in due course, it is hard to take away microservices completely. My take is that this architecture will remain as long as it is used for the right reasons.</p><p>I am sure there is no need to explain what a monolith is, what are microservices, their respective features and advantages microservices have when compared to monoliths. A microservice based architecture excels at the ease in ownership, isolation &amp; individual scaling and well scoped domains. Monoliths have their own associated problems and hence microservices as a pattern had its foray.</p><p>If you read the articles explaining the practices followed in the software community currently, a common pattern emerges out - API calls over the network replacing function calls, simple classes &amp; objects. Developers expect the API calls made will return in time almost always and the network performance will be at par most of the time. The software is split into smaller &amp; smaller units, claiming it as the best disciplined practice ever.</p><p>Since containers and kubernetes are the de-facto deployment choices currently, and given its availability in multiple flavours and as managed services, many teams pick their default architecture pattern as microservices, without giving a second &amp; and may be, a third thought. The multitude of tools that are available for this ecosystem makes the turnaround time less to develop and deploy a bunch of services.</p><p>I agree that the networking has evolved to a highly reliable state now a days. However, with each new smaller unit created, the number of API calls increases, the maintenance overhead increases &amp; the possible failures compound. This proliferation of microservices based on half-baked assumptions without real performance or business needs also affects how the Site Reliability Engineering teams function.</p><p>Every architectural pattern solves a set of problems and avoids common software traps and pitfalls. The software developers of the world strive towards getting the optimal architecture out there. However, using the right pattern to solve the problem at hand is important. The microservice architectural choice may not be always a wise decision every given time, as adopting microservices will also lead to increase in financials of hiring &amp; infrastructure. Over applying a solution to its extreme will create more chaos than being useful. <strong>On that note, are we in an age where microservice strategy is over applied?</strong></p><p>With this context as background, some of the points which we used to arrive at a decision point are listed below.</p><p><strong><em>Before setting services in stone, observe the patterns:</em></strong></p><ul><li>Microservices boundary decisions are tricky. The early adoption of microservices may bring in too much churn of changing boundaries for your services as your understanding, complexities and the business evolves. This has a direct impact on the devops and the ever changing model slows down the upgrade and adoption as opposed to speeding up.</li><li>Even if the system being designed has the well-defined patterns like event sourcing and saga pattern, its better off to start with a monolith / absolute minimal set of services and getting the functionalities and boundaries right before breaking down into microservices. This is because it is hard to get it right the very first time, point of failures will be many with microservices and building a robust system introduces more devops and monitoring concepts thus making going live a distant reality</li></ul><p><strong><em>Monitoring of services</em></strong>:</p><ul><li>Don’t deploy microservices unless the monitoring paradigms, tooling is defined and decided upon.</li><li>Unless the monitoring is well defined with the correct logs &amp; alerts and a proper incident management process, an outage will turn out to be a treasure hunt.</li></ul><p><strong><em>Hybrid is not bad thing</em></strong>:</p><ul><li>There is nothing wrong in following a hybrid pattern. We can build a monolith which communicates with other microservices for specific purposes</li><li>This will help to spend the time on how to get the functionalities out in the right way</li></ul><p><strong><em>Migrate towards Microservices when scaling becomes a challenge</em></strong>:</p><ul><li>If you have reached at a stage where scaling is an issue, you are too far in the development where you have not figured the boundaries. It is time to act upon!! Shift gears!!</li><li>Brainstorm on the boundaries (business domains, functional &amp; technical aspects) and start modularising the monolith</li></ul><p><strong><em>Understand Interdependencies &amp; States</em>:</strong></p><ul><li>Interdependencies between services need to be closely monitored. Downtime of services, service outages, service upgrades, etc can all have cascading downstream effects and such impact should be proactively analysed.</li><li>Stateless microservices are the utopian need, but in reality, the downtime of services results in cascading effect.</li><li>Understanding these interdependencies and states is important before defining boundaries, have appropriate logging and monitoring that signals the cascading effects of an outage.</li></ul><p><strong><em>Include Network in Cost calculations</em>:</strong></p><ul><li>API calls doesn’t come for free. There is a network cost associated with it. We should consider it in our cost calculations.</li><li>Invest in throttling, failure fallbacks, proper error handling &amp; retries where it makes sense at the first go and evolve later. It’s fine not to be 100% when starting.</li></ul><p><strong><em>Build a distributed system and not a distributed monolith</em></strong>:</p><ul><li>Don’t hold yourselves back in re-evaluating the architecture when more features get added in due course of time</li><li>Ask questions like “are there too many services”? “Can few of the services be combined”? etc. Make sure you don’t overapply the microservices pattern</li><li>The design should be done for building a distributed system and <strong>not a distributed monolith.</strong></li></ul><p><strong><em>Decide the Availability of the system</em></strong>:</p><ul><li>Is <a href="#2b95">99 / 98</a> fine to start with or we need <a href="#2b95">99.99 / 99.999</a> at the first go?</li><li>This is important because the latter is difficult to achieve in case of of microservices compared to the former</li></ul><p><strong><em>If load increases, how much does Scalability cost:</em></strong></p><ul><li>Is the load expected to increase by 20x or 50x or 100x in a very short span of time or will it follow a gradual increase?</li><li>The latter will give us time to start small &amp; eventually modularise</li></ul><p>There is a fine balance between a monolith and microservices. The engineers have to make wise and bold decisions to build an optimal system - a system which can undergo changes at a low cost. The word <strong>system </strong>needs to be stressed because we are making the required decisions to build a <strong>system </strong>and not a single service. A bunch of optimal services integrated together is not guaranteed to product an optimal <strong>system.</strong></p><p>We talk about standards to be followed and agreements to be reached during development of services. This practice should be extended when making the architectural decision too. Going the microservice highway without standardization &amp; agreement over the protocols &amp; communication models will only end up handling the mess later.</p><p>We also have a commitment to reduce our carbon footprint and leave a greener environment. Decisions like these contribute a lot towards it.</p><p>When the complexity of the microservices approach proves to not deliver the value or goals it intended and on the contrary, it starts working against those goals, teams shouldn’t hesitate to revert back to monoliths / lesser number of services. There is no right or wrong choice -every pattern has benefits &amp; problems and trade-offs can’t be ignored when we pick one.</p><p>I hope my 2 cents are useful to some of you reading this!!</p><p>Have a good day :-)</p><p><strong><em>References</em>:</strong></p><p>[1] <a href="https://twitter.com/GergelyOrosz/status/1247132806041546754">https://twitter.com/GergelyOrosz/status/1247132806041546754</a></p><p>[2] <a href="https://changelog.com/posts/monoliths-are-the-future">https://changelog.com/posts/monoliths-are-the-future</a></p><p>[3] <a href="https://www.theregister.co.uk/2020/03/04/microservices_last_resort/">https://www.theregister.co.uk/2020/03/04/microservices_last_resort/</a></p><p>[4] <a href="https://landing.google.com/sre/sre-book/chapters/availability-table/">https://landing.google.com/sre/sre-book/chapters/availability-table/</a></p><p><strong><em>Credits</em></strong>:</p><p>[1] Title Photo: Photo by <a href="https://www.pexels.com/@magda-ehlers-pexels?utm_content=attributionCopyText&amp;utm_medium=referral&amp;utm_source=pexels">Magda Ehlers</a> from <a href="https://www.pexels.com/photo/orange-cube-1340185/?utm_content=attributionCopyText&amp;utm_medium=referral&amp;utm_source=pexels">Pexels</a></p><p>[2] Thanks to my colleagues &amp; friends for their reviews &amp; suggestions.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=694fe4613e43" width="1" height="1" alt=""><hr><p><a href="https://medium.com/null-pointer/monolith-vs-microservices-the-quintessential-dilemma-694fe4613e43">Monolith vs Microservices: The Quintessential Dilemma</a> was originally published in <a href="https://medium.com/null-pointer">Null-Pointer</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>