The One Question To Haunt Everyone: What is a DDD Aggregate? - Thomas Ploch - DDD Europe 2022

  Рет қаралды 39,863

Domain-Driven Design Europe

Domain-Driven Design Europe

Жыл бұрын

Domain-Driven Design Europe 2022
dddeurope.com - / ddd_eu - newsletter.dddeurope.com/ / domain-driven-design-e...
Organised by Aardling (aardling.eu/)
There is one question that I am getting asked at almost every conference or meetup: What is and what isn't an Aggregate? How do we design an Aggregate? To be honest, it's not an easy answer, even for experienced practitioners.
In this session I am summarizing the current state of affairs regarding Aggregate design in the Domain-Driven Design community.
I am Thomas, and I design systems for people and computers for fun and profit!
My career has navigated me through various industries like Finance & Insurance, Medical, Automotive and Travel. I have been wearing many differently shaped hats over the last 15 years. From System Administration, Test Automation, Web Development, Software Architecture & Design, Product Design & Organisation Design, I can draw on a bit of experience that currently helps me every day as a Principal Solutions Architect FlixBus.
The biggest realization over the last few years is that the most important component of success is not running the latest distributed architecture in the cloud, but to enable people to work smart to manifest their ideas in helpful products. I want to share my experiences and hope that you can take away a bit of knowledge that can help you later.
It is impossible to design useful software without understanding the underlying forces driven by market conditions, competitors, business strategy and the actual people using or building the software. Hence, I firmly believe that a wider definition of system design is required to achieve an adaptive and evolvable environment of people, processes and technology that can react to changing conditions in our fast paced digital world.

