Re:The Ideal Domain-Driven Design Aggregate Store?
by bdavisx on Tuesday December 09, 2014 @12:41PM
(#8724226)
I'm not disagreeing, but I guess I was comparing a relational schema to a JSON "schema".
I do agree a mapper is less intrusive than either. I think I have a bias right now because I've been working on an event sourced model that's using JSON as the serialization mechanism :).
* The objects don't know about the mapper * The DB doesn't know about the mapper
The "ideal DDD aggregate store" with a "schemaless type of store such as JSON" on the other hand binds the implicit schema to your objects. Seems more interlocking and less modular to me.
E.g. I'd rather settle on "this Mapper is the bridge, whatever it does" instead of "the bridge is implicitly defined by however I entangle objects and store".
Boils down to the old inheritance vs composition.