How valarchie/agileboot-back-end works
Main Components
• AgileBoot-Admin – This module provides the backend management interface (admin API) for system operations such as user, department, and role management.
• AgileBoot-API – This module exposes public APIs (open interfaces) to clients (e.g., mobile or external services).
• AgileBoot-Domain – The heart of the business logic. It is organized using CQRS and DDD concepts, separating command (update operations) and query (read operations) flows. It encapsulates the core domain models, factories, commands, queries, and application services.
• AgileBoot-Common – Contains common utilities, core base classes, exception handling, and constants shared across modules.
• AgileBoot-Infrastructure – Focuses on system configuration and integration concerns (security, caching, exception handling, thread management, logging, MyBatis integration, etc.).
External Systems and Dependencies
• Database (MySQL) – the primary persistent storage backend.
• Redis – used for caching (with multi-tier caching strategies: Map, Guava, and Redis) and distributed session management via JWT.
• Additional components such as H2 (for testing/embedded mode), external authentication systems, and even containerized deployment (docker references).
Out Relationships and Data Flow
• Frontend Client (separate Vue3 project) communicates with the AgileBoot-Admin and AgileBoot-API modules (likely via REST APIs secured with JWT).
• Within the admin module, incoming HTTP requests (from the admin portal) pass through controllers. They then flow into the application service layer (residing mostly in the agileboot-domain module) to separate query and command paths:
– Query flows: Controller → Query DTO/Model → Application Service → Domain Service → Mapper (DB access)
– Command flows: Controller → Command DTO/Model → Application Service → Domain Model (business logic) → Persistence (save/update via MyBatis/JPA)
• AgileBoot-Common provides base classes and shared utilities (error codes, common exceptions, and DTOs) used across the other modules.
• AgileBoot-Infrastructure connects with external dependencies (configurations for Redis, MySQL, security filters such as JwtAuthenticationTokenFilter, rate limiting aspects, caching aspects, etc.) and even supports integration tests and embedded database modes.
Architectural Patterns and Design Principles
• CQRS: Clearly distinguish between query and command operations as explained in the README.
• Domain-Driven Design: The Domain layer uses domain models, factories, and application services that encapsulate business logic.
• Layered Architecture: Different modules are organized by concerns – presentation (controllers), application (service layers), domain (business logic), and infrastructure (configuration/integration).
• Separation of Concerns: Each module (admin, API, common, domain, infrastructure) is responsible for a clear-cut part of the business workflow.