How absievil/hcmut_ssps works
Main Components
• Frontend: This is the React application (found under “frontend-react”). It includes UI components, state management (store), routing (including login, register, dashboard, payment pages, etc.), and styling layers.
• Backend: The Spring Boot application (under “backend-springboot”) which contains controllers (RESTful endpoints for Admin, Student, Utilities, etc.), data transfer objects (DTOs), models, services (including email, payment, and utilities), security classes (JWT, OAuth2, etc.), and database configuration files.
• Database: The PostgreSQL database (as indicated in the README and supported by SQL scripts inside the backend’s resources folder).
• External Services: Payment integration via VNPAY configuration, and email services.
Understand the Interactions and Relationships
• The Backend orchestrates operations such as user authentication, payment processing, and data management. It makes use of various layers (e.g., Controllers → Services → Repositories → Database) which should be explicitly represented.
• Security: Include components such as JwtAuthenticationFilter, CustomUserDetailsService, and OAuth2LoginSuccessHandler, which mediate authentication and authorization.
Architectural Patterns and Design Principles
• MVC (Model-View-Controller): The backend clearly separates concerns between Controllers, Services, and Models.
• RESTful API Design: Display REST endpoints and the pattern of requests/responses.
• Layered Architecture: Frontend → API Gateway → Business Logic (Backend Services) → Data Access.
• Security: JWT-based authentication, OAuth2 integration, and role management using “Role” and “User” models.