A Java-based Lab Management System that handles user accounts, laboratories, and lab activities using MongoDB as the backend database.
This project demonstrates backend-focused application logic, including:
- User authentication
- Laboratory data management
- Activity scheduling and participation
- MongoDB integration using the official Java driver
This project relies on a MongoDB database structure provided separately.
📦 Database Repository:
👉 Database file
Make sure the database collections are available before running the application.
- User registration with auto-incremented user ID
- Credential validation (login)
- User data stored in MongoDB
- Persistent user ID tracking via a counter collection
- Add laboratory records
- Store lab details such as:
- Lab ID
- Lab name
- Function
- Specifications
- Location
- Retrieve all available labs
- Create lab activities
- Assign activities to labs
- Define active time slots per activity
- Join or cancel activities
- Track participants per activity
- Track user participation history
- Users are stored in the
Userscollection - A
Counterscollection is used to generate sequential user IDs - Authentication checks user ID or username + password
- Current user session is tracked internally
- Labs are stored in the
Labscollection - Each lab contains metadata describing its purpose and location
- Labs can be listed and referenced by activities
- Activities are stored in the
Activitiescollection - User participation is stored in
UserActivities - Each activity:
- Belongs to a lab
- Has selectable time slots
- Tracks registered participants
- Users can only join activities with active time slots
Activities use predefined time slots:
- 08:00
- 09:00
- 13:00
- 15:00
Each activity stores a boolean array indicating which slots are active.
The system uses the following MongoDB collections:
UsersCountersLabsActivitiesUserActivities
Collections are automatically created if they do not exist.
- Clone the project repository
- Ensure MongoDB access is available
- Update the MongoDB connection URI if needed
- Run the application using your Java IDE or command line
- Interact with users, labs, and activities through the application logic
- Language: Java
- Database: MongoDB
- Driver: MongoDB Java Driver
- Architecture: Model-based backend logic
- Data Format: BSON (MongoDB Documents)
This project demonstrates:
- Java–MongoDB integration
- CRUD operations in MongoDB
- Backend application structure
- Data modeling for real-world systems
- Exception handling and validation
- Multi-collection database design
- Password hashing and security improvements
- Role-based access control (admin / user)
- REST API layer (Spring Boot)
- GUI or web frontend
- Improved concurrency handling
- Better ID generation strategy
This project is intended for educational purposes.
You are free to modify and extend it for learning or academic projects.