- Command surface: - add a root `Justfile` with namespaced `api`, `ui`, and `release` modules so humans and agents can use the same entrypoints from the repo root - add project-local Justfiles for `booklore-api`, `booklore-ui`, and `tools/release` so each area remains self-contained and can still be driven from inside its own directory - standardize local developer workflows around `just check`, `just test`, `just api run`, `just ui dev`, `just db-up`, and `just image-build` - Workflow integration: - update the reusable test suite workflow to install `just` and run backend and frontend CI steps through the Justfiles instead of hardcoded shell commands - update the semantic-release workflows to install `just` and invoke release tooling via `just release install`, `just release preview`, and `just release run` - keep the Docker image publication workflows on the native Docker actions while moving the project-command logic into the canonical command surface - Documentation: - split backend and frontend implementation guidance into `booklore-api/README.md`, `booklore-api/CONTRIBUTING.md`, `booklore-ui/README.md`, and `booklore-ui/CONTRIBUTING.md` - simplify the top-level `README.md` and `CONTRIBUTING.md` so they stay focused on overview, policy, and navigation while pointing to component-specific guides for deeper detail - align contributor-facing examples on the `just` interface instead of mixing ad hoc Gradle, npm, Docker, and Compose commands - Developer environment: - add `mise.toml` to pin the expected Java and Node toolchain versions for local work - switch the development Compose defaults from the old Booklore database values to Grimmory-oriented defaults - keep the command layout ready for a future API/UI split without forcing that packaging change yet
2.0 KiB
Grimmory API
The booklore-api project is the Spring Boot backend for Grimmory. It owns the HTTP API, database migrations, background processing, authentication, and the packaged runtime jar that the production container runs.
Stack
- Java 25
- Spring Boot 4
- Gradle Wrapper
- Spring Data JPA + Flyway
- MariaDB in production, H2 for selected tests
- JUnit 5, Mockito, AssertJ, JaCoCo
Local Command Surface
Use Justfile when possible. It is the primary backend command surface for both humans and agents.
just # List backend recipes
just run # Start bootRun with the dev profile
just test # Run the backend test suite
just coverage # Run tests and generate JaCoCo output
just check # Run the Gradle check lifecycle
just tasks # Show available Gradle tasks
The repository root also exposes the same recipes through namespacing:
just api test
just api run
just api coverage
Running Locally
The backend expects a MariaDB instance and a local application-dev.yml with your database and storage paths. The higher-level setup lives in ../CONTRIBUTING.md, but the common backend loop is:
cd booklore-api
just run
If you need a different Spring profile:
just run profile=local
Build and Test
just build
just test
just coverage
just check
The frontend bundle is consumed during packaging when the UI build output exists. For normal backend-only development and test runs, the frontend resources are optional.
Packaging Notes
- The production container image is built from the repository root
Dockerfile. - That Docker build compiles the UI first and passes the resolved frontend dist path into the backend build.
- The backend jar remains the packaged application artifact for the current all-in-one runtime model.
More Detail
Backend-specific contributor rules and conventions live in CONTRIBUTING.md.