To ease the development without an IDE or systems without a proper Java installation, we utilize Just to provide run config/recipes.
just run-local
This will start the necessary dependencies (database etc.) before starting the application via maven.
just run-cont
This will build the Dockerfile and start the application inside Docker.
just prepare-dev
This will simply run the necessary dependencies for the application to be able to start.
After that you can simply compile and start the application via e.g. IntelliJ.
Simply open the justfile and copy the command and paste it into your terminal. If you want to fully utilize your IDE, you can do something like this in Intellij:
- Right-click on docker-compose.dev.yml.
- Choose Run 'docker-compose.dev.yml'.
- Next time you start IntelliJ, you will find this under your run configurations.
This project loosely follows DDD tactical patterns and is oriented towards a hexagonal architecture. Inside any of the following folders, subpackages will be grouped by their use case / domain model.
Entrypoint for the ports to the domain. Usually, controller speak to just services inside the application layer. Everything in there is basically a Spring Service.
The domain package is only concerned about domain logic.
Everything that is needed for the application to run but is not part of the domain model is put here. Infrastructure concerns can be interfaces that talk to external services (email, rest clients, ...) or simply configuration files for Spring.
Define ways in and out of the application. Subpackages usually denote the protocol that is used (rest, websocket, grcp, ...).