How xtoon/xtoon-boot-ddd works
Project type and purpose
• xtoon-boot is a Java/Spring Boot monolith scaffolding for SaaS platforms, built on Domain-Driven Design (DDD) and Hexagonal (Ports & Adapters) architecture.
• It provides turnkey modules—login/registration, user/role/menu/tenant management, logs, multi-tenancy—so teams can focus on business logic rather than boilerplate.
File structure
• Top-level modules:
• db (SQL scripts)
• xtoon-common (cross-cutting domain classes, utilities, configuration)
• xtoon-api (REST controllers, web layer, Swagger UI)
• xtoon-sys (system-management subdomain)
• xtoon-org (organization-management subdomain)
• Each subdomain module (xtoon-sys, xtoon-org) follows the DDD layering:
• application (DTOs, commands, services, assemblers)
• domain (entities, value objects, specifications, domain services, external interfaces)
• infrastructure (persistence adapters, external service implementations)
• xtoon-api depends on xtoon-common and both subdomains; xtoon-common holds shared code (MyBatis config, Redis config, utility classes).
README for architectural guidance
• Embraces Hexagonal (Ports & Adapters): core logic is isolated from frameworks and infrastructure.
• Four layers: Presentation/API, Application, Domain, Infrastructure.
• Uses Spring Boot for wiring, Apache Shiro for security, MyBatis-Plus + Alibaba Druid for persistence, Redis for caching, Swagger for API docs.