From Concept to Code: Implementing Hexagonal Architecture with Confidence
summary
Claims a practical recipe to make hexagonal/ports-and-adapters real in Java: use Lombok + MapStruct + vavr (Either) for always‑valid models and error values instead of exceptions, register handlers via Spring DI and custom, technology‑agnostic annotations, and wire a command/query bus plus transactional interceptor so core use cases stay framework‑free. Demonstrates a working reference app (create/get article) with an in‑memory repo, shows 201 on POST and a successful GET, and uses ArcUnit architectural checks to prevent accidental layer coupling.
AI-written summary · about
chapters (17)
- 0:00Introduction and welcome
- 3:40Modern software architect role
- 7:18Problems with layered architectures
- 13:22Clean architecture overview
- 16:56Hexagonal architecture explained
- 21:10Common pitfalls and solutions
- 22:34Design decisions for hexagonal architecture
- 30:02Always valid model principle
- 33:33Error values over exceptions
- 38:54Either monad and CQRS
- 42:05DTOs and domain model separation
- 44:56Rich domain model and DDD
- 47:04Technology agnostic annotations
- 50:12Dependency injection and assembly
- 52:18Testing and architecture validation
- 54:03Code execution and demo
- 1:05:46Q&A session
