Skip to content

Sponsor: Do you build complex software systems? See how NServiceBus makes it easier to design, build, and manage software systems that use message queues to achieve loose coupling. Get started for free.

Learn more about Software Architecture & Design.
Join thousands of developers getting weekly updates to increase your understanding of software architecture and design concepts.


Follow @CodeOpinion

The pendulum swings! Microservices to Monoliths

We moved from monoliths to microservices a decade ago, and there has been a swing back to either consolidating microservices or moving to a modular monolith. This isn’t surprising. Why is this happening? I will explain why logical boundaries don’t have to be physical. Once we finally make this distinction, it opens up many possibilities. YouTube Check out my YouTube channel, where I post all kinds of content accompanying my posts, including this video showing everything in this post. Physical Boundaries One of the good things that came from microservices is defining boundaries. Good fences make good neighbors, as the saying goes.… Read More »The pendulum swings! Microservices to Monoliths

Aggregate (DDD) isn’t hierarchy & relationships

How do you design an aggregate in domain-driven design? An aggregate in a cluster of related objects and used to manage the complexity of business rules and data consistency. Designing aggregates often incorrectly because of the focus on the relationship between entities. YouTube Check out my YouTube channel, where I post all kinds of content accompanying my posts, including this video showing everything in this post. Relationships I believe most developers designing aggregates are thinking about data, hierarchy & relationships. As an example, here’s an aggregate diagramed by its relationships. It has an entity that is the Aggregate Root which any consuming… Read More »Aggregate (DDD) isn’t hierarchy & relationships

Using your Database as a Queue?

Do you need a message broker, or can you use your database as a queue? Well, as in most cases, it depends. Let me explain how it’s possible and some trade-offs and things to consider, such as volume, processing failures, and more. YouTube Check out my YouTube channel, where I post all kinds of content accompanying my posts, including this video showing everything in this post. Database as a Queue There was a blog post about ditching RabbitMQ for Postgres as a queue. TLDR: They claimed they had issues with prefetching with RabbitMQ and it was causing issues because they have long-running… Read More »Using your Database as a Queue?