Our product has a requirement that full compatability must be maintained accross code and data versions. What this means is that even when the data schema changes, old code must still be able to startup and use the new database schema (with the same old functionality). This also means that a new version of the code needs to be able to read an older version of the schema (with reduced functionality).
The first problem can be solved by never deleting any data. Adding tables and columns is ok, but no data can ever be removed. This may cause performance problems, but can work. Hibernate has no problems ignoring unused columns or tables in a database.
The second problem is where my question lies. As soon as Hibernate starts up, it validates that the schema matches the descriptions in the .hbm.xml files. When the new schema has new fields or tables, and tha database has not been upgraded to the new version, Hibernate will fail since the schema does not match the mapping.
Is there any support in Hibernate to help with this problem?
Thanx,
Jim
|