Skip to content

This is tutorial project to learn how to connect Symfony4 and docker compose with Domain Driven Design and Event Sourcing

License

Notifications You must be signed in to change notification settings

yasiekz/payments-DDD-ES-tutorial

Repository files navigation

Build Status codecov

DDD + CQRS + ES + Symfony 4 based API + docker + Codeception

This is tutorial project to learn how to connect Symfony4 and docker compose with Domain Driven Design and Event Sourcing

Project resolves real problem with bank accounts and payments. Under development

Event Souring is based on two most popular PHP libraries:

Key features:

  • fully dockerized project
  • payments and account balance build from events
  • around 90% code coverage with phpunit unit and functional tests
  • event store on mongoDB, fully separated from domain
  • travis automated tests
  • Data fixtures

Scheduled functionality

  • Load domain objects from snapshots
  • REST API calls with CQRS
  • API tests with Codeception

Local run

You need docker and docker-compose installed on your system. After cloning repo just run:

docker-compose up -d
docker exec -it payments-ddd-es-tutorial-php composer install

If you want to run your app with some predefined objects from fixtures just run:

docker exec -it payments-ddd-es-tutorial-php php bin/console doctrine:mongodb:fixtures:load

Then on localhost:8080 will be your site.

Run automated tests

docker-compose -f docker-compose.test.yml up -d
docker exec -it payments-ddd-es-tutorial-php-test vendor/bin/phpunit -c phpunit.xml.dist

About

This is tutorial project to learn how to connect Symfony4 and docker compose with Domain Driven Design and Event Sourcing

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages