Chapter 30. Upgrading a ModelLibrary

This needs to be done when changes have been made to the XSDDB and associated transforms which are incompatible with the current reload data. This recipe assumes that a working copy exists of the ModelLibrary to upgrade and that this is the current working directory.

After installing an upgraded version of Theon packages do the following.

(1) Rebuild the reload data using the newly installed version.

THEON_MODEL_XSLT_PATH=/usr/share/theon/self/xslt ttkm derive ddldata

The new reload data will be in derived/model/reload.

(2) Attempt a reload using the new data.

ttkm -d reload

This should just work if the new version is backwards compatible. If not temporary manual tweaks may be required either to the XSDDB structure or to the reload data files. When this is the case the upgrade should either include a list of the steps to take or include a script to automatically apply the changes.

(3) Export the upgraded schema tree.

ttkm export

Then sanity check the differences in schemat to ensure they are as expected (correspond to changes made in the upgraded version) and commit.

Prior to committing a QA test is prudent to ensure that the new version does not break the ModelLibrary. This is achieved by ensuring that a derived DDL can be physically realised and when dumped is identical (with the exception of any expected changes in the upgrade), and that where applicable derived UI data sets and documentation is identical (again with the exception of any expected changes that are as a result of the upgrade).