Пікірлер: 39
@toinbis
@toinbis Жыл бұрын
Great talk Thomas! Thanks DDD Europe for sharing!
@DevOpsCraftsman
@DevOpsCraftsman Жыл бұрын
Best overview of aggregates and the reasoning behind it so far for me.
@filipmilovanovic8942
@filipmilovanovic8942 11 ай бұрын
It's encapsulation (a Facade (AR) provides an interface to effect aggregate behaviors) & cohesion (the aggregate being a group of closely related coevolving objects) - it's just that it's applied beyond the level of a single object.
@Felipe-53
@Felipe-53 4 ай бұрын
What an excellent talk, thank you very much for putting it out!
@rammehar5531
@rammehar5531 Жыл бұрын
What a wonderful explanation thanks
@charlesopuoro5295
@charlesopuoro5295 Жыл бұрын
Insightful Talk on just what Aggregates are, a Deep, Revealing Dive. Thank you so much.
@mohamedbeyremmakhlouf
@mohamedbeyremmakhlouf Жыл бұрын
awesome talk, very clear explanation thanks
@ismailm123
@ismailm123 Жыл бұрын
Fantastic explanation, very useful talk.
@ANTGPRO
@ANTGPRO 10 ай бұрын
Brilliant lecture! Thank you.
@jelenacupac7
@jelenacupac7 Жыл бұрын
Very engaging and informative presentation.
@pavelvasianovych4030
@pavelvasianovych4030 9 ай бұрын
Thank you very much!
@matthieujacquot8841
@matthieujacquot8841 Жыл бұрын
the quote may come from Vaughn Vernon paper "Effective Aggregate Design". I quote the paper : "Therefore, it is just plain smart to limit aggregate size. When you occasionally encounter a true consistency rule, then add another few entities, or possibly a collection, as necessary, but continue to push yourself to keep the overall size as small as possible"
@thomasgraf2107
@thomasgraf2107 10 ай бұрын
yes i had this paper in mind as well.
@nichtverstehen2045
@nichtverstehen2045 12 күн бұрын
well, then CRUD is the ultimate aggregate :))) reinventing the wheel is endless game
@jorgeolive9605
@jorgeolive9605 Жыл бұрын
IMO, a fundamental flaw that involves the DDD aggregate concept is that persistence concerns leak into their design - eg: race conditions because big object graphs, load to the database due to lots of entities, etc. This might lead to designs dictated because of your infrastructure components, not your domain.
@matthieujacquot8841
@matthieujacquot8841 Жыл бұрын
I guess that, like all engineering problems, we've to accept that we live in the real world. This reminds me the "fallacies of distributed computing" : sure everything would be easier and nicer if the network was reliable, without latency... but it's just not true and we've to deal with it
@NaveenSiddareddy
@NaveenSiddareddy Жыл бұрын
what if each entity has it local storage inside the aggregate and triggers another entity based on invariants (business rule)? essentially nodes and edges inside aggregate
@Deepz007
@Deepz007 9 ай бұрын
awesome!
@joachimdietl6737
@joachimdietl6737 Жыл бұрын
if these things have to be explained the ddd book cant be so good
@vincentcifello4435
@vincentcifello4435 Жыл бұрын
My opinion based on months of exploration trying to understand this topic. No offense intended... Q: "What does this picture represent? Why does it take 3 months to implement a small little change?" A: Tight coupling and low cohesion caused by incorrect boundaries. Suggesting that Aggregates, in and of themselves , can stop a system from spinning out of control is highly questionable. The boundaries need to be correct or coupling will take over. Everything will start breaking with even the most simple change, regardless of any Aggregate implementation. Of course, Aggregates, just like any other software construct, are "artificial" and "invented", but the proper boundaries most certainly are not. I really think that this is a misinterpretation of the blue book. Evans effectively said the opposite, "Forcing the required domain functionality to be the responsibility of an ENTITY or VALUE either distorts the definition of model-based object or adds meaningless artificial objects". Even in the cutlery metaphor, this becomes evident. Sure, cutlery is used together. So, keeping it in the same drawer (Aggregate) seems reasonable. However, the number of tines on a fork has absolutely nothing to do with knives or spoons. We have now coupled completely separate concerns and planted the seed for future disaster. Q: Why should Aggregates "be as small as possible" ? A: Because Vaughn Vernon said so! Q: OK, maybe, but why did he say that? Aggregates should be as small as possible because the immediate transactional consistency boundaries that they protect are relatively small by their very nature. "Finding correct service boundaries is really, really hard." - Udi Dahan paraphrase circa 21st century earth, local time.
@sighupcmd
@sighupcmd 9 күн бұрын
I heard so many people struggling with Aggregate term, but all I see is just a classic GoF Facade done right.
@nasamind
@nasamind Жыл бұрын
Awesome
@sotsch9280
@sotsch9280 Жыл бұрын
Very well explained! But there is one question left! how aggregates communicate with each other? do they "just" reference each other, for simplicity in the same bounded context?
@toufikoran8416
@toufikoran8416 Жыл бұрын
it seems like fancy OO
@m13v2
@m13v2 Жыл бұрын
composite: all functionality in one class. aggregate: functionality spread over multiple classes and one (facade) aggregating them. (mentioned in Ivar Jacobson‘s OOSE book 😁)
@ehm-wg8pd
@ehm-wg8pd 10 ай бұрын
its fun to get there, but its not fun to be there never been more accurate!
@boltthrower142
@boltthrower142 Жыл бұрын
@3:33 il problema non è se il system arriva o no a questo livello di complessità, il problema è chi scrive una query che implica 1000 tabelle...
@ornous
@ornous Жыл бұрын
True.
@botyironcastle
@botyironcastle 2 ай бұрын
what if you have huge data like 100000000comments in Post object. I don't think you can init a domain object with that much... looks useless to me when dealing with large chuncks of data. Thoughts?
@McRakns
@McRakns Ай бұрын
Very long way to explain plain old encapsulation of the object-oriented design
@kboite
@kboite Жыл бұрын
Lol, zero real solutions given. The first rule of distributed computing should be : don't do distributed computing (unless you really need to). Not "split your ACID boundaries early on" into various "agregates". For instance, this talk doesn't explain all the inconsistent system states that can occur if that UserAccount is deleted on one side, the CRMAccount should react to it and a third system losely depends on the existence of the CRMAccount. Like billing a user that shouldn't exist in your system anymore. Stuff like that. Without the saga patterns to monitor such inconsistencies and try repairing them, offering cancellation or refund. Premature distribution is a recipe for disaster. Agregates teached this way hence are a recipe for disaster.
@md.redwanhossain6288
@md.redwanhossain6288 3 ай бұрын
Domain events can help here.
@allmhuran
@allmhuran 15 күн бұрын
The idea that you can have two aggregates whose values are all identical other than some specific identity value, which makes them different, is fundamentally incorrect. The "specific identity value" *does not exist in the world*. It is *not part of the domain*. It's completely artificial, and therefore represents nothing. From the point of view of the domain, or any actual user who is using the system, two aggregates whose values are all identical are the same aggregate, by definition. To take a simple example, suppose I have a domain object representing a customer, and this customer happens to only have a single property - name. I create a customer "John". I then create another customer "John". How many customers do I have? ONE. You need proof? Suppose a customer calls up. You want to find them in the system. You ask them "what's your name". "John", they reply. Cool. Which "John" is THIS "John"? What are you going to do, say something like "Hey I have two Johns, one is ID 123 and the other is ID 124, which one are you?". The guy on the phone is going to ask what the heck you are talking about. This is the same mistake as saying "you don't need natural keys in your relational database, just add surrogate keys to your tables". No, that's completely and fundamentally wrong.
@boltthrower142
@boltthrower142 Жыл бұрын
it seems like the rediscovery of hot water, e.g. the entity-relationship model.. is it more important to wear a cap with a visor and a floral shirt, or a fruit shirt with pears and oranges? ::
@NaveenSiddareddy
@NaveenSiddareddy Жыл бұрын
everything in the world ends up as entity and relationships.. a graph with active nodes might solve this problem
@boltthrower142
@boltthrower142 Жыл бұрын
@@NaveenSiddareddy yes, I wonder if there's a real need for these ever new presumed "concepts", apart from selling books & colorful gadgets ;;
@chavdarangelov1433
@chavdarangelov1433 11 ай бұрын
If you can't explain it to a six year old, you don't understand it yourself.
@andyliu1210
@andyliu1210 11 ай бұрын
And one should stop using fancy words (specialized terms)
@md.redwanhossain6288
@md.redwanhossain6288 3 ай бұрын
So you want to teach DDD to a six year old? Good luck with that.
The DDD Starter Modelling Process - Maxime Sanglan-Charlier - DDD Europe 2022
48:26
Domain-Driven Design Europe
Рет қаралды 20 М.
DDD By Example - Paul Rayner - DDD Europe 2020
54:58
Domain-Driven Design Europe
Рет қаралды 49 М.
Looks realistic #tiktok
00:22
Анастасия Тарасова
Рет қаралды 106 МЛН
DEFINITELY NOT HAPPENING ON MY WATCH! 😒
00:12
Laro Benz
Рет қаралды 63 МЛН
39kgのガリガリが踊る絵文字ダンス/39kg boney emoji dance#dance #ダンス #にんげんっていいな
00:16
💀Skeleton Ninja🥷【にんげんっていいなチャンネル】
Рет қаралды 8 МЛН
Как бесплатно замутить iphone 15 pro max
00:59
ЖЕЛЕЗНЫЙ КОРОЛЬ
Рет қаралды 8 МЛН
Nature's Incredible ROTATING MOTOR (It’s Electric!) - Smarter Every Day 300
29:37
Don't be fooled! That's NOT an Aggregate in Domain Driven Design
10:12
Balancing Coupling in Software Design - Vlad Khononov - DDD Europe 2023
50:43
Domain-Driven Design Europe
Рет қаралды 8 М.
How I Mastered System Design Interviews
10:22
Ashish Pratap Singh
Рет қаралды 133 М.
Practical DDD - Transforming theories into guidelines - Hila Fox - DDD Europe 2023
45:23
How to Use Value Objects to Solve Primitive Obsession
13:54
Milan Jovanović
Рет қаралды 42 М.
Lost in transaction  - Bernd Ruecker - DDD Europe 2019
53:38
Domain-Driven Design Europe
Рет қаралды 6 М.
Is Domain-Driven Design Overrated? • Stefan Tilkov • GOTO 2021
31:21
GOTO Conferences
Рет қаралды 668 М.
Какой ноутбук взять для учёбы? #msi #rtx4090 #laptop #юмор #игровой #apple #shorts
0:18
$1 vs $100,000 Slow Motion Camera!
0:44
Hafu Go
Рет қаралды 28 МЛН
Проверил, как вам?
0:58
Коннор
Рет қаралды 13 М.
S24 Ultra and IPhone 14 Pro Max telephoto shooting comparison #shorts
0:15
Photographer Army
Рет қаралды 10 МЛН