Could I ask to somebody explain a concept of Aggregates and Aggregate roots. I just partly understand how should i operate with them in context of CQRS/Event-Sourcing.
There is this quote in http://cqrs.nu/Faq
And i have a some prototype like this:
If I am right, then in context of some Postal Service - Advertisement Services (bounded context), that whole thing named in violet NEW_PROJEKTS… is a Aggregate Root? Right? It’s a single project multiple people operate with. It has a stages and it contains a huge amount of child aggregates, like zones (highlighted yellow), groups for zone grouping (red) and optionally could contain a special selection of special addresses (extra service in those) in some zones (green). As well there are bunch of actions for every aggregate in this picture (hidden under context menus).
So, if I want to make bulk action (to add some distribution rules) on subset of all assigned zones (districts), that i naturally are thinking of Sagas, but in quote above they state that probably i have wrong aggregate boundaries.
Could somebody be so kind and explain me based on this example, what is what?
- Aggregate Root
- What data should be saved in event?
If i want to persist single small change (users collaboratively adding zones (districts) to project via web sockets), should i save a whole state of whole aggregate root? It sounds like a just crazy idea as there will no be a factory to produce storage for me.