Let’s be honest.

Some development teams hear that an application is built as a monolith and immediately start planning a migration to microservices. The reasoning usually sounds something like this:

“Our application is becoming difficult to maintain. Let’s split it into microservices.”

And suddenly, a team that previously maintained one application is now responsible for 15 services, 15 deployment pipelines, multiple databases, distributed transactions, message brokers, monitoring infrastructure, and a few additional meetings.

Congratulations! You have successfully distributed your technical debt. 😄

But is that really what your application needed? Microservices are not automatically an upgrade over a monolith. They are an architectural style that solves particular problems while introducing new complexities.

The real question is not whether microservices are better than monoliths.

The question is: Which architecture best fits your business requirements, team structure, and operational capabilities?

1. Understanding the difference

Let’s start with a simplified e-commerce application. Imagine we have the following business capabilities:

  • Customer Management
  • Product Catalog
  • Order Management
  • Payment Processing
  • Inventory Management
  • Notifications

In a traditional monolithic application, these capabilities can exist within a single deployable application.

              E-Commerce Application
                       |
       +---------------+---------------+
       |               |               |
   Customers         Products        Orders
       |               |               |
       +---------------+---------------+
                       |
             Payment & Inventory
                       |
                  Database

Everything is deployed together. This is not necessarily bad.

A well-designed monolith can have clearly separated business modules, maintainable code, good test coverage, and excellent performance. Now consider a microservices architecture.

                 API Gateway
                      |
        +-------------+-------------+
        |             |             |
   Customer       Product         Order
   Service        Service         Service
        |             |             |
    Customer DB    Product DB     Order DB
                                    |
                           +--------+--------+
                           |                 |
                     Payment Service   Inventory Service
                           |                 |
                       Payment DB       Inventory DB

Each service has its own responsibility, deployment lifecycle, and ideally ownership of its data. Services communicate through APIs or messaging infrastructure. This provides independence, but it also introduces distributed system challenges.

2. When a monolith is actually the better architecture

A monolith can be an excellent choice when:

Your domain is still evolving.

When business requirements are changing frequently, identifying the correct service boundaries can be difficult. Splitting an immature domain into multiple services can create unnecessary dependencies.

Your team is relatively small.

A small team may not need the operational overhead of managing multiple independently deployed services.

Your application has strong transactional requirements.

A monolithic application with a relational database can make certain transactional workflows considerably simpler.

Your deployment requirements are straightforward.

If the entire application can be deployed together without affecting independent business capabilities, separate deployments may not provide meaningful value. For example, an internal employee management application with a small development team may work perfectly well as a modular monolith.

There is no architectural award for having the highest number of microservices.

3. The modular monolith: An architecture worth considering

One architecture I particularly like for many enterprise applications is the modular monolith. Instead of splitting the application into independently deployed services, we establish clear business boundaries inside one deployable application.

For example:

              E-Commerce Platform
                       |
              ASP.NET Core API
                       |
       +---------------+---------------+
       |               |               |
   Customer         Catalog           Order
   Module           Module            Module
       |               |               |
   Customer DB     Catalog DB       Order DB
                       |
              Shared Infrastructure
                       |
              Logging / Messaging

The important part is not the folder structure. It is enforcing module boundaries.

For example:

  • The Order module should not directly modify the internal data structures of the Payment module.
  • The Customer module should expose explicit contracts.
  • Business rules should remain within their owning modules.
  • Cross-module communication should happen through well-defined interfaces or events.

A practical .NET solution might look like this:

ECommerce.sln
|
+-- ECommerce.Api
|
+-- Modules
|   |
|   +-- Customers
|   |   +-- Domain
|   |   +-- Application
|   |   +-- Infrastructure
|   |
|   +-- Orders
|   |   +-- Domain
|   |   +-- Application
|   |   +-- Infrastructure
|   |
|   +-- Payments
|       +-- Domain
|       +-- Application
|       +-- Infrastructure
|
+-- BuildingBlocks

This gives us a clear separation of responsibilities without introducing unnecessary network communication.

As the business grows, selected modules can become independent services when there is a genuine architectural reason. One important consideration: a modular monolith should enforce boundaries deliberately. Simply creating separate folders or projects does not guarantee modularity.

4. When microservices make sense

Microservices become valuable when independent business capabilities need independent evolution. Consider an e-commerce platform processing millions of orders.

