SlideShare a Scribd company logo
1 of 17
Download to read offline
Genealogy of DDD
Szymon Homa
@s2lomon
s2lomon@gmail.com
Why it is important?
Entity
Examples of reference objects might include:
Customer, Account, Telephone Switch, and the like.
They are often complex and large and may be
referred to in lots of places. They usually have a rich
state and any change from any place needs to be
visible to other objects that refer to it.
Reference objects are compared based on their
identity, although you may see IdentifyingAttributes.
You don't usually see muliple copies of a
ReferenceObject in one address space.
Source: https://web.archive.org/web/20010717202923/http://c2.com/cgi/wiki?ReferenceObject
Reference Objects
Martin Fowler
Entity
Keep behavior with related information.
Don't make any role too big.
Distribute intelligence.
Keep information about one thing in one place.
Source: http://www.wirfs-brock.com/PDFs/A_Brief-Tour-of-RDD.pdf
Hints from RDD
Rebecca Wirfs-Brock
Entity
Source: https://domainlanguage.com/ddd/patterns/DDD_Reference_2011-01-31.pdf
In DDD Context
When an object is distinguished by its identity,
rather than its attributes, make this primary to its
definition in the model. Keep the class definition
simple and focused on life cycle continuity and
identity.
…
The model must define what it means to be the same
thing.
(aka Reference Objects)
Value Object
Source: http://c2.com/ppr/checks.html
CHECKS Pattern Language (Whole Value)
Ward Cunningham
…
Construct specialized values to quantify your
domain model and use these values as the
arguments of their messages and as the units of
input and output. Make sure these objects capture
the whole quantity with all its implications beyond
merely magnitude, but, keep them independent of
any particular domain.
…
Value Object
Source: https://domainlanguage.com/ddd/patterns/DDD_Reference_2011-01-31.pdf
In DDD context
When you care only about the attributes
and logic of an element of the model, classify it as a
value object. Make it express the meaning of the
attributes it conveys and give it related functionality.
Treat the value object as immutable. Make all
operations Side-effect-free Functions that don’t
depend on any mutable state. Don’t give a value
objectany identity and avoid the design complexities
necessary to maintain entities.
Specification
GoF StrategyGoF Strategy
Specification
(Martin Fowler and Eric Evans)
Ubiquitous Language
...
Revise the names of your objects to reflect their
ultimate roles. Words drawn from human relations
often imply much secondary meaning. Make sure
these align with the intent of your responsibility
allocations.
…
Avoid names that have confused or unfortunate
meanings in related domains. Consult a Thesaurus
and try the synonyms it suggests as you might use it
as a class name.
…
Your new names will lead you to an even deeper
understanding of your objects
System Of Names
Ward Cunningham
Source: https://web.archive.org/web/19961129215819/http://c2.com/cgi/wiki?SystemOfNames
Ubiquitous Language
Use the model as the backbone of a language.
Commit the team to exercising that language
relentlessly in all communication within the team and
in the code.
In DDD Context
Source: https://domainlanguage.com/ddd/patterns/DDD_Reference_2011-01-31.pdf
Domain Event?
Domain Service?
Repository?
Domain Event?
Domain Service?
Repository?
Events can be found in the
literature since the 80s.
Services are widespread in many
contexts, e.g. in RDD
DAO, Gateway, Service Provider
Aggregate?
Bounded Context?
Aggregate?
Bounded Context?
Simillar ideas can be found in RDD
Simillar ideas can be found in RDD
Time to see some code
https://github.com/S2lomon/genealogy-of-ddd-sketches
So again -
why it is important?
Questions

More Related Content

Viewers also liked

Geri̇lla halkla i̇li̇şki̇ler nedi̇r gamze
Geri̇lla halkla i̇li̇şki̇ler nedi̇r gamzeGeri̇lla halkla i̇li̇şki̇ler nedi̇r gamze
Geri̇lla halkla i̇li̇şki̇ler nedi̇r gamzecnkr
 
BERR INDUSTRY - TR : PRESENTATION OF THE WORKS
BERR INDUSTRY - TR : PRESENTATION OF THE WORKSBERR INDUSTRY - TR : PRESENTATION OF THE WORKS
BERR INDUSTRY - TR : PRESENTATION OF THE WORKSBerr Industry
 
Long Term Economic Growth and Sustainability by Investing in the Arts
Long Term Economic Growth and Sustainability by Investing in the ArtsLong Term Economic Growth and Sustainability by Investing in the Arts
Long Term Economic Growth and Sustainability by Investing in the ArtsChelsea Casanave
 
