https://github.com/maciekiwaniuk/shop-system
💰 Simple shop system made in Symfony using hexagonal architecture (as modular monolith - soon)
https://github.com/maciekiwaniuk/shop-system
codesniffer cqrs data-fixtures ddd deptrac docker doctrine event-sourcing hexagonal-architecture lexikjwt openapi pagination php8 phpstan phpunit redis symfony7 tests uuid
Last synced: about 1 month ago
JSON representation
💰 Simple shop system made in Symfony using hexagonal architecture (as modular monolith - soon)
- Host: GitHub
- URL: https://github.com/maciekiwaniuk/shop-system
- Owner: maciekiwaniuk
- Created: 2023-08-26T21:07:01.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-03-30T19:27:51.000Z (about 1 month ago)
- Last Synced: 2025-03-30T20:25:46.261Z (about 1 month ago)
- Topics: codesniffer, cqrs, data-fixtures, ddd, deptrac, docker, doctrine, event-sourcing, hexagonal-architecture, lexikjwt, openapi, pagination, php8, phpstan, phpunit, redis, symfony7, tests, uuid
- Language: PHP
- Homepage:
- Size: 913 KB
- Stars: 1
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Shop system - description below is not up to date, project is being rebuilt




## General info
- Several tools are utilized to facilitate the creation of robust code: phpstan (6 level), deptrac, codesniffer.
- The application is well-tested, with tests categorized into Application (E2E), Integration, and Unit tests.
- A caching system based on Redis has been implemented.## Technical solutions
- Directories are organized into /Module, which contains subdirectories for all modules, and /Shared, which includes
components shared across all modules. Each module [Order, Product, User] comprises four directories:
- Application -> houses the implementation of application logic
- Domain -> contains things related strictly to business information - entities, enums and interfaces of repositories
- Infrastructure -> includes components related to the technical layer, such as the database and caching system
- UI -> contains console commands or controllers that serve as the connection between the user and the system
- Actions are classified into commands and queries. I have implemented a custom solution for storing information after
the completion of actions. Each command returns a CommandResult, while queries return a QueryResult, which contains
information about success, status codes, and retrieved data.
- Authentication is implemented using the JWT approach with the LexikJWTAuthenticationBundle.
- Event sourcing is used to store information about the current status of an order. The latest created order status
indicates its current status.### Database
### API Docs

### Structure
### Module
## Commands using Make
Initialize for first time run
make initialize
Run development profile
make run
Drop migrations, migrate and load fixtures
make drop_migrations
make migrate
make load_fixturesRun all tests
make test
## Commands without Make
Initialize for first time run
docker-compose up --profile dev -d
docker-compose exec php bin/console doctrine:migrations:diff
docker-compose exec php bin/console doctrine:migrations:migrate
docker-compose exec php bin/console lexik:jwt:generate-keypair#### For other commands check content of Makefile
## API Documentation
The API documentation is available at
localhost:80/api/doc