Download the PHP package gember/event-sourcing without Composer
On this page you can find all versions of the php package gember/event-sourcing. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download gember/event-sourcing
More information about gember/event-sourcing
Files in gember/event-sourcing
Package event-sourcing
Short Description Use case driven EventSourcing - Let go of the Aggregate with the Dynamic Consistency Boundary (DCB) pattern.
License MIT
Informations about the package event-sourcing
🫚 Gember Event sourcing
Use case driven EventSourcing - Let go of the Aggregate with the Dynamic Consistency Boundary (DCB) pattern.
Documentation
Full documentation is available at gemberphp.github.io/event-sourcing.
In a nutshell
Traditional 'Aggregate driven' EventSourcing
Domain concepts are modeled towards objects: the aggregate.
- Any business logic related to a single domain object should live inside the aggregate
- Logic that involves other domain objects or groups of the same kind of domain objects does not belong in the aggregate
'Use case driven' EventSourcing
Domain concepts are modeled through use cases.
- Any business logic tied to a use case should live inside that use case
- A use case can relate to one or more domain concepts
A simple example
This example demonstrates all key features of the library: a DCB use case with command handler, domain events, and a saga coordinating a workflow.
Scenario: A student subscribes to a course. When subscription succeeds, a saga automatically sends a welcome email.
Domain Events
Use Case with Command Handler
Saga
For more extended examples and complete implementations, check out the demo application gember/example-event-sourcing-dcb.
All versions of event-sourcing with dependencies
ext-mbstring Version *
ext-tokenizer Version *
gember/dependency-contracts Version ^0.8
psr/log Version ^3.0
psr/simple-cache Version ^3.0
