2 MINARCHITECTURE, SERVERLESS, CLOUD

Monolith before microservices

Verdict

One deployable app keeps calls fast, data consistent and changes simple, and clean modules let you split it later.

When I'd pick the other one

Work that runs apart from user requests, like batch jobs and async notifications, heavy compute such as 3D modeling, or separate teams that ship on different schedules.

A monolith is one application, deployed as one unit. Microservices split it into small services that deploy separately and talk over the network.

Microservices mostly solve an org problem. Separate teams can change their own piece without waiting on each other, and one busy part can scale without the rest. That’s real, if your org is big enough to have that problem.

The catch is that a function call becomes a network request that can time out, retry or arrive twice, and data that lived in one database is spread across several that can disagree.

In practice, this usually turns into serverless sprawl. Each endpoint becomes its own function, wired to the next through the provider’s own event services. Soon there are dozens of small deployables, each with its own permissions, configuration and logs, and the glue between them only exists on that one cloud. What used to be a function call now hops between functions, picking up a cold start or a network round trip at each step, so the app gets slower and harder to change.

To be clear, serverless hosting is fine. One well-structured app in a container, on a platform like Cloud Run, still scales to zero and moves between clouds as it is. What hurts is splitting the app up too early.

So I start with a monolith, built as clear modules with clean boundaries. The parts worth splitting out early are the ones that already run apart from user requests: batch jobs, async notifications, heavy compute like 3D modeling. They scale separately anyway, and they can sit behind a queue from day one. Anything else gets lifted out when it needs its own team or its own scaling, and by then you know where the boundary really is.

One app
AccountsOrdersBillingSearch
Modules call each other directly, in one process.
Queue Work handed off, not waited on
Separate services Batch jobsNotifications3D rendering

Tyler SandersEngineer, Computer Scientist, Tech Enthusiast