One of the best parts of speaking at or attending tech conferences is the opportunity to have meaningful conversations with fellow developers and speakers.
While attending the
@spring_io 2026 conference in Barcelona, I had the pleasure of speaking with
@odrotbohm over breakfast.
We discussed Spring Boot, Spring Modulith, Hexagonal Architecture, and the trade-offs between different approaches to organizing code.
During our discussion on code organization, Oliver shared a fantastic analogy.
Modularity, he explained, helps us organize code in much the same way we organize spaces in a house.
A house may have a living room, bedroom, children’s room, kitchen, and so on. Each room can be maintained differently depending on its purpose. Not every room is equally clean or equally messy at all times. Children’s rooms are often less organized. The living room is usually kept tidy because it is the space visitors see first. The kitchen is especially important, so we make an effort to keep it clean and hygienic.
The same principle applies to software modules.
Different modules in a system may have different levels of maturity. Some modules have stable requirements and a well-established structure. Others may still be exploratory, where imposing a strict design upfront may not be practical or even necessary. Some teams may prefer a Hexagonal Architecture style, while others may choose a simpler, flatter code organization.
One of the strengths of a modular monolith is that each module can evolve using the approach best suited to the team and the problem domain, without negatively affecting other modules or teams. If one module becomes messy, that complexity remains contained. At the same time, teams can experiment with approaches such as Hexagonal Architecture and evaluate whether they work better than the alternatives.
The analogy of a house with rooms maintained at different levels of cleanliness resonated strongly with me.
While we may not ultimately want every module to follow a completely different architectural style, a modular monolith gives teams the flexibility to experiment and evolve independently without disrupting the rest of the system.
Thank you Oliver for sharing your thoughts and it was wonderful meeting you in-person.
One of the best parts of attending conferences is the hallway conversations.
#Java #SpringBoot #SpringModulith #SoftwareArchitecture #SpringIO