JMO to dSeries, A 10 Stage Conversion Process - CA Workload Automation Techno...
JMO to dSeries, A 10 Stage Conversion Process - CA Workload Automation Techno...JMO to dSeries, A 10 Stage Conversion Process - CA Workload Automation Techno...
JMO to dSeries, A 10 Stage Conversion Process - CA Workload Automation Techno...Extra Technology
 
Lower respiratory tract__diseases
Lower respiratory tract__diseasesLower respiratory tract__diseases
Lower respiratory tract__diseasesVladimir Valkov
 
벽체개구부사인장균열방지재(홍성욱)141024[최종]
벽체개구부사인장균열방지재(홍성욱)141024[최종]벽체개구부사인장균열방지재(홍성욱)141024[최종]
벽체개구부사인장균열방지재(홍성욱)141024[최종]krposi
 
Dossier Spesa Pubblica Febbraio 2015
Dossier Spesa Pubblica Febbraio 2015Dossier Spesa Pubblica Febbraio 2015
Dossier Spesa Pubblica Febbraio 2015Alessandro Pastacci
 

Viewers also liked (10)

Geri̇lla halkla i̇li̇şki̇ler nedi̇r gamze
Geri̇lla halkla i̇li̇şki̇ler nedi̇r gamzeGeri̇lla halkla i̇li̇şki̇ler nedi̇r gamze
Geri̇lla halkla i̇li̇şki̇ler nedi̇r gamze
 
BERR INDUSTRY - TR : PRESENTATION OF THE WORKS
BERR INDUSTRY - TR : PRESENTATION OF THE WORKSBERR INDUSTRY - TR : PRESENTATION OF THE WORKS
BERR INDUSTRY - TR : PRESENTATION OF THE WORKS
 
Question 4
Question 4Question 4
Question 4
 
Long Term Economic Growth and Sustainability by Investing in the Arts
Long Term Economic Growth and Sustainability by Investing in the ArtsLong Term Economic Growth and Sustainability by Investing in the Arts
Long Term Economic Growth and Sustainability by Investing in the Arts
 
De haan wegwijs-2014
De haan wegwijs-2014De haan wegwijs-2014
De haan wegwijs-2014
 
Wegwijs in moorslede_informatiegids2013-2015
Wegwijs in moorslede_informatiegids2013-2015Wegwijs in moorslede_informatiegids2013-2015
Wegwijs in moorslede_informatiegids2013-2015
 
JMO to dSeries, A 10 Stage Conversion Process - CA Workload Automation Techno...
JMO to dSeries, A 10 Stage Conversion Process - CA Workload Automation Techno...JMO to dSeries, A 10 Stage Conversion Process - CA Workload Automation Techno...
JMO to dSeries, A 10 Stage Conversion Process - CA Workload Automation Techno...
 
Lower respiratory tract__diseases
Lower respiratory tract__diseasesLower respiratory tract__diseases
Lower respiratory tract__diseases
 
벽체개구부사인장균열방지재(홍성욱)141024[최종]
벽체개구부사인장균열방지재(홍성욱)141024[최종]벽체개구부사인장균열방지재(홍성욱)141024[최종]
벽체개구부사인장균열방지재(홍성욱)141024[최종]
 
Dossier Spesa Pubblica Febbraio 2015
Dossier Spesa Pubblica Febbraio 2015Dossier Spesa Pubblica Febbraio 2015
Dossier Spesa Pubblica Febbraio 2015
 

Similar to Genealogy of DDD

Domain driven design
Domain driven designDomain driven design
Domain driven designits_skm
 
Logical ERD 2022.pptx
Logical ERD  2022.pptxLogical ERD  2022.pptx
Logical ERD 2022.pptxJeff Jacobs
 
Up to speed in domain driven design
Up to speed in domain driven designUp to speed in domain driven design
Up to speed in domain driven designRick van der Arend
 
Repositories thru the looking glass
Repositories thru the looking glassRepositories thru the looking glass
Repositories thru the looking glassEduserv Foundation
 
PHP - Procedural To Object-Oriented
PHP - Procedural To Object-OrientedPHP - Procedural To Object-Oriented
PHP - Procedural To Object-OrientedVance Lucas
 
S doherty counting_dragons_dita-reuse
S doherty counting_dragons_dita-reuseS doherty counting_dragons_dita-reuse
S doherty counting_dragons_dita-reuseStan Doherty
 
Domain Driven Design Quickly
Domain Driven Design QuicklyDomain Driven Design Quickly
Domain Driven Design QuicklyMariam Hakobyan
 
Integrating Government Data New
Integrating Government Data NewIntegrating Government Data New
Integrating Government Data Newguest4543bb
 
