title: Preferred way of data upgrade considering abstraction of data storage format
body: <p>The core question is how to properly execute upgrade of data while applications versions differ in matter of data representation? E.g. for databases it is often to use SQL scripts to modify persisted data model. I can easily imagine similar way using XSL for XML and so on. But I would like to create abstraction of data persistence model in that way that upgrade method does not consider way of storing data - it is suffice that it can read previous version data and save new ones.</p>
  
  <p>I tried doing such thing in C# like loading previous version of assembly containing data definition classes through reflection while having current version deployed with application. It is quite complex and tricky solution. Other option is to keep previous model classes redundantly with some version based naming convension - this solution is easier as it gives full access to types at compile time.</p>
  
  <p>My idea asking this question is, what is the proper solution of such upgrades of data?</p>