Repository that contains practical knowledge about various Spring Framework projects.
- Spring Framework
- Spring Boot 3
- Spring Data JPA
- Spring Security
- ☕ Java 17
- 🌱 Spring
- 🌶️ Lombok
- 🐋 Docker and jib
- 🛢️ MySQL (MariaDB) and H2 Database
- 🧪 JUnit and Mockito
- 🔄 MapStruct
- 📄 SpringDoc OpenAPI (Swagger)
- 📄 Actuator, Prometheus and Grafana
Follow these steps to set up the project locally on your machine.
Prerequisites
Make sure you have the following installed on your machine:
Cloning the repository
git clone https://github.com/lucasoliveirabr/springboot-essentials.git cd springboot-essentials
Starting the database
docker-compose up
Running the Project
mvn spring-boot:run
- Open http://localhost:8080/animes in your browser.
Running Unit Testing and Integration Testing
mvn test -P all-tests
Extra: Push image to Docker Hub with jib
docker login
mvn compile jib:build
-
Main HTTP request methods
- GET: Paginated anime search.
- GET: Search all animes.
- GET: Search for an anime by ID.
- POST: Insert a new anime.
- PUT: Update an existing anime.
- DELETE: Delete an anime.
-
Other routes
- SpringDoc OpenAPI (Swagger)
- Actuator
- Prometheus
- Grafana