Learning Resource Metadata Initiative: Vocabulary Development Best Practices
Learning Resource Metadata Initiative: Vocabulary Development Best PracticesLearning Resource Metadata Initiative: Vocabulary Development Best Practices
Learning Resource Metadata Initiative: Vocabulary Development Best PracticesMike Linksvayer
 
Eprints Special Session - DC-2006, Mexico
Eprints Special Session - DC-2006, MexicoEprints Special Session - DC-2006, Mexico
Eprints Special Session - DC-2006, MexicoEduserv Foundation
 
Object oriented software engineering concepts
Object oriented software engineering conceptsObject oriented software engineering concepts
Object oriented software engineering conceptsKomal Singh
 
Dcap Ja Progmeet 2007 07 05
Dcap Ja Progmeet 2007 07 05Dcap Ja Progmeet 2007 07 05
Dcap Ja Progmeet 2007 07 05Julie Allinson
 
SENG691I - Knowledge Representation and The Semantic Web
SENG691I - Knowledge Representation and The Semantic WebSENG691I - Knowledge Representation and The Semantic Web
SENG691I - Knowledge Representation and The Semantic WebDaniel Shaw
 
Dublin Core Application Profile for Scholarly Works Slainte
Dublin Core Application Profile for Scholarly Works SlainteDublin Core Application Profile for Scholarly Works Slainte
Dublin Core Application Profile for Scholarly Works SlainteJulie Allinson
 
Domain-Driven Design
Domain-Driven DesignDomain-Driven Design
Domain-Driven DesignBradley Holt
 
Making Inter-operability Visible
Making Inter-operability VisibleMaking Inter-operability Visible
Making Inter-operability Visibleliddy
 
Evolve Your Code
Evolve Your CodeEvolve Your Code
Evolve Your CodeRookieOne
 
Swap For Dummies Rsp 2007 11 29
Swap For Dummies Rsp 2007 11 29Swap For Dummies Rsp 2007 11 29
Swap For Dummies Rsp 2007 11 29Julie Allinson
 
Object Oriented Approach For Software Development
Object Oriented Approach For Software DevelopmentObject Oriented Approach For Software Development
Object Oriented Approach For Software DevelopmentJessica Tanner
 

Similar to Genealogy of DDD (20)

Domain driven design
Domain driven designDomain driven design
Domain driven design
 
Logical ERD 2022.pptx
Logical ERD  2022.pptxLogical ERD  2022.pptx
Logical ERD 2022.pptx
 
Up to speed in domain driven design
Up to speed in domain driven designUp to speed in domain driven design
Up to speed in domain driven design
 
Repositories thru the looking glass
Repositories thru the looking glassRepositories thru the looking glass
Repositories thru the looking glass
 
PHP - Procedural To Object-Oriented
PHP - Procedural To Object-OrientedPHP - Procedural To Object-Oriented
PHP - Procedural To Object-Oriented
 
S doherty counting_dragons_dita-reuse
S doherty counting_dragons_dita-reuseS doherty counting_dragons_dita-reuse
S doherty counting_dragons_dita-reuse
 
Domain Driven Design
Domain Driven DesignDomain Driven Design
Domain Driven Design
 
Domain Driven Design Quickly
Domain Driven Design QuicklyDomain Driven Design Quickly
Domain Driven Design Quickly
 
Integrating Government Data New
Integrating Government Data NewIntegrating Government Data New
Integrating Government Data New
 
Learning Resource Metadata Initiative: Vocabulary Development Best Practices
Learning Resource Metadata Initiative: Vocabulary Development Best PracticesLearning Resource Metadata Initiative: Vocabulary Development Best Practices
Learning Resource Metadata Initiative: Vocabulary Development Best Practices
 
Eprints Special Session - DC-2006, Mexico
Eprints Special Session - DC-2006, MexicoEprints Special Session - DC-2006, Mexico
Eprints Special Session - DC-2006, Mexico
 
Object oriented software engineering concepts
Object oriented software engineering conceptsObject oriented software engineering concepts
Object oriented software engineering concepts
 
Dcap Ja Progmeet 2007 07 05
Dcap Ja Progmeet 2007 07 05Dcap Ja Progmeet 2007 07 05
Dcap Ja Progmeet 2007 07 05
 
SENG691I - Knowledge Representation and The Semantic Web
SENG691I - Knowledge Representation and The Semantic WebSENG691I - Knowledge Representation and The Semantic Web
SENG691I - Knowledge Representation and The Semantic Web
 
Dublin Core Application Profile for Scholarly Works Slainte
Dublin Core Application Profile for Scholarly Works SlainteDublin Core Application Profile for Scholarly Works Slainte
Dublin Core Application Profile for Scholarly Works Slainte
 
