Re: Versioning your Model with NoSQL storage

Greg Young <[email protected]>
Newsgroups gmane.comp.programming.domain-driven-design
Message-ID <CAC9RQtjiBUeR6G5deOvDDmCYPZqWtfKU+TKRRr3+TNCGdVw3Dg@mail.gmail.com>
These are certainly issues with any storage system. There are a few things
you can look at.

1) use weak versioning. Make additive/deleting changes to documents don't
rename things etc. At that point a simple json serializer should help. It
will also allow any version to read any version
2) use a view system of underlying documents. Transform them into the way
you want to see them.

There are however some more sinister changes with these models. Namely what
happens when you have to repartition documents. As an example consider
Vehicle and Engine that used to be a single aggregate vehicle but you
realize that engines have lifecycles independent of vehicles .... This
would require separating the vehicle documents.

These kinds of issues exist in all systems. NoSQL databases are strong at
handling some (as are SQL databases).

Cheers,

Greg

On Tue, Apr 2, 2013 at 12:03 PM, Wim van Gool <[email protected]> wrote:

> **
>
>
> I''m sure this topic has been discussed before, but if it has been, I
> can't seem to find it through search. What I basically would like to know
> is how people deal with versioning their domain model in relation to the
> storage type they use, primarily in the case of using NoSQL storage
> mechanisms.
>
> Versioning using a RDBMS has been a widely discussed topic because so many
> people still use a RDBMS for their domain models in combination with some
> ORM-framework. All sorts of guidance and tooling has been available for a
> while, so I'm not interested in this kind of versioning. Moreover, domain
> models are very well suited to store 'in a simpler way'.
>
> It gets interesting when you choose to store your domain model/aggregates
> using NoSQL alternatives, such as KeyValue-storage, by serializing your
> aggregates into some sort of binary or json format or using plain files.
> How do people cope with versioning in these cases? What if entire model
> refactorings have to be made while you're already in production?
>
> A few (real world) examples would be nice, thanks.
>
>  
>



-- 
Le doute n'est pas une condition agréable, mais la certitude est absurde.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.