Open trevorkerby opened 3 years ago
Hi @trevorkerby
Thank you very much for reporting this one!
You are absolutely right, I can only agree with you! :+1:
We have this issue (known limitation) only for technical reasons and not because we wanted to have this behavior... Basically we have to implement a proper scoping mechanism for our Xtext language, but I did not have the time so far. We also have the problem that one can simply reference domain objects within other bounded contexts without creating a relationship between the contexts.
We definitively have to fix this one and its one with high priority.
I'll keep you posted!
Wow, that's fantastic news! I kind of figured that it stemmed from a technical limitation, but from my research I've found some individuals who seem to argue against the inclusion of these false cognates. Being that I'm still learning Domain Driven Design I wanted to make sure that I presented my concern with some support and reasoning. I'm happy to hear that we agree.
Thank you for the quick and reassuring response!
As I understand it, in Domain Driven Design, concepts that happen to share the same name as another concept is an understood occurrence and it's not necessarily in line with the philosophy of Domain Driven Design to avoid such occurrences. This could very well include aggregates. Is that not one of the reasons we use Bounded Contexts?
On page 48 of Implementing Domain Driven Design Vaughn Vernon writes:
In Writing Great Specifications Kamil Nicieja mentions:
The Context Mapper DSL is simply awesome - I appreciate being able to utilize it within my project. It is however concerning that it appears, based on the documentation and errors being reported in my IDE, to suggest that I must effectively modify my Ubiquitous Language to use it properly. Maybe I should in the case of Artist, but it seems foreseeable that I will almost certainly run into further conflicts down the road. Having to come up with potentially unnatural names that will avoid collisions with future concepts in separate bounded contexts adds a fair amount of concern in addition to the already very particular nature of Domain Driven Design.
I understand that some people believe that false cognates are dangerous, but while how good of a practice this is appears to be debated it does seem clear that Domain Driven Design does indeed support their existence. In my project they do exist, but I'd still like to use the Context Mapper DSL. Is there any way around this issue without modifying my ubiquitous language? If not currently, is there a chance that Context Mapper DSL will be able to support aggregates with the same name but in different bounded contexts in the future?
Thank you for your time!