Domain-Driven Design
Domain-Driven DesignDomain-Driven Design
Domain-Driven Design
 
Making Inter-operability Visible
Making Inter-operability VisibleMaking Inter-operability Visible
Making Inter-operability Visible
 
Evolve Your Code
Evolve Your CodeEvolve Your Code
Evolve Your Code
 
Swap For Dummies Rsp 2007 11 29
Swap For Dummies Rsp 2007 11 29Swap For Dummies Rsp 2007 11 29
Swap For Dummies Rsp 2007 11 29
 
Object Oriented Approach For Software Development
Object Oriented Approach For Software DevelopmentObject Oriented Approach For Software Development
Object Oriented Approach For Software Development
 

Recently uploaded

Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Natan Silnitsky
 
Sending Calendar Invites on SES and Calendarsnack.pdf
Sending Calendar Invites on SES and Calendarsnack.pdfSending Calendar Invites on SES and Calendarsnack.pdf
Sending Calendar Invites on SES and Calendarsnack.pdf31events.com
 
SpotFlow: Tracking Method Calls and States at Runtime
SpotFlow: Tracking Method Calls and States at RuntimeSpotFlow: Tracking Method Calls and States at Runtime
SpotFlow: Tracking Method Calls and States at Runtimeandrehoraa
 
Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...
Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...
Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...confluent
 
Powering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data StreamsPowering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data StreamsSafe Software
 
Post Quantum Cryptography – The Impact on Identity
Post Quantum Cryptography – The Impact on IdentityPost Quantum Cryptography – The Impact on Identity
Post Quantum Cryptography – The Impact on Identityteam-WIBU
 
Cloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEECloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEEVICTOR MAESTRE RAMIREZ
 
Unveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsUnveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsAhmed Mohamed
 
Exploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdf
Exploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdfExploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdf
Exploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdfkalichargn70th171
 
UI5ers live - Custom Controls wrapping 3rd-party libs.pptx
UI5ers live - Custom Controls wrapping 3rd-party libs.pptxUI5ers live - Custom Controls wrapping 3rd-party libs.pptx
UI5ers live - Custom Controls wrapping 3rd-party libs.pptxAndreas Kunz
 
英国UN学位证,北安普顿大学毕业证书1:1制作
英国UN学位证,北安普顿大学毕业证书1:1制作英国UN学位证,北安普顿大学毕业证书1:1制作
英国UN学位证,北安普顿大学毕业证书1:1制作qr0udbr0
 
Simplifying Microservices & Apps - The art of effortless development - Meetup...
Simplifying Microservices & Apps - The art of effortless development - Meetup...Simplifying Microservices & Apps - The art of effortless development - Meetup...
Simplifying Microservices & Apps - The art of effortless development - Meetup...Rob Geurden
 
Unveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New FeaturesUnveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New FeaturesŁukasz Chruściel
 
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...Angel Borroy López
 
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...OnePlan Solutions
 
Odoo 14 - eLearning Module In Odoo 14 Enterprise
Odoo 14 - eLearning Module In Odoo 14 EnterpriseOdoo 14 - eLearning Module In Odoo 14 Enterprise
Odoo 14 - eLearning Module In Odoo 14 Enterprisepreethippts
 
CRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. SalesforceCRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. SalesforceBrainSell Technologies
 
What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...Technogeeks
 
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...Cizo Technology Services
 

Recently uploaded (20)

Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
 
Sending Calendar Invites on SES and Calendarsnack.pdf
Sending Calendar Invites on SES and Calendarsnack.pdfSending Calendar Invites on SES and Calendarsnack.pdf
Sending Calendar Invites on SES and Calendarsnack.pdf
 
SpotFlow: Tracking Method Calls and States at Runtime
SpotFlow: Tracking Method Calls and States at RuntimeSpotFlow: Tracking Method Calls and States at Runtime
SpotFlow: Tracking Method Calls and States at Runtime
 
Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...
Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...
Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...
 
Powering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data StreamsPowering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data Streams
 
Post Quantum Cryptography – The Impact on Identity
Post Quantum Cryptography – The Impact on IdentityPost Quantum Cryptography – The Impact on Identity
Post Quantum Cryptography – The Impact on Identity
 
Cloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEECloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEE
 
Unveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsUnveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML Diagrams
 
Advantages of Odoo ERP 17 for Your Business
Advantages of Odoo ERP 17 for Your BusinessAdvantages of Odoo ERP 17 for Your Business
Advantages of Odoo ERP 17 for Your Business
 
Exploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdf
Exploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdfExploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdf
Exploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdf
 
UI5ers live - Custom Controls wrapping 3rd-party libs.pptx
UI5ers live - Custom Controls wrapping 3rd-party libs.pptxUI5ers live - Custom Controls wrapping 3rd-party libs.pptx
UI5ers live - Custom Controls wrapping 3rd-party libs.pptx
 
英国UN学位证,北安普顿大学毕业证书1:1制作
英国UN学位证,北安普顿大学毕业证书1:1制作英国UN学位证,北安普顿大学毕业证书1:1制作
英国UN学位证,北安普顿大学毕业证书1:1制作
 
Simplifying Microservices & Apps - The art of effortless development - Meetup...
Simplifying Microservices & Apps - The art of effortless development - Meetup...Simplifying Microservices & Apps - The art of effortless development - Meetup...
Simplifying Microservices & Apps - The art of effortless development - Meetup...
 
Unveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New FeaturesUnveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New Features
 
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
 
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
 
Odoo 14 - eLearning Module In Odoo 14 Enterprise
Odoo 14 - eLearning Module In Odoo 14 EnterpriseOdoo 14 - eLearning Module In Odoo 14 Enterprise
Odoo 14 - eLearning Module In Odoo 14 Enterprise
 
CRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. SalesforceCRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. Salesforce
 
What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...
 
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
 

Genealogy of DDD

  • 1. Genealogy of DDD Szymon Homa @s2lomon s2lomon@gmail.com
  • 2. Why it is important?
  • 3. Entity Examples of reference objects might include: Customer, Account, Telephone Switch, and the like. They are often complex and large and may be referred to in lots of places. They usually have a rich state and any change from any place needs to be visible to other objects that refer to it. Reference objects are compared based on their identity, although you may see IdentifyingAttributes. You don't usually see muliple copies of a ReferenceObject in one address space. Source: https://web.archive.org/web/20010717202923/http://c2.com/cgi/wiki?ReferenceObject Reference Objects Martin Fowler
  • 4. Entity Keep behavior with related information. Don't make any role too big. Distribute intelligence. Keep information about one thing in one place. Source: http://www.wirfs-brock.com/PDFs/A_Brief-Tour-of-RDD.pdf Hints from RDD Rebecca Wirfs-Brock
  • 5. Entity Source: https://domainlanguage.com/ddd/patterns/DDD_Reference_2011-01-31.pdf In DDD Context When an object is distinguished by its identity, rather than its attributes, make this primary to its definition in the model. Keep the class definition simple and focused on life cycle continuity and identity. … The model must define what it means to be the same thing. (aka Reference Objects)
  • 6. Value Object Source: http://c2.com/ppr/checks.html CHECKS Pattern Language (Whole Value) Ward Cunningham … Construct specialized values to quantify your domain model and use these values as the arguments of their messages and as the units of input and output. Make sure these objects capture the whole quantity with all its implications beyond merely magnitude, but, keep them independent of any particular domain. …
  • 7. Value Object Source: https://domainlanguage.com/ddd/patterns/DDD_Reference_2011-01-31.pdf In DDD context When you care only about the attributes and logic of an element of the model, classify it as a value object. Make it express the meaning of the attributes it conveys and give it related functionality. Treat the value object as immutable. Make all operations Side-effect-free Functions that don’t depend on any mutable state. Don’t give a value objectany identity and avoid the design complexities necessary to maintain entities.
  • 9. Ubiquitous Language ... Revise the names of your objects to reflect their ultimate roles. Words drawn from human relations often imply much secondary meaning. Make sure these align with the intent of your responsibility allocations. … Avoid names that have confused or unfortunate meanings in related domains. Consult a Thesaurus and try the synonyms it suggests as you might use it as a class name. … Your new names will lead you to an even deeper understanding of your objects System Of Names Ward Cunningham Source: https://web.archive.org/web/19961129215819/http://c2.com/cgi/wiki?SystemOfNames
  • 10. Ubiquitous Language Use the model as the backbone of a language. Commit the team to exercising that language relentlessly in all communication within the team and in the code. In DDD Context Source: https://domainlanguage.com/ddd/patterns/DDD_Reference_2011-01-31.pdf
  • 12. Domain Event? Domain Service? Repository? Events can be found in the literature since the 80s. Services are widespread in many contexts, e.g. in RDD DAO, Gateway, Service Provider
  • 14. Aggregate? Bounded Context? Simillar ideas can be found in RDD Simillar ideas can be found in RDD
  • 15. Time to see some code https://github.com/S2lomon/genealogy-of-ddd-sketches
  • 16. So again - why it is important?