domain driven design
DESCRIPTION
Domain Driven Design una presentacion que introduce conceptos y usando muchos esquemas y conceptos de InternetTRANSCRIPT
![Page 1: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/1.jpg)
Domain Driven DesignViernes 21 de Marzo
Innbit
![Page 2: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/2.jpg)
Enfoque tradicional de diseño
De los casos de uso, se presume que es suficiente para que ...
… los equipos de Desarrollo construyan un sistema
! PERO NO ES SUFICIENTE !
![Page 3: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/3.jpg)
Al diseñar un sistema, pensarlo en términos del Dominio del problema a resolver
No diseñar en términos técnicos o
problemas de TI
![Page 4: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/4.jpg)
Por tanto el concepto de dominio ...Ayuda a entender el contexto del problema a ser resuelto por un sistema de software
Y permite expresar el problema y la solución en términos de un lenguaje común a todos los que involucrados.
![Page 5: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/5.jpg)
Model Driven Design
![Page 6: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/6.jpg)
Ubiquitous Language
![Page 7: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/7.jpg)
Bounded Context Importante definir el contexto en el cual el dominio aplica
El mapa de contexto es la vista global de todos los contextos que participan
La consistencia de los contexto se debe garantizar a través de integración continua
![Page 8: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/8.jpg)
Como cualquier modelo, el meta modelo no es facil de digerir ...
Manera de guardar información:Entity, Value Object
Encapsular Complejidad del modelo:
Aggregate
Procesamiento del Modelo:
Service
Construcción del Modelo:
FactoryInstrumentación del modelo:
Event
Persistencia del modelo:Repository
![Page 9: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/9.jpg)
EntityTienen una identidad que los hace único
An object that is not defined by its attributes, but rather by a thread of continuity and its identity.
![Page 10: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/10.jpg)
Value Object An object that contains attributes but has no conceptual identity. They should be treated as immutable.
![Page 11: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/11.jpg)
Aggregate A collection of objects that are bound together by a root entity, otherwise known as an aggregate root. The aggregate root guarantees the consistency of changes being made within the aggregate by forbidding external objects from holding references to its members.
Encapsula complejidad
![Page 12: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/12.jpg)
Domain ServiceWhen an operation does not conceptually belong to any object. Following the natural contours of the problem, you can implement these operations in services
● Servicio no tiene estado● Agnosticos a la infraestructura
de servicios subyacente
![Page 13: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/13.jpg)
FactoryMethods for creating domain objects should delegate to a specialized Factory object such that alternative implementations may be easily interchanged.
La manera para construir y ensamblar los bloques del dominio
![Page 14: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/14.jpg)
Repository Methods for retrieving domain objects should delegate to a specialized Repository object such that alternative storage implementations may be easily interchanged.
● El concepto de repositorio es que el lenguaje del dominio sea agnóstico al esquema de almacenamiento y la implantación del repositorio sea facilmente intercambiable
● Soportar esquemas de RDBMS, NoSQL, InMemory Database, entre otros
![Page 15: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/15.jpg)
Architecture
![Page 16: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/16.jpg)
Application● Una aplicación es cliente del modelo del dominio.● La aplicación se especifica con los casos de uso● Une la presentación, comunicación e infraestructura
![Page 17: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/17.jpg)
El mapa completo ...
![Page 18: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/18.jpg)
![Page 19: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/19.jpg)
Command & Query Responsibility Segregation - Diferente modelo para consultar que para modificar -
![Page 20: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/20.jpg)
Un ejemplo de uso de DDD
http://www.opentaps.org/docs/index.php/Domain_Driven_Architecture
![Page 21: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/21.jpg)
xDD
![Page 22: Domain driven design](https://reader034.vdocumento.com/reader034/viewer/2022052218/5585ae47d8b42ae22a8b5015/html5/thumbnails/22.jpg)
! Gracias !