I have begun to realize that a major flaw in the general thinking about the Query API is that, along the thinking of the CommandQuery separation discussion on the DDD list, there is not generally a relation between the domain model and queries. If there is, that's a coincidence more than anything else. The reason is that the queries support the clients view and the operations to be performed, which is not necessarily related to how the domain model is structured. I have this case myself now, where the queries to support the client are sort of different from how the domain model is constructed. The client has "views" of the domain model, rather than the domain model. In this case there is meaning to "use the domain model" to construct the query where-expression.

Aren't you talking about Bounded Contexts here? I guess what you mean by "view" is a Bounded Context in DDD terms...

If so, I would say that queries are very much domain related, just in a different BC, which means that it may not necessarily be the same as the model as seen in the "principal" BC (i.e. the one in which the objects were constructed).


Cheers,
=David



_______________________________________________
qi4j-dev mailing list
[email protected]
http://lists.ops4j.org/mailman/listinfo/qi4j-dev

Reply via email to