Contact Us
Contact Us
Cloud Architecture

Monolith to Microservices: When It Pays Off and When It Backfires

When splitting a monolith earns its overhead, the warning signs that it won't, and how a modular monolith gets you most of the benefit first.

JRC Software Team
6 min read
Monolith to Microservices: When It Pays Off and When It Backfires

A change to the invoice PDF breaks the monthly sales report. Nobody can explain why until someone finds a shared utils class that both modules import. Releases now need a two-hour regression run, and the newest developer is six weeks in and still nervous about merging.

At this point someone usually proposes going from monolith to microservices. It sounds like what the big tech companies do, and the pain is real, so the idea picks up speed.

Sometimes that's the right move. Often it isn't, or isn't yet. A badly timed split leaves you with the same tangled logic, now spread across a network, plus new bills for orchestration, tracing and on-call. What follows is how we judge when a split earns its cost, the signs it'll backfire, and the option most teams should try first.

Two kinds of complexity

Microservices are a mainstream style now, documented by every major cloud provider. Microsoft's Azure Architecture Center describes them as a collection of small, autonomous services, each implementing a single business capability within a bounded context, deployed independently and owning its own data.

The benefits on that page are genuine: independent deployment, small focused teams, fault isolation and scaling parts of the system separately. The same page doesn't hide the costs. There are more moving parts, testing across service dependencies is hard, data consistency becomes a design problem, and success needs a mature DevOps culture plus people who've run distributed systems before.

So you're not removing complexity. You're moving it from inside one codebase to the gaps between many. That's the whole decision.

Fowler's "premium", a decade on

Martin Fowler gave this trade-off a name in May 2015: the microservice premium. Distributed systems need extra work on automated deployment, monitoring, failure handling and eventual consistency, and that overhead slows a team down. His advice was not to consider microservices unless the system is too complex to manage as a monolith.

A few weeks later, in Monolith First, he noted that almost all successful microservice stories started with a monolith that grew too big and was broken up, while systems built as microservices from scratch often ran into serious trouble. Service boundaries are hard to get right at the start, and moving functionality between services is much harder than moving it between modules.

That's an argument about timing, not a verdict against microservices. It has aged well.

Monolith to microservices: when it pays off

In our experience a split earns its premium when several of these are true together, not just one:

  1. Teams are queuing on one release train. Three or more teams regularly waiting on each other to deploy means independent deployability has a real dollar value.
  2. Parts of the system scale very differently. A spiky ingestion job or search workload that forces you to scale the whole app is a classic first extraction.
  3. The boundaries are stable. You can name the business capabilities, and they haven't changed shape much in the past year.
  4. Different parts need different controls. Isolating card payments or sensitive personal data can shrink the scope of a PCI DSS or privacy audit.
  5. The platform basics already exist. Automated pipelines, infrastructure as code, centralised logging with correlation IDs, distributed tracing and an on-call rota are in place, or a platform team is building them (see platform engineering vs DevOps).

How it backfires

The failure modes are predictable enough to put in a table.

Warning signWhat tends to happen
Small team (one or two squads)Operational overhead eats the capacity that was meant for features
Fuzzy domain boundariesServices get chatty and tightly coupled: a distributed monolith
Shared database kept "for now"Schema changes still need coordinated releases, so independence is gone
No automated tests or deploymentEvery release turns into a multi-service coordination exercise
Weak observabilityIncidents take longer to diagnose because one request crosses six services
"Modernisation" is the only reasonCost and complexity go up with no measurable business benefit

Microsoft lists several of these as antipatterns, including sharing common libraries between services and building services without a deep understanding of the business domain. Its best practices also warn that overly granular services add complexity and hurt performance. A symptom we look for: a single user request that triggers a synchronous chain of calls (A calls B calls C), where one slow service drags the whole page down.

The modular monolith: get most of the benefit first

A modular monolith is one deployable application whose internals are split into modules with enforced boundaries. Each module owns its domain logic and its data, and other modules call it through an explicit interface instead of querying its tables.

Shopify's engineering team wrote up this choice in February 2019 for a Rails codebase that more than a thousand developers had worked on over more than a decade. They weighed microservices and saw separate pipelines per service, extra infrastructure, network latency and painful cross-service refactors. They went for more modularity without more deployment units.

For most growing businesses that's the sweet spot. Clearer ownership, safer changes and faster onboarding, at a fraction of the operational cost. It also keeps the door open: Fowler describes designing a monolith carefully with modularity in mind as the logical way to go monolith-first, because well-separated modules are far easier to extract later.

The sequence we follow

  1. Map the domain. List the business capabilities and the data each one owns.
  2. Enforce boundaries in code. Package visibility, dependency rules or architecture tests (ArchUnit on the JVM, Packwerk on Rails, NetArchTest in .NET) so one module can't reach into another.
  3. Split data ownership. Give each module its own schema or tables and stop cross-module joins.
  4. Measure the pain. Track deployment frequency, lead time and change failure rate per area.
  5. Extract only where the numbers say so. Peel off the module with the cleanest boundary and the strongest scaling or team case, using the strangler fig approach so old and new run side by side.

If the monolith is also a legacy system, our rehost, replatform or rebuild decision guide helps decide what to do with it first.

How JRC Software helps

We start with an architecture review, not a target diagram. In the first week our engineers read the codebase and its dependency graph, look at the pipeline and how long a release really takes, go through recent incidents, and talk to the team leads about where changes collide. We want to see where coupling actually hurts delivery, not where it looks untidy.

You get a written recommendation with one of three answers: leave it alone, modularise in place, or extract specific services. Each comes with the order of work and the platform changes it needs. We'll tell you plainly if we think a split isn't worth it, and we'll usually tell you not to extract anything until module boundaries are enforced and the shared database is untangled.

When extraction does make sense, we build the foundations first (infrastructure as code, pipelines, tracing) and move one capability at a time while keeping the system releasable. Both paths sit within our cloud engineering and modernisation service.

Weighing a split and want a second opinion before committing? Get an architecture review and we'll tell you whether microservices will pay off for your system, and what to do instead if they won't.

Frequently asked questions

What is a modular monolith?

A modular monolith is a single deployable application whose code is divided into modules with strict boundaries. Each module owns its business logic and data, and others reach it only through defined interfaces. You get many of the organisational benefits of microservices, such as clear ownership and safer changes, without the network, deployment and observability overhead of running many services.

How do I know if my team is ready for microservices?

Your team is ready when the foundations already exist and independent deployment would solve a real coordination problem. That means automated pipelines, infrastructure as code, centralised logging and tracing, reliable automated tests and an on-call practice, plus stable domain boundaries and several teams. If a few of those are missing, build them first.

Can we move from monolith to microservices gradually?

Yes, and you should. The strangler fig approach builds new services alongside the existing system and routes behaviour to them one capability at a time, so old and new run side by side. The business keeps running, value shows up early, and you can stop once the benefit levels off instead of committing to a full rewrite.

What is a distributed monolith?

A distributed monolith is a set of separate services that still have to change and deploy together, usually because they share a database, share libraries or call each other synchronously on every request. You pay the operational cost of microservices without getting the independence. It's the most common way a microservices migration goes wrong.

Cloud Architecture

Get an architecture review

Tell us where you're stuck and we'll come back with practical next steps.

Get in touch

Sources