How sayho93/nest-boilerplate works
Main Application Components
a) Core Application Layer:
• Auth Module
• Users Module
• Credits Module
• Projects Module
• Request Module
• Mail Module
b) Infrastructure Layer:
• Database (MariaDB) - indicated by the presence of TypeORM config and migrations
• Redis Cache - shown in the cache module and configuration
• Queue System - evidenced by the queue module
• Mail Service - shown by the mail module
External Services Integration
• Google OAuth (visible in auth strategies)
• JWT Authentication Service
Cross-Cutting Concerns
As horizontal layers:
• AOP (Aspect-Oriented Programming) Module
• Logger Module
• Cache Layer
• Transaction Management
• Event System
Specific Design Elements
Use the following representation guidelines:
a) Database Entities (show as connected tables):
• User Entity
• Auth Entity
• Credit Entity
• Project Entity
• Request Entity
• Local Auth Strategy
• JWT Strategy
• Google Strategy
• Refresh Token Flow
c) Request Processing Pipeline (show as a flow):
• Request ID Interceptor
• Request Log Interceptor
• Global Exception Filter
• AsyncLocalStorage Middleware
Important Relationships to Highlight
Key interactions:
• User ←→ Auth relationships
• Credit ←→ User relationships
• Project ←→ User relationships
• Queue processing flows
• Cache interaction patterns
• Transaction boundaries
Additional Elements
Supporting components:
• Configuration Management
• Migration System
• Seeding System
• Docker Container Boundary
• Nginx Reverse Proxy
Technical Details
Annotations for:
• TypeORM as the ORM layer
• Redis for caching and queue
• MariaDB as the primary database
• JWT for token management
• Bull for queue processing
For the actual drawing: