Understanding Domain-driven Design | Software Architecture Conference
0 views
Aug 6, 2025
"What is Domain-driven design? When to use it? Tactical patterns of Domain-driven design Strategical Patterns of Domain-driven design" 🔗 Conference Website: https://softwarearchitecture.live 📺 CSharp TV - Dev Streaming Destination http://csharp.tv 🌎 C# Corner - Community of Software and Data Developers https://www.c-sharpcorner.com #CSharpTV #CSharpCorner #CSharp #SoftwareArchitectureConf
View Video Transcript
0:03
hey everyone my name is tral I'm
0:04
hey everyone my name is tral I'm
0:04
hey everyone my name is tral I'm Microsoft MVP cop Corner MVP and chief
0:07
Microsoft MVP cop Corner MVP and chief
0:07
Microsoft MVP cop Corner MVP and chief software Arch I'm out I have YouTube
0:10
software Arch I'm out I have YouTube
0:10
software Arch I'm out I have YouTube channel TR man Tech where I share my
0:12
channel TR man Tech where I share my
0:12
channel TR man Tech where I share my knowledge related to C SQL microservices
0:17
knowledge related to C SQL microservices
0:17
knowledge related to C SQL microservices domain driven design graphical all the
0:19
domain driven design graphical all the
0:19
domain driven design graphical all the Technologies I know and today's session
0:21
Technologies I know and today's session
0:21
Technologies I know and today's session is about domain driven design I now we
0:24
is about domain driven design I now we
0:24
is about domain driven design I now we have a limited time so I will try to
0:26
have a limited time so I will try to
0:26
have a limited time so I will try to wrap up and I will try to touch every
0:30
wrap up and I will try to touch every
0:30
wrap up and I will try to touch every aspect of domain drin design and I will
0:32
aspect of domain drin design and I will
0:32
aspect of domain drin design and I will try to explain every building blocks of
0:34
try to explain every building blocks of
0:34
try to explain every building blocks of domain drin design as simple as possible
0:37
domain drin design as simple as possible
0:37
domain drin design as simple as possible okay so first things first before uh
0:41
okay so first things first before uh
0:41
okay so first things first before uh defining domain drin design let's try to
0:44
defining domain drin design let's try to
0:44
defining domain drin design let's try to understand what we have and why in which
0:47
understand what we have and why in which
0:47
understand what we have and why in which type of cases we are able to apply our
0:50
type of cases we are able to apply our
0:50
type of cases we are able to apply our domain ding design so first things first
0:53
domain ding design so first things first
0:53
domain ding design so first things first we need to understand some important key
0:55
we need to understand some important key
0:55
we need to understand some important key characteristics of software systems we
0:58
characteristics of software systems we
0:58
characteristics of software systems we have performance we have scalability we
1:02
have performance we have scalability we
1:02
have performance we have scalability we have business logic complexity we have a
1:05
have business logic complexity we have a
1:05
have business logic complexity we have a big amount of
1:06
big amount of
1:06
big amount of data and we have technical complexities
1:09
data and we have technical complexities
1:09
data and we have technical complexities like for example you you have a solution
1:12
like for example you you have a solution
1:12
like for example you you have a solution you have a project you need to apply
1:14
you have a project you need to apply
1:14
you have a project you need to apply complex data structures algorithms you
1:16
complex data structures algorithms you
1:17
complex data structures algorithms you need to apply different Technologies
1:19
need to apply different Technologies
1:19
need to apply different Technologies this is a technical complexity so in
1:21
this is a technical complexity so in
1:21
this is a technical complexity so in which type of cases we are able to apply
1:24
which type of cases we are able to apply
1:24
which type of cases we are able to apply domain driven design for example if you
1:27
domain driven design for example if you
1:27
domain driven design for example if you need a performance if you need a scale a
1:29
need a performance if you need a scale a
1:29
need a performance if you need a scale a ability but you have a simple
1:32
ability but you have a simple
1:32
ability but you have a simple application should you apply domain driv
1:34
application should you apply domain driv
1:34
application should you apply domain driv design or you have a big amount of data
1:37
design or you have a big amount of data
1:37
design or you have a big amount of data to handle you have technical complexity
1:39
to handle you have technical complexity
1:39
to handle you have technical complexity should you apply domain driven
1:42
should you apply domain driven
1:42
should you apply domain driven design well we apply domain driven
1:45
design well we apply domain driven
1:45
design well we apply domain driven design when we have business complex
1:49
design when we have business complex
1:50
design when we have business complex business complexity let's say Okay
1:51
business complexity let's say Okay
1:51
business complexity let's say Okay business logic complexity so uh also you
1:56
business logic complexity so uh also you
1:56
business logic complexity so uh also you are able to apply domain driven design
1:58
are able to apply domain driven design
1:58
are able to apply domain driven design if you don't have any knowledge related
2:01
if you don't have any knowledge related
2:01
if you don't have any knowledge related to The Domain you are working it means
2:03
to The Domain you are working it means
2:03
to The Domain you are working it means it is not just about you it is about the
2:06
it is not just about you it is about the
2:06
it is not just about you it is about the team because the team may not know about
2:08
team because the team may not know about
2:09
team because the team may not know about the domain domain is in you there is no
2:12
the domain domain is in you there is no
2:12
the domain domain is in you there is no other solution for this domain and
2:14
other solution for this domain and
2:14
other solution for this domain and nobody knows about this domain so it is
2:16
nobody knows about this domain so it is
2:16
nobody knows about this domain so it is completely okay to apply domain driven
2:19
completely okay to apply domain driven
2:19
completely okay to apply domain driven design and also if you have a an MVP of
2:23
design and also if you have a an MVP of
2:23
design and also if you have a an MVP of your application but you know that in
2:25
your application but you know that in
2:25
your application but you know that in the future there will be a lot of
2:27
the future there will be a lot of
2:27
the future there will be a lot of changes it means you able to apply
2:31
changes it means you able to apply
2:31
changes it means you able to apply domain driving design but when not to
2:34
domain driving design but when not to
2:34
domain driving design but when not to apply domain driving design if you have
2:36
apply domain driving design if you have
2:36
apply domain driving design if you have simple domain like the crowd-based
2:39
simple domain like the crowd-based
2:39
simple domain like the crowd-based application or also if you have 20 maybe
2:43
application or also if you have 20 maybe
2:43
application or also if you have 20 maybe 30 40 use cases and just a Define at
2:47
30 40 use cases and just a Define at
2:47
30 40 use cases and just a Define at static use cases there is no changes
2:50
static use cases there is no changes
2:50
static use cases there is no changes maybe in the future or small changes
2:53
maybe in the future or small changes
2:53
maybe in the future or small changes domain is really simple there is no need
2:55
domain is really simple there is no need
2:55
domain is really simple there is no need to apply domain driven Design This is
2:58
to apply domain driven Design This is
2:58
to apply domain driven Design This is where we are applying domain driven
2:59
where we are applying domain driven
2:59
where we are applying domain driven design design and under these conditions
3:02
design design and under these conditions
3:02
design design and under these conditions we should not apply domain during
3:05
we should not apply domain during
3:05
we should not apply domain during design and I want to touch the fact that
3:10
design and I want to touch the fact that
3:10
design and I want to touch the fact that domain driving design is not a design
3:13
domain driving design is not a design
3:13
domain driving design is not a design pattern we should understand this before
3:15
pattern we should understand this before
3:15
pattern we should understand this before moving forward because in many articles
3:18
moving forward because in many articles
3:18
moving forward because in many articles in many posts I realized that they are
3:21
in many posts I realized that they are
3:21
in many posts I realized that they are sharing some information related DD and
3:24
sharing some information related DD and
3:24
sharing some information related DD and they are defining it as a design pattern
3:27
they are defining it as a design pattern
3:27
they are defining it as a design pattern DDD is not a design pattern d DD is not
3:31
DDD is not a design pattern d DD is not
3:31
DDD is not a design pattern d DD is not architectural pattern DDD is not
3:33
architectural pattern DDD is not
3:33
architectural pattern DDD is not architectural style DDD is not a
3:36
architectural style DDD is not a
3:36
architectural style DDD is not a technology D also is not about coding
3:41
technology D also is not about coding
3:41
technology D also is not about coding technique okay so before moving forward
3:46
technique okay so before moving forward
3:46
technique okay so before moving forward let's try to understand the core concept
3:49
let's try to understand the core concept
3:49
let's try to understand the core concept of domain driving design when we build a
3:53
of domain driving design when we build a
3:53
of domain driving design when we build a solution when we build a project uh the
3:57
solution when we build a project uh the
3:57
solution when we build a project uh the building process is not just about about
4:00
building process is not just about about
4:00
building process is not just about about coding we have some requirements we have
4:02
coding we have some requirements we have
4:02
coding we have some requirements we have business guys uh project managers
4:05
business guys uh project managers
4:06
business guys uh project managers business analytics product owners they
4:08
business analytics product owners they
4:08
business analytics product owners they are also a main building blocks of our
4:12
are also a main building blocks of our
4:12
are also a main building blocks of our solution because they are providing the
4:14
solution because they are providing the
4:14
solution because they are providing the related information about the business
4:17
related information about the business
4:17
related information about the business and we are developers working on the
4:19
and we are developers working on the
4:19
and we are developers working on the implementation side so we are on the
4:23
implementation side so we are on the
4:23
implementation side so we are on the same sheap with our business
4:27
same sheap with our business
4:27
same sheap with our business people but unfortunately ly in a
4:31
people but unfortunately ly in a
4:31
people but unfortunately ly in a classical manner we are using different
4:34
classical manner we are using different
4:34
classical manner we are using different languages developers use complet
4:37
languages developers use complet
4:37
languages developers use complet different language like design patterns
4:39
different language like design patterns
4:39
different language like design patterns architectural Styles I don't know the
4:41
architectural Styles I don't know the
4:41
architectural Styles I don't know the service layer repository Etc controller
4:44
service layer repository Etc controller
4:44
service layer repository Etc controller Services uh proxies Etc and business
4:49
Services uh proxies Etc and business
4:49
Services uh proxies Etc and business people speak completely different
4:51
people speak completely different
4:51
people speak completely different language the problem here is we are
4:54
language the problem here is we are
4:54
language the problem here is we are trying to reach to the same destination
4:57
trying to reach to the same destination
4:57
trying to reach to the same destination but we are speaking completely different
4:59
but we are speaking completely different
4:59
but we are speaking completely different different language how it is possible to
5:02
different language how it is possible to
5:02
different language how it is possible to be on the same sheep and with speaking
5:05
be on the same sheep and with speaking
5:05
be on the same sheep and with speaking different language to achieve the same
5:08
different language to achieve the same
5:08
different language to achieve the same goal this is where we are applying
5:10
goal this is where we are applying
5:10
goal this is where we are applying domain driven design in our domain
5:12
domain driven design in our domain
5:12
domain driven design in our domain driven design um I think one of the
5:15
driven design um I think one of the
5:15
driven design um I think one of the greatest invention from Eric Evans is
5:18
greatest invention from Eric Evans is
5:18
greatest invention from Eric Evans is ubiquitous language this ubiquitous
5:20
ubiquitous language this ubiquitous
5:20
ubiquitous language this ubiquitous language yeah of course we have some
5:22
language yeah of course we have some
5:22
language yeah of course we have some slides related to ubiquitous language
5:24
slides related to ubiquitous language
5:24
slides related to ubiquitous language but this is the core for our session so
5:27
but this is the core for our session so
5:27
but this is the core for our session so I decided to explain it a bit earlier so
5:29
I decided to explain it a bit earlier so
5:30
I decided to explain it a bit earlier so in this case we should speak the same
5:32
in this case we should speak the same
5:32
in this case we should speak the same language because when you talk to
5:35
language because when you talk to
5:35
language because when you talk to business you are speaking in a different
5:38
business you are speaking in a different
5:38
business you are speaking in a different language but when you apply start coding
5:41
language but when you apply start coding
5:41
language but when you apply start coding you are using completely different
5:43
you are using completely different
5:43
you are using completely different language this is the biggest problem in
5:45
language this is the biggest problem in
5:45
language this is the biggest problem in our implementation process so we are
5:48
our implementation process so we are
5:48
our implementation process so we are losing some information because business
5:50
losing some information because business
5:50
losing some information because business brings some uh information for you and
5:54
brings some uh information for you and
5:54
brings some uh information for you and here we have translation process we are
5:56
here we have translation process we are
5:56
here we have translation process we are translating and unfortunately it is not
5:59
translating and unfortunately it is not
5:59
translating and unfortunately it is not possible to 100% translate all the
6:02
possible to 100% translate all the
6:02
possible to 100% translate all the information so we are losing the value
6:04
information so we are losing the value
6:04
information so we are losing the value of this uh business sentences here okay
6:08
of this uh business sentences here okay
6:08
of this uh business sentences here okay so we it means we have not 100%
6:11
so we it means we have not 100%
6:11
so we it means we have not 100% information we have 50
6:14
information we have 50
6:14
information we have 50 60% precis information okay and the
6:19
60% precis information okay and the
6:19
60% precis information okay and the problem here is in the future if you
6:21
problem here is in the future if you
6:21
problem here is in the future if you need to change something you are using
6:24
need to change something you are using
6:24
need to change something you are using again two different languages you have
6:26
again two different languages you have
6:26
again two different languages you have your own coding language I'm talking
6:28
your own coding language I'm talking
6:28
your own coding language I'm talking about from the Developers perspective
6:30
about from the Developers perspective
6:30
about from the Developers perspective you are using uh like completely
6:33
you are using uh like completely
6:33
you are using uh like completely different language you are mapping your
6:34
different language you are mapping your
6:34
different language you are mapping your coding to business language okay and
6:37
coding to business language okay and
6:37
coding to business language okay and after getting information you are
6:39
after getting information you are
6:39
after getting information you are translating it into your code so you
6:41
translating it into your code so you
6:41
translating it into your code so you have uh let's say two times translation
6:45
have uh let's say two times translation
6:45
have uh let's say two times translation process this is the biggest problem when
6:47
process this is the biggest problem when
6:47
process this is the biggest problem when we develop our
6:49
we develop our
6:49
we develop our application and long story short long
6:52
application and long story short long
6:52
application and long story short long story short domain Dr in design as we
6:55
story short domain Dr in design as we
6:55
story short domain Dr in design as we mentioned is not about design parents
6:57
mentioned is not about design parents
6:57
mentioned is not about design parents design principles is about software
6:59
design principles is about software
6:59
design principles is about software development approach DDD is a software
7:02
development approach DDD is a software
7:02
development approach DDD is a software development methodology software
7:04
development methodology software
7:04
development methodology software development approach DDD helps us to
7:08
development approach DDD helps us to
7:08
development approach DDD helps us to gain centralized business knowledge it
7:10
gain centralized business knowledge it
7:10
gain centralized business knowledge it means when uh business brings some
7:13
means when uh business brings some
7:13
means when uh business brings some information there is no need to trans no
7:15
information there is no need to trans no
7:15
information there is no need to trans no need to translate this information to
7:17
need to translate this information to
7:17
need to translate this information to developers language so we are using the
7:20
developers language so we are using the
7:20
developers language so we are using the same language and it means developers
7:22
same language and it means developers
7:22
same language and it means developers help business to improve and also
7:26
help business to improve and also
7:26
help business to improve and also business help developers the solution
7:30
business help developers the solution
7:30
business help developers the solution to have real language so the business
7:34
to have real language so the business
7:34
to have real language so the business language is the same as your coding
7:37
language is the same as your coding
7:37
language is the same as your coding language the same as your methods same
7:40
language the same as your methods same
7:40
language the same as your methods same as your classes you apply you implement
7:43
as your classes you apply you implement
7:43
as your classes you apply you implement in your project level okay so domain R
7:47
in your project level okay so domain R
7:47
in your project level okay so domain R design as Veron mentioned it is firstly
7:51
design as Veron mentioned it is firstly
7:51
design as Veron mentioned it is firstly is not about technology it is about
7:53
is not about technology it is about
7:53
is not about technology it is about learning discussing bringing business
7:57
learning discussing bringing business
7:57
learning discussing bringing business value because um you are sitting Vis
7:59
value because um you are sitting Vis
7:59
value because um you are sitting Vis your teammates it is not about only
8:02
your teammates it is not about only
8:02
your teammates it is not about only developers testers it is all team like
8:06
developers testers it is all team like
8:06
developers testers it is all team like business analytics product owners you
8:08
business analytics product owners you
8:08
business analytics product owners you are together discussing the business it
8:11
are together discussing the business it
8:11
are together discussing the business it means now developers also know more
8:15
means now developers also know more
8:15
means now developers also know more about business and also business team
8:18
about business and also business team
8:18
about business and also business team now how developers are planning to
8:21
now how developers are planning to
8:21
now how developers are planning to implement stuff and it will be really
8:24
implement stuff and it will be really
8:24
implement stuff and it will be really easy for business people even without
8:27
easy for business people even without
8:27
easy for business people even without learning programming language e easily
8:30
learning programming language e easily
8:30
learning programming language e easily understand the code because the code
8:33
understand the code because the code
8:33
understand the code because the code reflects the business the business uh
8:35
reflects the business the business uh
8:35
reflects the business the business uh language is the same as our code
8:38
language is the same as our code
8:38
language is the same as our code language so business people help to
8:40
language so business people help to
8:41
language so business people help to achieve a better design I mean the uh
8:43
achieve a better design I mean the uh
8:43
achieve a better design I mean the uh technical implementation like designing
8:45
technical implementation like designing
8:45
technical implementation like designing and C JY Etc and also developers with
8:49
and C JY Etc and also developers with
8:49
and C JY Etc and also developers with asking proper and precise questions help
8:53
asking proper and precise questions help
8:53
asking proper and precise questions help to understand business well so you are
8:57
to understand business well so you are
8:57
to understand business well so you are asking relevant questions to business of
9:00
asking relevant questions to business of
9:00
asking relevant questions to business of course business also uh doesn't now all
9:03
course business also uh doesn't now all
9:03
course business also uh doesn't now all related the problem domain and you are
9:07
related the problem domain and you are
9:07
related the problem domain and you are helping business people to learn more if
9:10
helping business people to learn more if
9:10
helping business people to learn more if they learn more it means they will
9:12
they learn more it means they will
9:12
they learn more it means they will reflect their knowledge to your project
9:15
reflect their knowledge to your project
9:15
reflect their knowledge to your project so you are working together you are
9:17
so you are working together you are
9:17
so you are working together you are using the same language you are on the
9:19
using the same language you are on the
9:20
using the same language you are on the same ship and trying to achieve the same
9:23
same ship and trying to achieve the same
9:23
same ship and trying to achieve the same goal together so we have there
9:26
goal together so we have there
9:26
goal together so we have there translation between our business and
9:29
translation between our business and
9:29
translation between our business and velers this is the ubiquities language
9:32
velers this is the ubiquities language
9:32
velers this is the ubiquities language okay
9:34
okay
9:34
okay and as I mentioned business and
9:36
and as I mentioned business and
9:36
and as I mentioned business and developer team use the same ubiquitous
9:39
developer team use the same ubiquitous
9:39
developer team use the same ubiquitous language as one Bon mentioned uh we have
9:42
language as one Bon mentioned uh we have
9:43
language as one Bon mentioned uh we have design it is a code a code is a design
9:46
design it is a code a code is a design
9:46
design it is a code a code is a design this is a great definition by the way
9:49
this is a great definition by the way
9:49
this is a great definition by the way and domain ring design helps us to apply
9:52
and domain ring design helps us to apply
9:52
and domain ring design helps us to apply the agile principles iterative
9:55
the agile principles iterative
9:55
the agile principles iterative development that's completely okay for
9:57
development that's completely okay for
9:57
development that's completely okay for modern days and also domain driven
10:00
modern days and also domain driven
10:00
modern days and also domain driven design helps uh domain driven design
10:02
design helps uh domain driven design
10:02
design helps uh domain driven design brings strategic and tactical patterns
10:06
brings strategic and tactical patterns
10:06
brings strategic and tactical patterns to the table so you have strategical
10:08
to the table so you have strategical
10:08
to the table so you have strategical patterns you have tactical patterns DDD
10:11
patterns you have tactical patterns DDD
10:11
patterns you have tactical patterns DDD is not just about strategical and
10:12
is not just about strategical and
10:12
is not just about strategical and tactical patterns as we mentioned DDD is
10:15
tactical patterns as we mentioned DDD is
10:15
tactical patterns as we mentioned DDD is for most about learning discussing
10:17
for most about learning discussing
10:17
for most about learning discussing bringing business value using the same
10:20
bringing business value using the same
10:20
bringing business value using the same language for most and then applying all
10:24
language for most and then applying all
10:24
language for most and then applying all this stuff in your strategic level for
10:27
this stuff in your strategic level for
10:27
this stuff in your strategic level for your strategic patterns and and then uh
10:30
your strategic patterns and and then uh
10:30
your strategic patterns and and then uh from the implementation perspective
10:32
from the implementation perspective
10:32
from the implementation perspective apply tactical patterns okay so now
10:36
apply tactical patterns okay so now
10:36
apply tactical patterns okay so now let's focus on our strategic patterns
10:40
let's focus on our strategic patterns
10:40
let's focus on our strategic patterns first as a developer I now we really
10:43
first as a developer I now we really
10:43
first as a developer I now we really don't love to apply we really don't love
10:47
don't love to apply we really don't love
10:47
don't love to apply we really don't love to talk much we want to code but this is
10:51
to talk much we want to code but this is
10:51
to talk much we want to code but this is not applicable in domain design because
10:54
not applicable in domain design because
10:54
not applicable in domain design because you should participate in a business
10:56
you should participate in a business
10:56
you should participate in a business process you should understand business
10:58
process you should understand business
10:58
process you should understand business process you should ask questions because
11:01
process you should ask questions because
11:01
process you should ask questions because if you don't know business well it is
11:03
if you don't know business well it is
11:03
if you don't know business well it is not possible to reflect it to your
11:05
not possible to reflect it to your
11:05
not possible to reflect it to your project this is really important so in
11:08
project this is really important so in
11:08
project this is really important so in our strategic pars box we have
11:11
our strategic pars box we have
11:11
our strategic pars box we have ubiquitous language we have bounded
11:14
ubiquitous language we have bounded
11:14
ubiquitous language we have bounded context and we have context map and they
11:17
context and we have context map and they
11:17
context and we have context map and they are the main building blocks of of
11:19
are the main building blocks of of
11:19
are the main building blocks of of course we also have core domain but um
11:21
course we also have core domain but um
11:21
course we also have core domain but um anyway we'll talk about it in our
11:23
anyway we'll talk about it in our
11:23
anyway we'll talk about it in our bounded context uh section so what is
11:27
bounded context uh section so what is
11:27
bounded context uh section so what is strategic parent so in domain design we
11:31
strategic parent so in domain design we
11:31
strategic parent so in domain design we have strategic parents and they are
11:33
have strategic parents and they are
11:33
have strategic parents and they are blueprints for structuring and
11:35
blueprints for structuring and
11:36
blueprints for structuring and organizing complex software systems
11:39
organizing complex software systems
11:39
organizing complex software systems aligned with business domain it means
11:42
aligned with business domain it means
11:42
aligned with business domain it means you first need to understand the
11:44
you first need to understand the
11:44
you first need to understand the business the problem space and start to
11:48
business the problem space and start to
11:48
business the problem space and start to implement move it to the solution space
11:51
implement move it to the solution space
11:51
implement move it to the solution space using bounded context you should talk
11:54
using bounded context you should talk
11:54
using bounded context you should talk much you should understand your core
11:56
much you should understand your core
11:56
much you should understand your core domain you should talk to business
11:59
domain you should talk to business
11:59
domain you should talk to business people to understand more about business
12:01
people to understand more about business
12:01
people to understand more about business and you should apply you should speak in
12:05
and you should apply you should speak in
12:05
and you should apply you should speak in a same language and you should try to
12:08
a same language and you should try to
12:08
a same language and you should try to apply the speak spoken language to your
12:12
apply the speak spoken language to your
12:12
apply the speak spoken language to your project first things first uh the main
12:15
project first things first uh the main
12:15
project first things first uh the main building block of our uh uh strategic
12:19
building block of our uh uh strategic
12:19
building block of our uh uh strategic pattern is of course y this language so
12:23
pattern is of course y this language so
12:23
pattern is of course y this language so ubiquitous language as waron mentioned a
12:25
ubiquitous language as waron mentioned a
12:25
ubiquitous language as waron mentioned a shared Tim language ubiquitous language
12:28
shared Tim language ubiquitous language
12:28
shared Tim language ubiquitous language helps us to capture the concepts terms
12:33
helps us to capture the concepts terms
12:33
helps us to capture the concepts terms from core business domain so you have
12:36
from core business domain so you have
12:36
from core business domain so you have all the related terms Concepts
12:39
all the related terms Concepts
12:39
all the related terms Concepts Expressions verbs the related keywords
12:43
Expressions verbs the related keywords
12:43
Expressions verbs the related keywords let's say uh and you you will analyze
12:47
let's say uh and you you will analyze
12:47
let's say uh and you you will analyze them and you will discuss them with
12:50
them and you will discuss them with
12:50
them and you will discuss them with business people and you will gain the
12:53
business people and you will gain the
12:53
business people and you will gain the exact words and then you will be able to
12:57
exact words and then you will be able to
12:57
exact words and then you will be able to apply to create stuff related to these
13:00
apply to create stuff related to these
13:00
apply to create stuff related to these expressions and words okay ubiquitous
13:04
expressions and words okay ubiquitous
13:04
expressions and words okay ubiquitous language is a language that business and
13:06
language is a language that business and
13:06
language is a language that business and developer teams used to achieve the same
13:09
developer teams used to achieve the same
13:09
developer teams used to achieve the same goal we already talked about it when we
13:11
goal we already talked about it when we
13:11
goal we already talked about it when we describe the ship uh presentation uh
13:15
describe the ship uh presentation uh
13:15
describe the ship uh presentation uh this utus language uh should be
13:17
this utus language uh should be
13:17
this utus language uh should be developed by the team of course in our
13:19
developed by the team of course in our
13:19
developed by the team of course in our strategic design we have bounded
13:21
strategic design we have bounded
13:21
strategic design we have bounded contexts okay and this ubiquitous
13:24
contexts okay and this ubiquitous
13:24
contexts okay and this ubiquitous language should be applicable only
13:26
language should be applicable only
13:26
language should be applicable only inside one bounded context we'll talk
13:29
inside one bounded context we'll talk
13:29
inside one bounded context we'll talk about bonded context a bit later and
13:33
about bonded context a bit later and
13:33
about bonded context a bit later and ubiquitous language is about capturing
13:35
ubiquitous language is about capturing
13:35
ubiquitous language is about capturing the concepts terms of specific core
13:37
the concepts terms of specific core
13:37
the concepts terms of specific core business domain and this is valid only
13:40
business domain and this is valid only
13:40
business domain and this is valid only inside of a bounded context we already
13:42
inside of a bounded context we already
13:42
inside of a bounded context we already mentioned about it and also it helps us
13:44
mentioned about it and also it helps us
13:44
mentioned about it and also it helps us to create valuable business domain model
13:46
to create valuable business domain model
13:47
to create valuable business domain model so uh domain domain design is about uh
13:50
so uh domain domain design is about uh
13:50
so uh domain domain design is about uh creating artifacts in terms of domain
13:53
creating artifacts in terms of domain
13:53
creating artifacts in terms of domain models so you are designing domain
13:57
models so you are designing domain
13:57
models so you are designing domain models and the first step is is to
14:00
models and the first step is is to
14:00
models and the first step is is to understand your business and to apply to
14:02
understand your business and to apply to
14:03
understand your business and to apply to gain the valuable ubiquitous language to
14:05
gain the valuable ubiquitous language to
14:05
gain the valuable ubiquitous language to apply it to create a domain model based
14:08
apply it to create a domain model based
14:08
apply it to create a domain model based on ubiquitous language okay and
14:11
on ubiquitous language okay and
14:11
on ubiquitous language okay and ubiquitous language uh serves a design
14:15
ubiquitous language uh serves a design
14:15
ubiquitous language uh serves a design so how to capture uus language yeah this
14:18
so how to capture uus language yeah this
14:18
so how to capture uus language yeah this is also really important so you can use
14:21
is also really important so you can use
14:21
is also really important so you can use uh different glossaries for example in
14:24
uh different glossaries for example in
14:24
uh different glossaries for example in your domain you may have multiple
14:27
your domain you may have multiple
14:27
your domain you may have multiple synonyms you will definitely have
14:29
synonyms you will definitely have
14:29
synonyms you will definitely have multiple synonyms for the given words
14:31
multiple synonyms for the given words
14:31
multiple synonyms for the given words let's say and you need to discuss it
14:34
let's say and you need to discuss it
14:34
let's say and you need to discuss it with your team to select only one and
14:37
with your team to select only one and
14:37
with your team to select only one and all team members should use the same
14:39
all team members should use the same
14:39
all team members should use the same term every discussion process you can
14:42
term every discussion process you can
14:43
term every discussion process you can also use some drawings of your domain
14:45
also use some drawings of your domain
14:45
also use some drawings of your domain elements you can draw some pictures of
14:47
elements you can draw some pictures of
14:47
elements you can draw some pictures of your uh business domain models and also
14:52
your uh business domain models and also
14:52
your uh business domain models and also you can create a different
14:53
you can create a different
14:53
you can create a different documentations that will help you to
14:56
documentations that will help you to
14:56
documentations that will help you to grab the related information from the
14:58
grab the related information from the
14:58
grab the related information from the business to to capture the information
15:00
business to to capture the information
15:00
business to to capture the information from the business and after that you
15:03
from the business and after that you
15:03
from the business and after that you need to talk to domain experts the
15:06
need to talk to domain experts the
15:06
need to talk to domain experts the domain expert is a guy who knows about
15:09
domain expert is a guy who knows about
15:09
domain expert is a guy who knows about domain more than you let's say it can be
15:13
domain more than you let's say it can be
15:13
domain more than you let's say it can be uh other Senor developer who works more
15:16
uh other Senor developer who works more
15:16
uh other Senor developer who works more than I don't know four five years in
15:18
than I don't know four five years in
15:18
than I don't know four five years in this company or business analytics
15:21
this company or business analytics
15:21
this company or business analytics product owners so there is no special
15:23
product owners so there is no special
15:23
product owners so there is no special position like domain experts it depends
15:26
position like domain experts it depends
15:26
position like domain experts it depends from the knowledge of the teammate
15:29
from the knowledge of the teammate
15:29
from the knowledge of the teammate come and you need to try to understand
15:32
come and you need to try to understand
15:32
come and you need to try to understand the core domain as much as possible and
15:35
the core domain as much as possible and
15:35
the core domain as much as possible and then after discussing after analyzing
15:38
then after discussing after analyzing
15:38
then after discussing after analyzing all this stuff you are deciding to use
15:41
all this stuff you are deciding to use
15:41
all this stuff you are deciding to use for example these five terms um like I
15:45
for example these five terms um like I
15:45
for example these five terms um like I don't know them let's say ship person
15:48
don't know them let's say ship person
15:48
don't know them let's say ship person you maybe order category Etc so you are
15:54
you maybe order category Etc so you are
15:54
you maybe order category Etc so you are defining all this stuff you are
15:55
defining all this stuff you are
15:55
defining all this stuff you are discussing and you are selecting the
15:59
discussing and you are selecting the
15:59
discussing and you are selecting the proper words depending from your bounded
16:02
proper words depending from your bounded
16:02
proper words depending from your bounded context this is a simple gloser for
16:05
context this is a simple gloser for
16:05
context this is a simple gloser for example we have product so you say we
16:08
example we have product so you say we
16:08
example we have product so you say we have product and we have exact
16:10
have product and we have exact
16:10
have product and we have exact definition there should be crystal clear
16:13
definition there should be crystal clear
16:13
definition there should be crystal clear as beron mayor mentioned there should be
16:15
as beron mayor mentioned there should be
16:15
as beron mayor mentioned there should be a clister clear definition for your
16:18
a clister clear definition for your
16:18
a clister clear definition for your words like product a tangible item
16:21
words like product a tangible item
16:21
words like product a tangible item available for purchase order a
16:23
available for purchase order a
16:23
available for purchase order a customer's request to purchase one or
16:24
customer's request to purchase one or
16:24
customer's request to purchase one or more products the customer inventory
16:27
more products the customer inventory
16:27
more products the customer inventory shopping cart promotions in your
16:29
shopping cart promotions in your
16:29
shopping cart promotions in your glossery you may have multiple synonyms
16:32
glossery you may have multiple synonyms
16:32
glossery you may have multiple synonyms for these elements but at the end you
16:35
for these elements but at the end you
16:35
for these elements but at the end you should pick only one and you should
16:37
should pick only one and you should
16:37
should pick only one and you should start to use this one without it is
16:40
start to use this one without it is
16:40
start to use this one without it is synonym every time start from A to Z
16:44
synonym every time start from A to Z
16:44
synonym every time start from A to Z from starting to the end
16:46
from starting to the end
16:46
from starting to the end process okay now let's talk about
16:49
process okay now let's talk about
16:49
process okay now let's talk about bounded context what is a bounded
16:51
bounded context what is a bounded
16:51
bounded context what is a bounded context bounded context is uh concept
16:54
context bounded context is uh concept
16:54
context bounded context is uh concept from strategic parent bound context is a
16:56
from strategic parent bound context is a
16:56
from strategic parent bound context is a conceptual boundary uh where your domain
17:00
conceptual boundary uh where your domain
17:00
conceptual boundary uh where your domain model is valid so you have a domain
17:02
model is valid so you have a domain
17:02
model is valid so you have a domain model let's say we'll know about the
17:04
model let's say we'll know about the
17:04
model let's say we'll know about the models but we'll Define the domain model
17:06
models but we'll Define the domain model
17:06
models but we'll Define the domain model a bit later so we have the domain model
17:09
a bit later so we have the domain model
17:09
a bit later so we have the domain model is it is let's say properties and
17:12
is it is let's say properties and
17:12
is it is let's say properties and methods okay and this domain model is
17:15
methods okay and this domain model is
17:15
methods okay and this domain model is valid only in this context this context
17:18
valid only in this context this context
17:18
valid only in this context this context defines the uh validity of our domain
17:21
defines the uh validity of our domain
17:21
defines the uh validity of our domain model okay and this is a conceptual
17:24
model okay and this is a conceptual
17:24
model okay and this is a conceptual Bounder bounded context is a solution
17:26
Bounder bounded context is a solution
17:26
Bounder bounded context is a solution space artifact we'll also talk about it
17:29
space artifact we'll also talk about it
17:29
space artifact we'll also talk about it boundary context is a conceptual
17:30
boundary context is a conceptual
17:30
boundary context is a conceptual boundary where a domain model is
17:32
boundary where a domain model is
17:32
boundary where a domain model is applicable from one on again we have
17:36
applicable from one on again we have
17:36
applicable from one on again we have tactical patterns and we are applying
17:39
tactical patterns and we are applying
17:39
tactical patterns and we are applying this tactical patterns inside our
17:41
this tactical patterns inside our
17:41
this tactical patterns inside our bounded context so in domainer design
17:43
bounded context so in domainer design
17:43
bounded context so in domainer design there is there is no one single solution
17:46
there is there is no one single solution
17:46
there is there is no one single solution okay let's start domain dur design okay
17:48
okay let's start domain dur design okay
17:48
okay let's start domain dur design okay let's create all these domain models all
17:50
let's create all these domain models all
17:50
let's create all these domain models all these infrastructure Etc no you have
17:53
these infrastructure Etc no you have
17:53
these infrastructure Etc no you have bounded context so it means you have a
17:55
bounded context so it means you have a
17:55
bounded context so it means you have a big problem you are dividing it into
17:57
big problem you are dividing it into
17:57
big problem you are dividing it into smaller ones this smaller ones is going
17:59
smaller ones this smaller ones is going
17:59
smaller ones this smaller ones is going to be your bounded context okay this is
18:02
to be your bounded context okay this is
18:02
to be your bounded context okay this is like your microservice infrastructure
18:04
like your microservice infrastructure
18:04
like your microservice infrastructure okay your you have a smaller
18:06
okay your you have a smaller
18:06
okay your you have a smaller microservices every microservices in
18:08
microservices every microservices in
18:08
microservices every microservices in this case let's say match you to bounded
18:10
this case let's say match you to bounded
18:10
this case let's say match you to bounded context so it means you have a big
18:12
context so it means you have a big
18:12
context so it means you have a big problem you are dividing into it into
18:15
problem you are dividing into it into
18:15
problem you are dividing into it into smaller ones and they are going to be
18:16
smaller ones and they are going to be
18:16
smaller ones and they are going to be your bounded context in your bounded
18:18
your bounded context in your bounded
18:19
your bounded context in your bounded context every bounded context is uh an
18:21
context every bounded context is uh an
18:21
context every bounded context is uh an independent item so you can apply
18:24
independent item so you can apply
18:24
independent item so you can apply different programming language you can
18:25
different programming language you can
18:25
different programming language you can apply different technology you can apply
18:27
apply different technology you can apply
18:27
apply different technology you can apply different architecture and different
18:29
different architecture and different
18:29
different architecture and different team working on this bounded context
18:31
team working on this bounded context
18:31
team working on this bounded context like in a microservice development
18:33
like in a microservice development
18:33
like in a microservice development process okay so that's why domain driven
18:35
process okay so that's why domain driven
18:35
process okay so that's why domain driven design uh also matches with microservice
18:38
design uh also matches with microservice
18:38
design uh also matches with microservice development so we can host bounded
18:41
development so we can host bounded
18:41
development so we can host bounded context using different architecture you
18:43
context using different architecture you
18:43
context using different architecture you can use hexagonal architecture even
18:44
can use hexagonal architecture even
18:44
can use hexagonal architecture even driven service oriented I know now rest
18:46
driven service oriented I know now rest
18:46
driven service oriented I know now rest for example you have uh four bounded
18:49
for example you have uh four bounded
18:49
for example you have uh four bounded context you may apply a layered
18:51
context you may apply a layered
18:51
context you may apply a layered architecture for one um the clean
18:53
architecture for one um the clean
18:53
architecture for one um the clean architecture 41 I don't know the service
18:55
architecture 41 I don't know the service
18:55
architecture 41 I don't know the service oriented 41 even 41 so that's complete
18:58
oriented 41 even 41 so that's complete
18:58
oriented 41 even 41 so that's complete location you don't strict to one
19:00
location you don't strict to one
19:00
location you don't strict to one architecture this is the the really a
19:03
architecture this is the the really a
19:04
architecture this is the the really a good side of bounded context also uh the
19:07
good side of bounded context also uh the
19:07
good side of bounded context also uh the ubiquitous language also valid inside
19:10
ubiquitous language also valid inside
19:10
ubiquitous language also valid inside our bounded context it means we have
19:12
our bounded context it means we have
19:12
our bounded context it means we have onetoone relation between bounded
19:14
onetoone relation between bounded
19:14
onetoone relation between bounded context and ubiquitous language you
19:16
context and ubiquitous language you
19:16
context and ubiquitous language you cannot use the same ubiquitous language
19:18
cannot use the same ubiquitous language
19:18
cannot use the same ubiquitous language for multiple bounded context uh for
19:20
for multiple bounded context uh for
19:20
for multiple bounded context uh for example if you define the ubiquitous
19:21
example if you define the ubiquitous
19:21
example if you define the ubiquitous language it is only valid in one bounded
19:24
language it is only valid in one bounded
19:24
language it is only valid in one bounded context for the different bounded
19:26
context for the different bounded
19:26
context for the different bounded context you may use the same terms but
19:29
context you may use the same terms but
19:29
context you may use the same terms but they are completely they are meaning
19:31
they are completely they are meaning
19:31
they are completely they are meaning completely different for example in one
19:33
completely different for example in one
19:33
completely different for example in one context we have account in another
19:36
context we have account in another
19:36
context we have account in another context we have account but they are
19:37
context we have account but they are
19:38
context we have account but they are completely different domain models
19:40
completely different domain models
19:40
completely different domain models because they are isolated with bounded
19:42
because they are isolated with bounded
19:42
because they are isolated with bounded context so bounded context is a solution
19:44
context so bounded context is a solution
19:44
context so bounded context is a solution space element we have problem space we
19:47
space element we have problem space we
19:47
space element we have problem space we have solution space if you read
19:48
have solution space if you read
19:48
have solution space if you read different books related to domain during
19:52
different books related to domain during
19:52
different books related to domain during design you realize that most of them are
19:54
design you realize that most of them are
19:54
design you realize that most of them are talking about problem space solution
19:56
talking about problem space solution
19:56
talking about problem space solution space in our problem space we have sub
19:58
space in our problem space we have sub
19:58
space in our problem space we have sub in our solution space we have bounded
20:01
in our solution space we have bounded
20:01
in our solution space we have bounded context because in subdomain we are
20:02
context because in subdomain we are
20:02
context because in subdomain we are trying to grab more information about
20:05
trying to grab more information about
20:05
trying to grab more information about business we are trying to understand we
20:07
business we are trying to understand we
20:07
business we are trying to understand we are trying to learn the complexity we
20:10
are trying to learn the complexity we
20:10
are trying to learn the complexity we are not applying anything any
20:12
are not applying anything any
20:12
are not applying anything any architecture in our problem space but in
20:15
architecture in our problem space but in
20:15
architecture in our problem space but in our solution space we are starting to
20:18
our solution space we are starting to
20:18
our solution space we are starting to apply uh all these architectural Styles
20:21
apply uh all these architectural Styles
20:21
apply uh all these architectural Styles all these architectural patterns
20:22
all these architectural patterns
20:22
all these architectural patterns Technologies Etc so bounded context is
20:25
Technologies Etc so bounded context is
20:25
Technologies Etc so bounded context is related to solution space it is not a
20:27
related to solution space it is not a
20:27
related to solution space it is not a problem space element that the problem
20:29
problem space element that the problem
20:29
problem space element that the problem space element is
20:31
space element is
20:31
space element is subdomain and bounded context is about
20:33
subdomain and bounded context is about
20:33
subdomain and bounded context is about dividing a big problem into smaller ones
20:35
dividing a big problem into smaller ones
20:36
dividing a big problem into smaller ones already discussed about it and uh of
20:38
already discussed about it and uh of
20:38
already discussed about it and uh of course bounded context is
20:40
course bounded context is
20:40
course bounded context is architecturally neutral
20:42
architecturally neutral
20:42
architecturally neutral so unfortunately our bounded context had
20:46
so unfortunately our bounded context had
20:46
so unfortunately our bounded context had a complex relationship with subdomain so
20:49
a complex relationship with subdomain so
20:49
a complex relationship with subdomain so it is not always possible to we are of
20:52
it is not always possible to we are of
20:52
it is not always possible to we are of course striving to have onetoone
20:54
course striving to have onetoone
20:54
course striving to have onetoone relation between our subdomain
20:56
relation between our subdomain
20:56
relation between our subdomain subdomains and bounded context but
20:58
subdomains and bounded context but
20:58
subdomains and bounded context but unfortunately is mostly not possible
21:00
unfortunately is mostly not possible
21:00
unfortunately is mostly not possible because you may have one bounded context
21:03
because you may have one bounded context
21:03
because you may have one bounded context that covers multiple subdomains or one
21:05
that covers multiple subdomains or one
21:05
that covers multiple subdomains or one subdomain that covers multiple bounded
21:07
subdomain that covers multiple bounded
21:07
subdomain that covers multiple bounded context but in our core domain we are
21:09
context but in our core domain we are
21:10
context but in our core domain we are trying to a one toone relationship
21:12
trying to a one toone relationship
21:12
trying to a one toone relationship between bounded context and subdomain
21:14
between bounded context and subdomain
21:14
between bounded context and subdomain but in
21:15
but in
21:15
but in our generic subdomain um in sometimes it
21:20
our generic subdomain um in sometimes it
21:20
our generic subdomain um in sometimes it is not possible so this is a simple
21:22
is not possible so this is a simple
21:22
is not possible so this is a simple example of our domain so our domain from
21:25
example of our domain so our domain from
21:26
example of our domain so our domain from the Enterprise architecture perspective
21:27
the Enterprise architecture perspective
21:27
the Enterprise architecture perspective we have domain that divided into
21:29
we have domain that divided into
21:29
we have domain that divided into subdomains and for example in core
21:31
subdomains and for example in core
21:31
subdomains and for example in core domain here we have one bounded context
21:33
domain here we have one bounded context
21:33
domain here we have one bounded context you said so but in our another subdomain
21:36
you said so but in our another subdomain
21:36
you said so but in our another subdomain we have two bounded contexts yeah and
21:38
we have two bounded contexts yeah and
21:38
we have two bounded contexts yeah and also the given bounded context that
21:40
also the given bounded context that
21:40
also the given bounded context that match to different even three different
21:43
match to different even three different
21:43
match to different even three different uh subdomains so it is uh depending from
21:46
uh subdomains so it is uh depending from
21:46
uh subdomains so it is uh depending from your domain complexity from your domain
21:48
your domain complexity from your domain
21:48
your domain complexity from your domain of
21:49
of
21:49
of course and let's talk about context map
21:52
course and let's talk about context map
21:52
course and let's talk about context map so we have bounded contexts okay and um
21:56
so we have bounded contexts okay and um
21:56
so we have bounded contexts okay and um what to do in this case so you have
21:57
what to do in this case so you have
21:58
what to do in this case so you have different bound context and it means
22:00
different bound context and it means
22:00
different bound context and it means let's compare it like this so you have
22:02
let's compare it like this so you have
22:02
let's compare it like this so you have imagine like you have multiple
22:04
imagine like you have multiple
22:04
imagine like you have multiple microservices and one microservice
22:07
microservices and one microservice
22:07
microservices and one microservice doesn't mean a lot if it is not
22:09
doesn't mean a lot if it is not
22:09
doesn't mean a lot if it is not interacting with other microservices so
22:12
interacting with other microservices so
22:12
interacting with other microservices so in domain Drivin design perspective when
22:14
in domain Drivin design perspective when
22:14
in domain Drivin design perspective when you have a bounded context that doesn't
22:16
you have a bounded context that doesn't
22:16
you have a bounded context that doesn't interact with others doesn't much value
22:19
interact with others doesn't much value
22:19
interact with others doesn't much value so they should interact with each other
22:22
so they should interact with each other
22:22
so they should interact with each other so context map helps us to have
22:25
so context map helps us to have
22:25
so context map helps us to have communication between our bounded
22:27
communication between our bounded
22:27
communication between our bounded contexts it is really
22:29
contexts it is really
22:29
contexts it is really having relationship between bounded
22:31
having relationship between bounded
22:31
having relationship between bounded contexts so uh context map is a
22:33
contexts so uh context map is a
22:33
contexts so uh context map is a strategic pattern um tactical patterns
22:36
strategic pattern um tactical patterns
22:36
strategic pattern um tactical patterns inside uh technical patterns applied
22:38
inside uh technical patterns applied
22:38
inside uh technical patterns applied inside our G bounded context we already
22:41
inside our G bounded context we already
22:41
inside our G bounded context we already talked about it um um this uh bounded
22:45
talked about it um um this uh bounded
22:45
talked about it um um this uh bounded context where talk that this is um
22:48
context where talk that this is um
22:48
context where talk that this is um hosted in uh you can use different um
22:52
hosted in uh you can use different um
22:52
hosted in uh you can use different um architectures like event architecture
22:54
architectures like event architecture
22:54
architectures like event architecture service architecture to apply your um
22:57
service architecture to apply your um
22:57
service architecture to apply your um bounded contexts uh to design your
23:00
bounded contexts uh to design your
23:00
bounded contexts uh to design your bounded context it is completely
23:02
bounded context it is completely
23:02
bounded context it is completely architectural natural and in our context
23:04
architectural natural and in our context
23:04
architectural natural and in our context map we have different uh integrational
23:07
map we have different uh integrational
23:07
map we have different uh integrational and communication relationship between
23:10
and communication relationship between
23:10
and communication relationship between our bounded context let's talk about it
23:12
our bounded context let's talk about it
23:12
our bounded context let's talk about it so uh we have organizational
23:15
so uh we have organizational
23:15
so uh we have organizational integrational patterns like we have
23:17
integrational patterns like we have
23:17
integrational patterns like we have partnership we have shared Kel we have
23:19
partnership we have shared Kel we have
23:19
partnership we have shared Kel we have customer supplier relationship we have
23:21
customer supplier relationship we have
23:21
customer supplier relationship we have confirm Miss anti-corruption open
23:24
confirm Miss anti-corruption open
23:24
confirm Miss anti-corruption open service publish language separate ways
23:26
service publish language separate ways
23:26
service publish language separate ways and big well of mood unfortunately we
23:28
and big well of mood unfortunately we
23:28
and big well of mood unfortunately we don't have enough time to talk much all
23:31
don't have enough time to talk much all
23:31
don't have enough time to talk much all about to talk much about all of them but
23:34
about to talk much about all of them but
23:34
about to talk much about all of them but I will try to cover at least uh two or
23:38
I will try to cover at least uh two or
23:38
I will try to cover at least uh two or three of them so we have partnership
23:40
three of them so we have partnership
23:40
three of them so we have partnership relationship so it means you have to
23:43
relationship so it means you have to
23:43
relationship so it means you have to bounded context they should fail
23:45
bounded context they should fail
23:45
bounded context they should fail together they should succeed together
23:47
together they should succeed together
23:47
together they should succeed together okay they are really dependent with each
23:50
okay they are really dependent with each
23:50
okay they are really dependent with each other we have shared kernel in most
23:52
other we have shared kernel in most
23:52
other we have shared kernel in most cases sh canel is a part of our domain
23:55
cases sh canel is a part of our domain
23:55
cases sh canel is a part of our domain so we are having the generic code like
23:59
so we are having the generic code like
23:59
so we are having the generic code like the related to entities like related to
24:01
the related to entities like related to
24:01
the related to entities like related to our business about value object about
24:04
our business about value object about
24:04
our business about value object about domain uh Services domain events we are
24:07
domain uh Services domain events we are
24:07
domain uh Services domain events we are not moving the infrastructure elements
24:10
not moving the infrastructure elements
24:10
not moving the infrastructure elements to our shared kernel so shared Kel is
24:12
to our shared kernel so shared Kel is
24:12
to our shared kernel so shared Kel is about our business the common usage for
24:15
about our business the common usage for
24:15
about our business the common usage for all our bounded contexts we have a
24:18
all our bounded contexts we have a
24:18
all our bounded contexts we have a customer supplier uh relationship
24:21
customer supplier uh relationship
24:21
customer supplier uh relationship customer supplier means you you have one
24:24
customer supplier means you you have one
24:24
customer supplier means you you have one you have a producer and you have a
24:26
you have a producer and you have a
24:26
you have a producer and you have a consumer and uh for example we have big
24:29
consumer and uh for example we have big
24:29
consumer and uh for example we have big ball of mod uh you can apply big ball of
24:32
ball of mod uh you can apply big ball of
24:32
ball of mod uh you can apply big ball of mod if you have already implemented
24:33
mod if you have already implemented
24:33
mod if you have already implemented application and you need somehow you
24:36
application and you need somehow you
24:36
application and you need somehow you want to somehow isolate it to apply
24:38
want to somehow isolate it to apply
24:38
want to somehow isolate it to apply domain drin design concept and you can
24:41
domain drin design concept and you can
24:41
domain drin design concept and you can wrap all this stuff into a big bow of
24:43
wrap all this stuff into a big bow of
24:43
wrap all this stuff into a big bow of mod and to see it as a separate bounded
24:47
mod and to see it as a separate bounded
24:47
mod and to see it as a separate bounded context
24:48
context
24:48
context okay so this is a simple example so you
24:51
okay so this is a simple example so you
24:51
okay so this is a simple example so you see we have let's say we have three
24:53
see we have let's say we have three
24:53
see we have let's say we have three bounded context and we have open host
24:56
bounded context and we have open host
24:56
bounded context and we have open host service here this is a uh organizational
24:59
service here this is a uh organizational
24:59
service here this is a uh organizational and integrational communication
25:01
and integrational communication
25:01
and integrational communication mechanism and we are applying publisher
25:04
mechanism and we are applying publisher
25:04
mechanism and we are applying publisher language this is also one part of
25:06
language this is also one part of
25:06
language this is also one part of organizational integration parents here
25:09
organizational integration parents here
25:09
organizational integration parents here publish it language so you see we have
25:10
publish it language so you see we have
25:10
publish it language so you see we have open host service we have publish it
25:12
open host service we have publish it
25:12
open host service we have publish it language so we are able to write a raer
25:17
language so we are able to write a raer
25:17
language so we are able to write a raer over our open host service to have
25:20
over our open host service to have
25:20
over our open host service to have separate versions of our context map in
25:24
separate versions of our context map in
25:24
separate versions of our context map in this case let's say so we have uh
25:25
this case let's say so we have uh
25:25
this case let's say so we have uh publish it language version one for dis
25:27
publish it language version one for dis
25:27
publish it language version one for dis bounded context and publish it language
25:29
bounded context and publish it language
25:29
bounded context and publish it language version two for this bounded context
25:32
version two for this bounded context
25:32
version two for this bounded context great so this is about our strategical
25:35
great so this is about our strategical
25:35
great so this is about our strategical parents unfortunately it is not possible
25:37
parents unfortunately it is not possible
25:37
parents unfortunately it is not possible for you to bypass this strategic step uh
25:41
for you to bypass this strategic step uh
25:41
for you to bypass this strategic step uh to move directly to Tactical ones
25:43
to move directly to Tactical ones
25:43
to move directly to Tactical ones because if you don't have enough
25:45
because if you don't have enough
25:45
because if you don't have enough understanding if you don't know what to
25:47
understanding if you don't know what to
25:47
understanding if you don't know what to code what can you code so in a simple
25:50
code what can you code so in a simple
25:50
code what can you code so in a simple terms so what about tactical parents we
25:53
terms so what about tactical parents we
25:54
terms so what about tactical parents we have uh a lot of tactical parents like
25:56
have uh a lot of tactical parents like
25:56
have uh a lot of tactical parents like we have value objects entities we have
25:59
we have value objects entities we have
25:59
we have value objects entities we have Aggregates we have moduls we have
26:02
Aggregates we have moduls we have
26:02
Aggregates we have moduls we have repositories domain Services application
26:05
repositories domain Services application
26:05
repositories domain Services application Services factories they are part of our
26:07
Services factories they are part of our
26:07
Services factories they are part of our tactical patterns and we'll try one by
26:09
tactical patterns and we'll try one by
26:09
tactical patterns and we'll try one by one cover um all of them let's say so
26:13
one cover um all of them let's say so
26:13
one cover um all of them let's say so tactical patterns are the specific
26:15
tactical patterns are the specific
26:15
tactical patterns are the specific building blocks and design techniques
26:17
building blocks and design techniques
26:17
building blocks and design techniques used to implement a domain model within
26:19
used to implement a domain model within
26:19
used to implement a domain model within a bounded context so you see we are
26:21
a bounded context so you see we are
26:21
a bounded context so you see we are going to talk about in a given bounded
26:24
going to talk about in a given bounded
26:24
going to talk about in a given bounded context so without a bounded context you
26:26
context so without a bounded context you
26:26
context so without a bounded context you cannot apply this Tactical pth patterns
26:28
cannot apply this Tactical pth patterns
26:28
cannot apply this Tactical pth patterns you should first specify your bounded
26:30
you should first specify your bounded
26:30
you should first specify your bounded context so you should first specify your
26:33
context so you should first specify your
26:33
context so you should first specify your ubiquitous language and you need to have
26:36
ubiquitous language and you need to have
26:36
ubiquitous language and you need to have a clear solution space communication
26:39
a clear solution space communication
26:39
a clear solution space communication using context map uh and then you can
26:42
using context map uh and then you can
26:43
using context map uh and then you can apply this tactical parents okay the
26:45
apply this tactical parents okay the
26:45
apply this tactical parents okay the first tactical pattern is going to be
26:47
first tactical pattern is going to be
26:47
first tactical pattern is going to be our entity this is not entity so we all
26:52
our entity this is not entity so we all
26:52
our entity this is not entity so we all now from the C Entity framework we have
26:55
now from the C Entity framework we have
26:55
now from the C Entity framework we have entities this is not the same entity so
26:58
entities this is not the same entity so
26:58
entities this is not the same entity so this is is a bit
26:59
this is is a bit
26:59
this is is a bit different The Entity is identified by it
27:03
different The Entity is identified by it
27:03
different The Entity is identified by it is ID uh in our entity entity is a class
27:07
is ID uh in our entity entity is a class
27:07
is ID uh in our entity entity is a class I will show you a simple example here
27:09
I will show you a simple example here
27:09
I will show you a simple example here entity is a simple class that is not
27:12
entity is a simple class that is not
27:12
entity is a simple class that is not anemic model what is anemic model it
27:14
anemic model what is anemic model it
27:14
anemic model what is anemic model it means you your class only consist from
27:18
means you your class only consist from
27:18
means you your class only consist from properties in terms of let's say C Java
27:21
properties in terms of let's say C Java
27:21
properties in terms of let's say C Java Fields properties and the related
27:24
Fields properties and the related
27:25
Fields properties and the related business operations related logic method
27:29
business operations related logic method
27:29
business operations related logic method uh handled by the upper layer you have
27:31
uh handled by the upper layer you have
27:31
uh handled by the upper layer you have for example the service layer that uh
27:36
for example the service layer that uh
27:36
for example the service layer that uh acts as a wer over your entity and does
27:40
acts as a wer over your entity and does
27:40
acts as a wer over your entity and does the related operations to this entity so
27:43
the related operations to this entity so
27:43
the related operations to this entity so it means it indicate that you have
27:45
it means it indicate that you have
27:45
it means it indicate that you have anemic model uh anemic model is
27:49
anemic model uh anemic model is
27:49
anemic model uh anemic model is andarn and you shouldn't apply it in
27:52
andarn and you shouldn't apply it in
27:52
andarn and you shouldn't apply it in your projects when you really apply
27:54
your projects when you really apply
27:54
your projects when you really apply domain ding design and when we talk
27:57
domain ding design and when we talk
27:57
domain ding design and when we talk about entity we talk about a class that
28:00
about entity we talk about a class that
28:00
about entity we talk about a class that have in terms of modern language
28:02
have in terms of modern language
28:02
have in terms of modern language properties and
28:04
properties and
28:04
properties and methods every entity has it is life
28:07
methods every entity has it is life
28:07
methods every entity has it is life cycle so you can create modify and
28:10
cycle so you can create modify and
28:10
cycle so you can create modify and eventually delete it uh entities are
28:13
eventually delete it uh entities are
28:13
eventually delete it uh entities are mutable and entities has a state uh that
28:17
mutable and entities has a state uh that
28:17
mutable and entities has a state uh that represent by attributes which can change
28:19
represent by attributes which can change
28:19
represent by attributes which can change over time okay so let's uh before moving
28:23
over time okay so let's uh before moving
28:23
over time okay so let's uh before moving to Value object let's go to our project
28:26
to Value object let's go to our project
28:26
to Value object let's go to our project here and and first let's uh here in our
28:31
here and and first let's uh here in our
28:31
here and and first let's uh here in our Visual Studio we have for example great
28:34
Visual Studio we have for example great
28:34
Visual Studio we have for example great so you see this grade inherits from
28:37
so you see this grade inherits from
28:37
so you see this grade inherits from entity base this is our entity
28:39
entity base this is our entity
28:39
entity base this is our entity identified by ID so we are defining G
28:42
identified by ID so we are defining G
28:42
identified by ID so we are defining G you can use it different uh even you may
28:45
you can use it different uh even you may
28:45
you can use it different uh even you may have the your own solution for your ID
28:49
have the your own solution for your ID
28:49
have the your own solution for your ID you can implement it in your database
28:51
you can implement it in your database
28:51
you can implement it in your database site in your application side the
28:52
site in your application side the
28:52
site in your application side the generation process so you see this is my
28:55
generation process so you see this is my
28:55
generation process so you see this is my grade this is not a simple entity in my
28:57
grade this is not a simple entity in my
28:57
grade this is not a simple entity in my grade I I have some properties here and
29:00
grade I I have some properties here and
29:00
grade I I have some properties here and also I have behaviors so you see these
29:04
also I have behaviors so you see these
29:04
also I have behaviors so you see these behaviors are really related to the
29:06
behaviors are really related to the
29:06
behaviors are really related to the business this is a domain model because
29:09
business this is a domain model because
29:09
business this is a domain model because this domain model really valuable from
29:12
this domain model really valuable from
29:12
this domain model really valuable from the business process if I have the
29:14
the business process if I have the
29:14
the business process if I have the business operations related to my entity
29:18
business operations related to my entity
29:18
business operations related to my entity that I can um put it push it to my grade
29:22
that I can um put it push it to my grade
29:23
that I can um put it push it to my grade I'm writing it inside my grade class for
29:25
I'm writing it inside my grade class for
29:26
I'm writing it inside my grade class for example it has is valid GR is assignable
29:29
example it has is valid GR is assignable
29:29
example it has is valid GR is assignable it has calculate bonus method so you see
29:32
it has calculate bonus method so you see
29:32
it has calculate bonus method so you see I'm not using a separate service layer
29:35
I'm not using a separate service layer
29:35
I'm not using a separate service layer creating a calculate bonus
29:37
creating a calculate bonus
29:37
creating a calculate bonus asynchronously and let's call this grd
29:39
asynchronously and let's call this grd
29:40
asynchronously and let's call this grd somehow from The Entity using uh the
29:43
somehow from The Entity using uh the
29:43
somehow from The Entity using uh the repository stuff so I'm just going to
29:45
repository stuff so I'm just going to
29:45
repository stuff so I'm just going to show you the examples using C but it
29:47
show you the examples using C but it
29:47
show you the examples using C but it doesn't mean that it is applicable only
29:50
doesn't mean that it is applicable only
29:50
doesn't mean that it is applicable only in
29:51
in
29:51
in C you can uh apply domain D design in
29:54
C you can uh apply domain D design in
29:54
C you can uh apply domain D design in any modern language this is a language
29:56
any modern language this is a language
29:56
any modern language this is a language agnostic architectural agnostic and this
29:58
agnostic architectural agnostic and this
29:58
agnostic architectural agnostic and this is really cool stuff to use so we have
30:02
is really cool stuff to use so we have
30:02
is really cool stuff to use so we have great here entity base it inters from
30:04
great here entity base it inters from
30:04
great here entity base it inters from The Entity and this entity defin the
30:07
The Entity and this entity defin the
30:07
The Entity and this entity defin the reality of our entity so you see we have
30:10
reality of our entity so you see we have
30:10
reality of our entity so you see we have equality stuff here and if we need to
30:13
equality stuff here and if we need to
30:13
equality stuff here and if we need to compare this entity with another same
30:16
compare this entity with another same
30:16
compare this entity with another same type entity we should care only about it
30:18
type entity we should care only about it
30:18
type entity we should care only about it is ID if their ID are equal it means
30:21
is ID if their ID are equal it means
30:21
is ID if their ID are equal it means these entities are equal okay and uh
30:26
these entities are equal okay and uh
30:26
these entities are equal okay and uh that's about entity about value objects
30:29
that's about entity about value objects
30:29
that's about entity about value objects they are identified by attributes they
30:31
they are identified by attributes they
30:31
they are identified by attributes they don't have life cycle immutable no State
30:34
don't have life cycle immutable no State
30:35
don't have life cycle immutable no State and they should be a part of our
30:36
and they should be a part of our
30:36
and they should be a part of our aggregate root and in our case let me
30:39
aggregate root and in our case let me
30:39
aggregate root and in our case let me show you a simple example here and in
30:42
show you a simple example here and in
30:42
show you a simple example here and in our example we have for example domain
30:45
our example we have for example domain
30:45
our example we have for example domain range here this is our value object uh
30:48
range here this is our value object uh
30:48
range here this is our value object uh we we mostly Focus to move all the
30:50
we we mostly Focus to move all the
30:50
we we mostly Focus to move all the business processes to our value objects
30:52
business processes to our value objects
30:52
business processes to our value objects because value objects better than moving
30:55
because value objects better than moving
30:55
because value objects better than moving the business logic into our entities
30:58
the business logic into our entities
30:58
the business logic into our entities okay so we have the short amount of time
31:01
okay so we have the short amount of time
31:01
okay so we have the short amount of time so I will try to cover everything as
31:03
so I will try to cover everything as
31:03
so I will try to cover everything as simple as possible again so we have
31:05
simple as possible again so we have
31:05
simple as possible again so we have Aggregates they are the um single unit
31:08
Aggregates they are the um single unit
31:09
Aggregates they are the um single unit for data changes they are associated
31:11
for data changes they are associated
31:11
for data changes they are associated objects treated as a single unit
31:13
objects treated as a single unit
31:13
objects treated as a single unit Aggregates I designed to encapsulate a
31:16
Aggregates I designed to encapsulate a
31:16
Aggregates I designed to encapsulate a group of related objects and it has a
31:18
group of related objects and it has a
31:18
group of related objects and it has a root entity and entity can be part of an
31:22
root entity and entity can be part of an
31:22
root entity and entity can be part of an aggregate one aggregate can contain
31:24
aggregate one aggregate can contain
31:24
aggregate one aggregate can contain multiple uh entities and value objects
31:27
multiple uh entities and value objects
31:27
multiple uh entities and value objects because because your repository should
31:29
because because your repository should
31:29
because because your repository should interact with your entity The Entity is
31:32
interact with your entity The Entity is
31:32
interact with your entity The Entity is uh sub let's say a type of the aggregate
31:35
uh sub let's say a type of the aggregate
31:35
uh sub let's say a type of the aggregate is a type of entity but in a repository
31:38
is a type of entity but in a repository
31:38
is a type of entity but in a repository layer in the highest layer we are
31:40
layer in the highest layer we are
31:40
layer in the highest layer we are interacting with our Aggregates okay and
31:44
interacting with our Aggregates okay and
31:44
interacting with our Aggregates okay and you all know about the repositories we
31:46
you all know about the repositories we
31:46
you all know about the repositories we have repository we are um uh providing a
31:49
have repository we are um uh providing a
31:49
have repository we are um uh providing a methods to retrieve add update delete
31:51
methods to retrieve add update delete
31:51
methods to retrieve add update delete stuff and it encapsulates underlying
31:53
stuff and it encapsulates underlying
31:53
stuff and it encapsulates underlying data storage and we are working with
31:57
data storage and we are working with
31:57
data storage and we are working with aggregate roots in our repository stuff
31:59
aggregate roots in our repository stuff
31:59
aggregate roots in our repository stuff and it defines boundary between domain
32:01
and it defines boundary between domain
32:01
and it defines boundary between domain and
32:03
and
32:03
and infrastructure and for the other
32:05
infrastructure and for the other
32:05
infrastructure and for the other tactical patterns we have domain
32:07
tactical patterns we have domain
32:07
tactical patterns we have domain Services application Services domain
32:09
Services application Services domain
32:09
Services application Services domain events modules factories and this is our
32:12
events modules factories and this is our
32:12
events modules factories and this is our general architecture so you see we have
32:14
general architecture so you see we have
32:14
general architecture so you see we have UI application Services repositories
32:17
UI application Services repositories
32:17
UI application Services repositories factories domain Services here and in
32:19
factories domain Services here and in
32:19
factories domain Services here and in the core we have entities value objects
32:21
the core we have entities value objects
32:22
the core we have entities value objects domain events Aggregates which they are
32:24
domain events Aggregates which they are
32:24
domain events Aggregates which they are matter
32:25
matter
32:25
matter more and for the alternative and better
32:29
more and for the alternative and better
32:29
more and for the alternative and better resources unfortunately I couldn't cover
32:31
resources unfortunately I couldn't cover
32:31
resources unfortunately I couldn't cover every aspect of uh the domain driv in
32:33
every aspect of uh the domain driv in
32:33
every aspect of uh the domain driv in design we have uh great book from Eric
32:35
design we have uh great book from Eric
32:35
design we have uh great book from Eric evance from V Veron I really love
32:37
evance from V Veron I really love
32:37
evance from V Veron I really love implementing domain dur design book and
32:39
implementing domain dur design book and
32:40
implementing domain dur design book and also we have learning domain dur design
32:42
also we have learning domain dur design
32:42
also we have learning domain dur design book by Vlad con kov and also sorry for
32:47
book by Vlad con kov and also sorry for
32:47
book by Vlad con kov and also sorry for the mismatching the stuff and also
32:50
the mismatching the stuff and also
32:50
the mismatching the stuff and also handson domain R design with net core
32:52
handson domain R design with net core
32:52
handson domain R design with net core the net implementation by Alexa Z yeah
32:57
the net implementation by Alexa Z yeah
32:57
the net implementation by Alexa Z yeah uh that that's pretty much all about
33:00
uh that that's pretty much all about
33:00
uh that that's pretty much all about understanding domain Rin design I hope I
33:02
understanding domain Rin design I hope I
33:02
understanding domain Rin design I hope I could explain more in a given short
33:05
could explain more in a given short
33:05
could explain more in a given short amount of time
33:07
amount of time
33:07
amount of time [Music]