Skip to content

Latest commit

 

History

History
50 lines (36 loc) · 1.34 KB

README.md

File metadata and controls

50 lines (36 loc) · 1.34 KB

Build Status

Student Grades

This is a toy Spring Boot application to demonstrate persisting data to a file database (HSQL) via a web service that receives and responds in JSON. Data persistence happens on an HSQL database file populated with some example data.

Setup

  1. Install Java v1.8 and Apache Maven >=3.5.4
  2. Download the source:
git clone https://github.com/zFlux/StudentGrades
  1. Build and run the project:
mvn compile exec:java
  1. That's it! See below for example requests

Example curl GET requests

Retrieve all students and their related grades

curl --header "Content-Type: application/json" http://localhost:8080/student_records

Retrieve a specific student by student ID

curl --header "Content-Type: application/json" http://localhost:8080/student/UOT-001-1

Retrieve a specific grade by student ID

curl --header "Content-Type: application/json" http://localhost:8080/grade/UOT-001-1

POST endpoints

To add a grade, student or a set of student records, POST something similar to what is in the "examples" directory to these endpoints:

http://localhost:8080/grade
http://localhost:8080/student
http://localhost:8080/student_records

Please feel free to modify this example!