A comprehensive task management system built with Spring Boot that provides functionality for managing tasks, users, departments, and notifications in an organizational setting.
- User Management: Support for Employees, Managers, and Admins with role-based access control
- Department Management: Organize employees into departments with manager assignments
- Task Assignment: Managers can assign tasks to employees with status tracking
- Email Notifications: Automated email notifications for task assignments and updates
- JWT Authentication: Secure authentication with JWT tokens
- Scheduled Notifications: Daily and weekly notification system for task reminders
- Caching: Redis-based caching for improved performance
- Database Migration: Flyway for database schema versioning
- Message Queue: Asynchronous processing of task updates, notifications, and OTP using RabbitMQ for reliable and scalable communication between services
- Spring Boot 3.5.4 - Main application framework
- Java 21 - Programming language
- Maven - Dependency management and build tool
- Spring Data JPA - Object-relational mapping
- MySQL 8.0 - Primary database
- Flyway - Database migration tool
- Hibernate - JPA implementation
- Spring Security - Authentication and authorization
- JWT (JSON Web Tokens) - Token-based authentication
- JJWT 0.11.5 - JWT library for Java
- Redis 7.2 - In-memory data structure store for caching
- Jedis - Java Redis client
- Spring Boot Mail - Email functionality
- SMTP (Gmail) - Email service provider
- Lombok - Reduce boilerplate code
- Spring Boot Actuator - Application monitoring and management
- Spring Boot Test - Testing framework
- Docker Compose - Container orchestration for development environment
- Java 21 or higher
- Maven 3.6+
- MySQL 8.0
- Redis 7.2
- RabbitMQ 3.x (for message queuing)
- Docker and Docker Compose (optional, for containerized setup)
-
Clone the repository:
$ git clone git@github.com:MohamedAEmara/task-management-system.git $ cd task-management-system -
Start the required services (MySQL, Redis, and RabbitMQ):
$ docker-compose -f src/main/resources/docker-compose.yml up -d
Note: This will start MySQL, Redis, and RabbitMQ containers. RabbitMQ Management UI will be available at http://localhost:15672 (admin/password)
-
Build and run the application:
./mvnw clean install ./mvnw spring-boot:run
-
Install MySQL 8.0 and create a database named
task-management-system -
Install Redis 7.2 and ensure it's running on port 6379
-
Configure Email Settings in
application.properties:- Update
spring.mail.usernameandspring.mail.passwordwith your Gmail credentials - Enable "App Passwords" in your Gmail account for authentication
- Update
-
Build and run the application:
./mvnw clean install ./mvnw spring-boot:run
spring.datasource.url=jdbc:mysql://localhost:3306/task-management-system
spring.datasource.username=emara
spring.datasource.password=asdfasdfspring.mail.host=smtp.gmail.com
spring.mail.port=587
spring.mail.username=your-email@gmail.com
spring.mail.password=your-app-passwordspring.redis.host=localhost
spring.redis.port=6379jwt.secret=TnIyTCYMZ5CMF/Jh18fru6RZ9UXoe5C4qGw3uiJ3GUg=
jwt.expiration=3600000notification.cron.daily=0 0 9 * * ?
notification.cron.weekly=0 0 10 * * MON
notification.enabled=truespring.rabbitmq.host=localhost
spring.rabbitmq.port=5672
spring.rabbitmq.username=admin
spring.rabbitmq.password=passwordThe application provides REST APIs for:
- Authentication (
/auth/*) - Login, registration, account verification - Users (
/users/*) - User management - Departments (
/departments/*) - Department operations - Tasks (
/tasks/*) - Task management - Notifications (
/notifications/*) - Notification management
The application uses the following main entities:
- Users: Base user information with role-based access (EMPLOYEE, MANAGER, ADMIN)
- Managers: Extended user information for managers
- Employees: Employee-specific information with department associations
- Departments: Organizational units managed by managers
- Tasks: Task entities with assignment and status tracking
- Daily Notifications: Sent at 9:00 AM every day
- Weekly Notifications: Sent at 10:00 AM every Monday
./mvnw clean package./mvnw spring-boot:run -Dspring-boot.run.profiles=devsrc/
├── main/
│ ├── java/com/emara/task/
│ │ ├── config/ # Configuration classes
│ │ ├── controller/ # REST controllers
│ │ ├── dto/ # Data Transfer Objects
│ │ ├── model/ # Entity classes
│ │ ├── repo/ # Repository interfaces
│ │ ├── security/ # Security configuration
│ │ └── service/ # Business logic
│ └── resources/
│ ├── db/migration/ # Flyway migration scripts
│ └── application.properties
└── test/ # Test classes
For support or questions, please contact the development team or create an issue in the repository.
