DEV Community

Cover image for Modern clean architecture
Bertil Muth
Bertil Muth

Posted on • Edited on

1 1

Modern clean architecture

I am pleased to announce the release of the modern-clean-architecture project.

Clean architecture follows these principles:

  • The domain code and use cases of an application are independent of frameworks, UI, the database or any external agency, e.g. external services.
  • Through this clear separation of concern, the domain code and use cases become testable independent of the framework, UI or infrastructure.
  • The user interface, database technology, external services and framework specific code can change without affecting the domain code and vice versa.

Modern clean architecture provides a fresh view on clean architecture, in a Spring Boot environment. It reduces the effort required to create a clean architecture through the following constraints:

  • Serialization of immutable requests and responses without serialization specific annotations.
  • No necessity for DTOs. You can use the same immutable value objects for requests/responses in web layer and use cases.
  • Generic endpoint that receives and forwards POST requests. New behavior and domain logic can be added and used without the need to write framework specific code.
  • Testing with a repository double that acts like a normal repository. No need for mocking it.

Visit the website, I'm happy to hear your thoughts.

Heroku

Build apps, not infrastructure.

Dealing with servers, hardware, and infrastructure can take up your valuable time. Discover the benefits of Heroku, the PaaS of choice for developers since 2007.

Visit Site

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay