- Notifications
You must be signed in to change notification settings - Fork42
DDD+CQRS+Event-sourcing examples using EventFlow following CQRS-ES architecture. It is configured with RabbitMQ, MongoDB(Snapshot store), PostgreSQL(Read store), EventStore(GES). It's targeted to .Net Core 2.2 and include docker compose file.
License
OKTAYKIR/EventFlow.Example
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
DDD+CQRS+Event-sourcing examples using EventFlow following CQRS-ES architecture. It is configured with RabbitMQ, MongoDB(Snapshot store), PostgreSQL(Read store), EventStore(GES). It's targeted to .Net Core 2.2 and includedocker compose file.
The most common CQRS/ES architecture would look like following diagram
The example consists of the following concepts, each shown below
- Aggregates
- Command bus and commands
- Synchronous subscriber
- Event store (GES)
- In-memory read model.
- Snapshots (MongoDb)
- Sagas
- Event publising (In-memory,RabbitMq)
- Metadata
- Command bus decorator, custom value object, custom execution result, ...
varresolver=EventFlowOptions.New.UseAutofacContainerBuilder(newContainerBuilder()).Configure(c=>c.ThrowSubscriberExceptions=true).AddEvents(typeof(ExampleEvent)).AddEvents(typeof(ResetEvent)).AddCommands(typeof(ExampleCommand)).AddCommands(typeof(ResetCommand)).AddCommandHandlers(typeof(ExampleCommandHandler)).AddCommandHandlers(typeof(ResetCommandHandler)).ConfigureEventStore().ConfigureMongoDb(client,SNAPSHOT_CONTAINER_NAME).AddSnapshots(typeof(ExampleSnaphost)).UseMongoDbSnapshotStore().RegisterServices(sr=>sr.Register(i=>SnapshotEveryFewVersionsStrategy.Default)).RegisterServices(DecorateCommandBus).PublishToRabbitMq(RabbitMqConfiguration.With(newUri(@"amqp://test:test@localhost:5672"),true,4,"eventflow")).UseInMemoryReadStoreFor<Aggregates.ReadModels.ExampleReadModel>().AddJobs(typeof(ExampleJob)).CreateResolver());
- Fork it (https://github.com/OKTAYKIR/EventFlow.Example/fork )
- Create your feature branch (
git checkout -b my-new-feature) - Commit your changes (
git commit -am 'Add some feature') - Push to the branch (
git push origin my-new-feature) - Create a new Pull Request
Please ⭐️ this repository if this project helped you!
Apache-2.0 ©Oktay Kır
About
DDD+CQRS+Event-sourcing examples using EventFlow following CQRS-ES architecture. It is configured with RabbitMQ, MongoDB(Snapshot store), PostgreSQL(Read store), EventStore(GES). It's targeted to .Net Core 2.2 and include docker compose file.
Topics
Resources
License
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Releases
Packages0
Uh oh!
There was an error while loading.Please reload this page.