How dorian-frances/df-java-template works
Main Components
a) Core Components:
• Domain Layer (Central Hexagon)
• Application Layer (Primary/Driving Adapters)
• Infrastructure Layer (Secondary/Driven Adapters)
• Bootstrap Layer (Application Configuration)
b) Technical Components:
• REST API Interface
• PostgreSQL Database
• Spring Boot Framework
• Liquibase Migration System
[External Layer]
• REST API Adapter (Primary)
• PostgreSQL Adapter (Secondary)
[Domain Layer (Core Hexagon)]
• User Service
• Domain Models
• Port Interfaces
[Infrastructure Layer]
• Database Configuration
• Entity Mappings
• Repositories
[Bootstrap Layer]
• Application Configuration
• Dependency Injection
Key Relationships to Highlight
a) Port Interfaces:
b) Data Flow:
• REST API requests flow through controllers to domain services
• Database interactions from domain through storage ports
Specific Implementation Details
• UserController → UserFacade → UserService → UserStoragePort → PostgresUserAdapter
• Error handling flow through DfExceptionMapper
• Liquibase migration connection to PostgreSQL
• Spring Boot's configuration management
Additional Elements
Supporting components:
• Test containers for integration testing
• CircleCI pipeline connection
• Contract-first API generation flow
• Error handling pathways
How the bootstrap module orchestrates all components
Remember to maintain a balance between detail and clarity, focusing on the architectural decisions while avoiding implementation-specific details that don't contribute to understanding the system's structure.
• How the application implements hexagonal architecture
• The flow of data through the system
• Where to add new features or adapters
• How testing fits into the architecture
• The role of each technical component