This repository contains an example implementation of some Document Mangement System.
- Prerequisite: you need a Java SDK 17 and a Git client.
- Clone this repository:
git clone https://github.com/hex-arch-training/code.git cd code - Build the code using the Maven wrapper:
./mvnw clean package
-
You can run the
Document Mangement System's REST API as a Spring Boot web application:java -jar configuration/web-api/target/web-api-0.0.1-SNAPSHOT.jar
-
Add a simple revision:
curl -X POST http://localhost:8080/revision -H 'Content-Type: application/json' -d '{"documentTitle": "Title", "revisionContent": "some content"}'
The above POST request returns the ID of the revision just created, e.g:
1 -
Query the revision just created using this ID:
curl http://localhost:8080/revision/1