https://github.com/henriiqueaze/studentprogress
StudentProgress is a Spring Boot application for managing and tracking student data, including grades and academic status. It provides an API for registering, updating, and monitoring student records, calculating averages, and offering real-time insights into student performance, helping educational institutions streamline their processes.
https://github.com/henriiqueaze/studentprogress
docker java spring-boot sql
Last synced: about 2 months ago
JSON representation
StudentProgress is a Spring Boot application for managing and tracking student data, including grades and academic status. It provides an API for registering, updating, and monitoring student records, calculating averages, and offering real-time insights into student performance, helping educational institutions streamline their processes.
- Host: GitHub
- URL: https://github.com/henriiqueaze/studentprogress
- Owner: henriiqueaze
- License: mit
- Created: 2025-03-11T23:36:50.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-07-08T23:35:43.000Z (12 months ago)
- Last Synced: 2025-08-25T19:03:01.414Z (10 months ago)
- Topics: docker, java, spring-boot, sql
- Language: Java
- Homepage:
- Size: 55.8 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
#
๐ StudentProgress API ๐
**StudentProgress** is a Spring Boot application for managing and tracking student data, including grades and academic status.
It provides an API for registering, updating, and monitoring student records, calculating averages, and offering real-time insights into student performance.
This helps educational institutions streamline their processes efficiently.
---
## โจ Features
- ๐ Full CRUD operations for student records in the database
- ๐ฏ Filter students by academic status
- ๐งฎ Automatically calculate grade averages
- ๐ HATEOAS support for enhanced API navigation
- ๐ Pagination and pageable search for student lists
- ๐ ๏ธ Database version control with Flyway
---
## ๐ How to Use
1. **Clone the repository:**
```bash
git clone git@github.com:henriiqueaze/StudentProgress.git
cd StudentProgress
```
2. **Create the MySQL database:**
Before running the application, make sure you have a MySQL server running locally or accessible remotely,
and create the database used by the app:
```bash
CREATE DATABASE student_progress;
```
3. **Set up environment variables:**
Copy the example file and customize it:
```bash
cp .env.example .env
```
Make sure the SPRING_DATASOURCE_URL points to your MySQL server host and port, for example:
```bash
jdbc:mysql://localhost:3306/student_progress?useSSL=false
```
4. **Build the application (.jar) with Maven:**
This step compiles the code and generates the .jar file inside the target/ folder:
```bash
./mvnw clean package
```
5. **Run the application using Docker Compose:**
```bash
docker-compose up --build
```
6. **Access the API documentation (Swagger):**
```bash
http://localhost:8080/swagger-ui.html
```
---
## ๐ API Endpoints
- ๐ `GET /student/{id}` - Retrieve a specific student details
- ๐ฅ `GET /student` - Retrieve all student details. Optional query parameters for pagination:
- page: page number (default: 0)
- size: number of records per page (default: 12)
- direction: sorting direction, asc or desc (default: asc)
- Example:
```bash
GET /student?page=0&size=10&direction=desc
```
- ๐ `POST /student` - Register a new student
- โ๏ธ `PUT /student` - Update student information
- ๐๏ธ `PATCH /student/id` - Update a student a specific information
- โ `DELETE /student/id` - Remove a student record
- ๐ `GET /student/average/id` - Get the grade point average of a specific student
- ๐งฎ `GET /student/filter/{status}` โ Filter students by academic status
---
## ๐ CORS Configuration
This API supports **CORS (Cross-Origin Resource Sharing)** to enable integration with front-end applications hosted on different domains.
CORS is configured globally in the backend using the following setup:
- Allowed Origins: Defined via CORS_ALLOWED_ORIGINS
- Allowed Methods: All (GET, POST, PUT, PATCH, DELETE, etc.)
- Credentials: Enabled (allowCredentials=true) โ supports cookies and authorization headers
In your .env file, define:
```bash
CORS_ALLOWED_ORIGINS=http://localhost:8080
```
To allow multiple domains, separate them with commas:
```bash
CORS_ALLOWED_ORIGINS=http://localhost:8080,https://your-frontend.com
```
---
## ๐ ๏ธ Technologies Used
- โ Java (Spring Boot)
- ๐๏ธ MySQL (Database)
- ๐๏ธ Hibernate (ORM)
- ๐ HATEOAS (Hypermedia API support)
- ๐งช JUnit (Testing framework)
- ๐ Flyway (Database migrations)
- ๐ณ Docker & Docker Compose
- ๐ Swagger (API documentation)
---
## ๐ License
This project is licensed under the MIT License.
Feel free to use and modify it according to your needs.
---
For contributions or support, please contact me via email at [henriqueeaze.dev@gmail.com](mailto:henriqueeaze.dev@gmail.com)
or connect with me on [LinkedIn](https://www.linkedin.com/in/henrique-azevedo-b2195b2b0/).