Picon

DDD Introduction Talk



Hi,

I want to introduce my team to domain driven design and thought it would be a good idea to let some real expert speak to them (via Youtube or the like). Do you know a good introduction talk?

Thanks,
Christian




__._,_.___
Posted by: christian.helmbold <at> yahoo.de



__,_._,___
Picon

New DDD group in Atlanta (ATL)



 Hello Everyone,

I am announcing a new group for those who live in Atlanta, GA (USA).


Feel free to join us if you live within reasonable distance from zip code 30305. We will try to meet up once a week. All expenses covered (refreshments, parking, etc.).

Thank you for your support!

Jose.
__________________________________________________________
If You Refuse To Everything But The Best....
You Very Often Get It.


__._,_.___
Posted by: Jose Fernandez <ppcuban <at> yahoo.com>



__,_._,___
Picon

Same aggregate in 2 bounded contexts



Let's model this scenario: We are trying to connect to different "Suppliers" via FTP. Each Supplier can have 1 or more FTP servers. We are going to download Inventory files from these FTP servers.

I can identify 2 bounded contexts in this domain:
  1. Suppliers Bounded Context where I mange the life cycle of adding or disabling/enabling a supplier.
  2.  Suppliers Communication Bounded Context where  connect and download the inventory files from the ftp servers.
In BC 1, Supplier is an entity with a model that has id, name, description,...etc. I think I'll also add a Supplier Type since we may need to co nnect to other supplier via different protocols other than ftp.

The problem is with BC 2. Is Supplier an entity? 

The FTP info (host, port, user, pass) is stored in BC 2 and I believe it's a value object. However, this value object should be tied to an entity. If I make Supplier an entity I'm guessing the only attribute it will need is the supplier id from BC 1. 

Does that make sense to have the same entity in 2 bounded contexts? Is it normal that the only attribute to be present in entity is the id?


__._,_.___
Posted by: songoko20000 <at> yahoo.com



__,_._,___
Picon

Many rules for reusability and testability



I have problem similar to this where I need to decide how to deal numerous rules.


I own 10 houses. There are 10 renters. At the end of the month, I check whether all the 10 renters have paid their rent. If they have not paid their rent, I have to send an eviction notice. There are many rules to be checked before sending the eviction notice.


1. Have I sent a reminder to the renter to pay the rent before the end of the month?

2. Have I given the renter a grace period of 5 days after the reminder was sent?

3. Whether or not the renter has his furniture in the house? If he does not have, send the eviction notice immediately else send a warning notification with 10 days grace period.

4. Is the renter living in the house for more than 5 years? If so, send a warning notification with a 30 days grace period to pay the rent.

5. ...


I can think of two entities here OWNER and RENTER. I can also think about


Owner owner = new Owner();

Renter renter = new Renter();

if (owner.Evict(renter))

{

// Let the UI know the renter has been evicted after checking all the rules.

}

else

{

// Let the UI know the renter h as not been evicted because certain rules failed like the renter has not been sent // a reminder.

}


There can be numerous rules to meet the Evict behavior. They are agile, so it can change during the development. They also need to be tested.


When I looked at some DDD examples, I see that the rules like these are baked into the Evict method. Adding a new rule requires the module that holds he Evict method need to be compiled. I would rather test HasRenterBeenSentAReminder rather than a Evict method.


What pattern I can follow to implement a kind of Business Rules Engine in DDD?


Thanks.




__._,_.___
Posted by: varghese.pallathu <at> yahoo.com



__,_._,___
Picon

Conceptual Vs Data Vs Domain model



I'm trying to change the mindset of my data model design to design a Catalog, Products and Category domain model.


The conceptual model: 


Catalog contains Products belonging to a Category.


Data Model:


Table Catalog

[

CatalogID

]


Table Product

[

CatalogID (Catalog.CatalogID Foreign Key)

Categ oryID (Category.CategoryID Foreign Key)

]


Table Category

[

CategoryID

]


Domain Model:


The domain model (class model) can be modeled in two ways as following. Thinking about the aggregate root, the Catalog can be an aggregate root.


To me the Model 1 resembles a data model when the Model 2 resembles an aggregate root.


What do you think?


Model 1: 


class Catalog

{

List<Product> Products;

}


class Product

{

Category Category;

}


class Category

{

}


Model 2:


class Catalog

{

List<Category> Categories;

}


class Category

{

List<Product> products;

}


class Product

{

}




__._,_.___
Posted by: varghese.pallathu <at> yahoo.com



__,_._,___
Picon

Usability as core domain?



Hi,

