Skip to main content
added 307 characters in body
Source Link
candied_orange
  • 119.7k
  • 27
  • 233
  • 369

Another issue is getting your modules to be the right size. I found some good advice on that here. Yes, making things as small as you can makes them simple. But that just pushes the complexity out somewhere else. Find balance.

Another issue is getting your modules to be the right size. I found some good advice on that here. Yes, making things as small as you can makes them simple. But that just pushes the complexity out somewhere else. Find balance.

added 11 characters in body
Source Link
candied_orange
  • 119.7k
  • 27
  • 233
  • 369

The danger of a modular monolith is it allows unwanted coupling between the modules. Since you have a requirement that forces you to decouple them that danger goes poof. You don't need the architecture to force this on you when the requirements do. Rather, you need an architecture that enables this decoupling.

The danger of a modular monolith is it allows unwanted coupling between the modules. Since you have a requirement that forces you to decouple them that danger goes poof. You don't need the architecture to force this on you when the requirements do. Rather, you need an architecture that enables this.

The danger of a modular monolith is it allows unwanted coupling between the modules. Since you have a requirement that forces you to decouple them that danger goes poof. You don't need the architecture to force this on you when the requirements do. Rather, you need an architecture that enables this decoupling.

Source Link
candied_orange
  • 119.7k
  • 27
  • 233
  • 369

The client was very much inspired from microservices so I had to convince him to go for a monolith which then can later be migrated to a microservices. besides to me microservices for a 3-dev team is a joke.

There are definitely those who agree with you:

Microservices are not neccesarily required to manage huge software, but rather to manage a huge number of people working on them.

The horror of microservices in small teams - medium.com

Microservices solve a few problems

  • allow large teams to break up work and have separate release cycles.

  • scale. You can scale out different services independently.

  • tackle a few large data problems more efficiently

If you don’t have these issues then the added cost of microseconds are not worth it.

You want a modular monolith

Are microservices worth it, when you have A SINGLE TEAM of 4 devs - redit.com

Conversely,

They want a system in which modules can be subscribed to, independent of each other.

This means you have to maintain a hard isolation of these modules regardless of microservices.

Which means you're part way to microservices anyway.

Is this too much for a modular monolith system?

The danger of a modular monolith is it allows unwanted coupling between the modules. Since you have a requirement that forces you to decouple them that danger goes poof. You don't need the architecture to force this on you when the requirements do. Rather, you need an architecture that enables this.

It may be worth analyzing how far you've been pushed towards microservices already.

Here are some microservice best practices. I'll contrast them with your modular monolith:

  1. Follow the Single-Responsibility Principle (SRP)‍

Still good advice in a modular monolith.

  1. Do Not Share Databases Between Services

You're already doing this.

  1. Clearly Define Data Transfer Object (DTO) Usage

Still good advice in a modular monolith.

  1. Use centralized observability tools‍

Still good advice in a modular monolith.

  1. Carefully consider your authorization options

May not be needed yet.

  1. Use an API gateway for HTTP

Still good advice in a modular monolith.

  1. Use the Right Communication Protocol Between Services

Still good advice in a modular monolith.

  1. Adopt a consistent authentication strategy

Still good advice in a modular monolith.

  1. Use containers and a container orchestration framework

May not be needed yet.

  1. Run health checks on your services‍

Still good advice in a modular monolith.

  1. Maintain consistent practices across your microservices

Still good advice in a modular monolith.

  1. Apply Resiliency and Reliability Patterns

Still good advice in a modular monolith.

  1. Ensure Idempotency of Microservices Operations

Still good advice in a modular monolith.

Evolving microservices - microservices.io

There are other things that go with microservices, like giving each service it's own pipeline, you can likely not bother with yet. But making your modules independently deployable has benefits even on a 3 person team.