A Java EE web application for managing tasks, users, and task statuses, using Hibernate ORM and MySQL. This project provides a RESTful API for task management, user authentication, and status tracking, suitable for integration with modern frontend frameworks.
- Project Overview
- Tech Stack
- Folder Structure
- API Endpoints
- Setup & Installation
- Usage
- Contributing
- License
TaskManager is a backend application designed to manage tasks, users, and task statuses. It exposes RESTful endpoints for CRUD operations on tasks, user registration/login, and status retrieval. The backend is built with Java Servlets, Hibernate ORM, and MySQL, and is ready to be deployed on a Java EE server (e.g., GlassFish).
- User registration and login
- Task CRUD (Create, Read, Update, Delete)
- Task status management
- Hibernate ORM for database operations
- RESTful API with JSON responses
- CORS enabled for frontend integration
- Java EE (Servlets)
- Hibernate ORM
- MySQL (Database)
- Gson (JSON serialization)
- GlassFish (or compatible Java EE server)
- Maven/Ant (build tools)
TaskManager/
├── build.xml # Ant build script
├── README.md # Project documentation
├── src/
│ ├── conf/
│ │ └── MANIFEST.MF # Manifest file
│ └── java/
│ ├── hibernate.cfg.xml # Hibernate configuration
│ ├── controller/ # Servlet controllers (Task, User, TaskStatus)
│ └── hibernate/ # Entity classes (User, Task, TaskStatus, HibernateUtil)
├── web/
│ └── WEB-INF/
│ ├── glassfish-web.xml # GlassFish deployment descriptor
│ └── ...
├── lib/ # External libraries (JARs)
├── nbproject/ # NetBeans project files
└── test/ # Test sources (if any)
POST /api/user/login
— User loginPOST /api/user/register
— User registration
GET /api/tasks
— Get all tasksGET /api/tasks/{id}
— Get task by IDGET /api/tasks/user/{userId}
— Get tasks by userPOST /api/tasks
— Create a new taskPUT /api/tasks/{id}
— Update a taskDELETE /api/tasks/{id}
— Delete a task
GET /api/taskstatus
— Get all task statuses
- Clone the repository:
git clone https://github.com/cusaldmsr/TaskManagerApp-Backend.git
- Configure the database:
- Create a MySQL database named
task-manager
. - Update
src/java/hibernate.cfg.xml
with your DB credentials if needed.
- Create a MySQL database named
- Build the project:
- Use NetBeans, Ant, or your preferred Java IDE to build the project.
- Deploy:
- Deploy the generated WAR file to GlassFish or another Java EE server.
- Use tools like Postman or a frontend app to interact with the API endpoints.
- Ensure the server is running and accessible at the configured base URL.
Contributions are welcome! Please fork the repository and submit a pull request.
This project is licensed under the MIT License.