This is a simple product stock management system. It is a console application that allows
the user to add, edit, delete, and view products. The user can also view the total value
of the stock and the total value of the stock by category.
You can view the API documentation by entering the following URL in a browser on Heroku.
If you can watch a video of the application running on YouTube.
- Java 21
- Maven 3.8.1
- Spring Boot 3.1.5
- MySQL 8.0.26
- Docker 20.10.8
- Docker Compose 1.29.2
- JUnit 5.7.2
- OpenApi 2.2.0
- MapStruct 1.4.2
- Flyway 10.0.1
- Clone the repository
- Execute
docker compose up -d
in the terminal - Execute
mvn clean install
in the terminal - Create a schema named
products
in your MySQL databaseproducts
- Open the project in your IDE
- Run the program
- Enjoy!
- When the program starts, the user will be presented with a menu of options.
- The user can select an option by entering the corresponding number.
- The user can add, edit, delete, and view products.
- When the program starts, the user will be access the documentation.
- The user can view the API documentation by entering the following URL in a browser:
- http://localhost:8080/swagger-ui/index.html
- GET /product
- GET /product/{id}
- POST /product
- PUT /product
- DELETE /product/physic/{id}
- DELETE /product/logic/{id}
- The application is implemented following of Netflix hexagonal architecture.
- The application is divided into three layers: transportlayers, entities, interactors, and datasources.
- The transport layer is responsible for exposing the application to the outside world.
- The entities layer is responsible for the business logic.
- The interactors layer is responsible for the application use cases.
- The datasources layer is responsible for the data access.
- You can find more information about the architecture in the following link:
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
This project is licensed under the MIT License - see the LICENSE.md file for details.