Vision is to use them to tag code to be able to visualize hierarchical
and zoomable design of the model:
http://code.google.com/p/ddd-cqrs-sample/wiki/DomainDrivenDesignBusinessDeveloperMentalModel#Expressing_Design_using_Custom_AnnotationsVisual tool should behave just like prezi:
http://prezi.com/hi2dmhfej9zu/ddd-cqrs-sample/So we can see modules, than aggregates, and digging *inside*
aggregates we will see aggregates entities. All uml tools draws flat
picture that is hard to grasp when dealing with large models.
It would be also nice to "teach" hibernate that @DomainAggregateRoot,
@DomainEntity means @Entity in JPA world. So that we do not need to
add both @DomainEntity and @Entity annotations - it should be able to
add just @DomainEntity. Just like in Spring, we can create custom
annotations that are annotated with @Component and @Service. But I
guess that need to go into deep guts each JPA impl...
Sławek Sobótka