The Payment Service may require:

  • Independent scaling.
  • Stronger security boundaries.
  • Separate deployment schedules.
  • Dedicated engineering ownership.
  • Independent availability and recovery strategies.

Meanwhile, the Notification Service may have very different scaling and processing requirements. In this scenario, independent services can provide meaningful benefits.

Some common indicators include:

Independent scaling

One business capability experiences significantly higher workloads than others.

Independent deployment

Teams need to release functionality without coordinating deployments across the entire application.

Different technology or operational requirements

Certain workloads need specialized infrastructure, processing models, or security boundaries.

Organizational independence

Different teams own distinct business capabilities and can operate them independently. However, these benefits only materialize when the organization has the engineering maturity to support them.

5. The hidden cost of microservices

Microservices introduce complexity that is often underestimated during architecture planning.

Let’s look at some examples.

ConcernMonolithMicroservices
DeploymentUsually one deployable unitMultiple independent deployments
CommunicationMostly in-processNetwork-based and messaging
TransactionsOften simplerDistributed consistency challenges
DebuggingUsually easierRequires distributed tracing
ScalingOften application-levelCan scale individual services
Data ownershipCan share one databaseIdeally independent ownership
OperationsComparatively simplerMore infrastructure and monitoring

Microservices also require attention to:

  • Service discovery and routing.
  • API versioning and contract compatibility.
  • Network timeouts and retries.
  • Message duplication and ordering.
  • Distributed tracing.
  • Secrets and identity management.
  • Deployment orchestration.
  • Service-level objectives and incident response.

If your organization is not prepared to manage these concerns, microservices may make delivery slower rather than faster.

6. A practical .NET and Azure architecture

Let’s imagine that our e-commerce platform has grown significantly. We decide to keep Customer and Catalog capabilities within a modular application while extracting Payment and Order Processing into independent services.

A possible architecture:

                    Azure API Management
                             |
                     ASP.NET Core API
                             |
                   Modular Core Application
                     /              \
                Customer           Catalog
                             |
                        Order API
                             |
                      Azure Service Bus
                        /          \
                       /            \
                Payment Service   Inventory Service
                       |                |
                   Azure SQL        Azure SQL
                       |
                 Payment Events
                       |
                 Order Processing
                       |
              Azure Application Insights

Technology choices could include:

  • ASP.NET Core for application APIs.
  • Entity Framework Core for persistence.
  • Azure Service Bus for asynchronous communication.
  • Azure SQL for relational data.
  • Azure API Management for API governance.
  • Azure Application Insights and OpenTelemetry for observability.
  • Azure Container Apps or Azure App Service for deployment, depending on workload and operational requirements.

The architecture should evolve based on workload, business boundaries, reliability requirements, and operational capabilities. We should not introduce Kubernetes simply because we have five services. Sometimes Azure Container Apps or App Service is a better operational choice.

7. My approach as an architect

When evaluating whether to introduce microservices, I prefer to ask these questions first:

  1. What business problem are we trying to solve?
  2. Are our current module boundaries clear?
  3. Do different business capabilities have different scaling requirements?
  4. Do teams need independent deployment capabilities?
  5. Can we manage distributed failures and observability?
  6. Do we have appropriate DevOps and operational maturity?
  7. What additional complexity will this architecture introduce?

I also consider the cost of operating the architecture over several years, not just the cost of implementing it initially. An architecture that looks impressive during a technical presentation but becomes difficult to operate is not a successful architecture.

8. The takeaway

I don’t believe monoliths are outdated, and I don’t believe microservices are the destination for every enterprise application. A well-structured monolith can be more maintainable than a poorly designed microservices architecture. A modular monolith can provide an excellent starting point for growing applications.

Microservices can become the right choice when independent business capabilities, scaling requirements, deployment needs, and organizational boundaries justify the additional complexity.

Start with good boundaries. Introduce distribution when the business and engineering requirements justify it.

And please, don’t turn one application into 30 services just to make your architecture diagram look more exciting. Your operations team has enough reasons to lose sleep already. 😄

Let’s discuss

What would you choose when starting a new enterprise application today?

  1. Traditional monolith.
  2. Modular monolith.
  3. Microservices.
  4. A hybrid architecture.

And more importantly, what business or technical requirement would influence your decision?

I’d love to hear your experiences from real-world projects.