ecotone-examples / php-ddd-cqrs-event-sourcing-ecotone
Requires
- php: >=8.0
- ext-ctype: *
- ext-iconv: *
- ext-pdo: *
- ext-pdo_pgsql: *
- composer/package-versions-deprecated: 1.11.99.4
- doctrine/dbal: ^2.0
- doctrine/doctrine-bundle: ^2.5
- doctrine/doctrine-migrations-bundle: ^3.2
- doctrine/orm: ^2.10
- ecotone/jms-converter: ^1.0
- ecotone/pdo-event-sourcing: ^1.0
- ecotone/symfony-bundle: ^1.0
- symfony/console: 5.2.*
- symfony/flex: ^1.3.1
- symfony/framework-bundle: 5.2.*
- symfony/proxy-manager-bridge: 5.2.*
- symfony/twig-bundle: 5.2.*
- symfony/yaml: 5.2.*
Conflicts
Replaces
This package is auto-updated.
Last update: 2022-03-12 08:55:16 UTC
README
Application shows the how complex systems can be built with ease using PHP. The example using CQRS DDD and Event Sourcing backed by Prooph in Symfony using Ecotone Framework.
Have fun :)
Run using docker-compose
make start # Starts the containers. `make docker_up_detached` would run it in detached (-d) mode. make help # To see the available usage command make [tab] # For autocomplete make sh # to login to the bash of the app container # Inside the container console [tab] # To get all the Symfony's available commands including Ecotone ones exit # Outside the container make db_sql # To access the PostgreSQL command CLI on the database container make stop # To stop the containers and their networks (keep their volumes and images) make reset # To remove the containers, their networks, their volumes for then restarting from scratch make clean # To remove everything from Docker and let your computer as if you never used this repo
- The application is available under
localhost:3000
- As read model is updated asynchronously, you may need to refresh after performing action to see the changes.
Run on local Kubernetes
In order to set up local cluster with ease follow the instructions from here. And install skaffold for automatic code synchronization to your Kubernetes. You will be able to modify the code and see the changes instantly on same deployment.
Add to your hosts file (/etc/hosts) ecotone.local.dev for your docker ip address (127.0.0.1 for linux) Run `skaffold dev --tail` Enter `https://ecotone.local.dev` and enjoy the application :)
If you want to get more information on how it everything play together visit the blog post.
Possible Integrations with Laravel and Ecotone Lite
Application is written in Symfony
, however Ecotone
integrates with Laravel
and can be run alone without any additional framework (Ecotone Lite
).
All the code that is written in here, will work exactly the same way, when will be run with Laravel
or Ecotone Lite
.