Is it possible for e-commerce business (selling certain services related to event organizing) to have usability as a core domain? The business has few web based applications dealing with various areas of the business. From what I read about DDD most businesses have at some point a core domain (a part of business that brings most value and/or competitive advantage to that business).

It seems that business people want to focus on usability of one of their web based applications as a way for their business to distinguish itself from competitors. I just can't wrap my head how would that fit with DDD. I always pictured a core domain as one where you would make heavy use of tactical DDD patterns and other GoF design patterns. Usability as core domain doesn't fit that picture.

Thanks

  

 




__._,_.___
Posted by: "Stefan A." <acid24 <at> gmail.com>



__,_._,___
Picon

Expanding entity that is agile



I have an entity similar to Product. It has many properties/attributes like Name, Description, few different prices like Original Price, Sales Price, Discounted Price, Cost, Manufacturer etc... Counting all the properties of this Entity that I use, it has 20 properties. To be agile, I see that this Entity can grow by adding new properties.


I'm sure I'm not modelling this Entity properly. I should have all pricing properties as Value objects. And move some properties to a different entity. However, I'm anticipating more properties are added which can ultimately change the version of the Entity. To put this way "Embrace change".


Is there a pattern to make an Entity agile, so a compilation is not needed for the Entity when a property/containing object is added and thus no deployment of the existing Entity is needed?


Is using a Key/Value pairs for this Entity a good practice?


Or use the inheritance with a hierarchy like ProductBase, ProductInfo (derived from ProductBase), ProductSpec1 (derived from ProductInfo), ProductSpec2 (derived from ProductSpec1)? By following this pattern, when a new property is added, I can create a new class called ProductSpec3 and derive from ProductSpec2 and deploy through a new assembly or DLL and don't touch the existin g assemblies.


Thoughts?




__._,_.___
Posted by: varghese.pallathu <at> yahoo.com



__,_._,___
Picon

Aspects as a modelling bridge between OOD and SOA



While Object Oriented approaches are the option of choice for the design of software components, they may fall short when business domains are to be shared by changing applications across architectures. Such functional requirements are better served by services oriented architectures, and aspects oriented approaches may provide a modelling bridge between Object and Service oriented paradigms

Remy

https://caminao.wordpress.com/how-to-represent-objects-and-activities/abstractions/objects-aspects/



__._,_.___
Posted by: caminao <at> gmail.com



__,_._,___
Picon

Is IoC containers harmful for DDD?



I was reading Growing Object-Oriented Software book and came across this article Dependency Injection harmful by Nat Pryce.


I had hard time understanding what Nat is talking in that article. Is he talking about not using the word dependency injection or not using a IoC container to achieve the DI?


I have used Microsoft Unity and MEF before, and they are very convenient in building up the objects. MEF is extremely useful where the parts can be discovered automatically. For example, the core domain depends on pricing service which can be switched to any implementation thr ough Unity as well as MEF. With MEF, just dropping a dll is enough for the domain to pick up the new implementation. Without a IoC or MEF, it would require a lot of code to inject a dependency.






__._,_.___
Posted by: varghese.pallathu <at> yahoo.com



__,_._,___
Picon

Bounded Context with modules in .NET



As I understand, a Bounded Context can contain multiple modules.


Let us take a Product Catalog Bounded Context. This Product Catalog BC can contain modules like CatalogManagement, ProductManagement.


When it is implemented in .net, the CatalogManagement and ProductManagement can be implemented as assemblies. Since they are part of the same Bounded Context, should they be implemented in the same namespace to draw the boundary?


This is my understanding of Bounded Context. The core domain and sub domain are discussed at the problem space while Bounded Conte xt and Module are discussed at the solution space where there are implementations. I don't know how the Bounded Context and Modules are implemented in .NET.


Thanks.



__._,_.___
Posted by: varghese.pallathu <at> yahoo.com



__,_._,___
Picon

Transactionally Consistency in DDD



I'm stuck at a quote from  Vaughn Vernon in his IDDD book. Here it goes:


"An Aggregate is composed of either a single Entity (5) or a cluster of Entities and Value Objects (6) that must remain transactionally consistent throughout the Aggregate’s lifetime." - Implementing DDD by  Vaughn Vernon


I'm trying to understand "transactionally consistent" that is mentioned here. Is it the behavior of the repository that makes sure the aggregate should be consistent when it is read or committed from the database.


Or it the consistency of the aggregate when it is operated in memory and goes through state changes and shows consistent behavior.




__._,_.___
Posted by: varghese.pallathu <at> yahoo.com



__,_._,___

Gmane