When you are making non-compatible changes to your Global Case Data Model you have to upgrade the major version. However, when you are accessing data in a newly deployed process you can only see data from the latest version. For example, when you have a list of customers and you upgrade the major version you won't see all the customers when you search for them in business service. But luckily the data is still there in the database :-) In order to migrate this data, we looked at moving it from one table to another. But I think I found a much more elegant way to do this migration, using the TIBCO ActiveMatrix® BPM API and Classic TIBCO BusinessWorks? (BW). So I created a very simple and easy re-use-BW project to run such a migration:
A case is actually an XML Document, and two versions of an XML document can easily be transformed into each other easily with Business Works. That is the power of BW! So first you have to export the XSD's of both versions of the Case Model, which can be done in Studio:
Then you import these two different XSD's with different names into Designer. Note here that the XSD's actually have the same namespaces, but Designer can handle this, just make sure you import using location:
and not the namespace. Now you just have to make the mapping:
in one place. Configure the global variables:
This will get the old case versions, transforms them and create new versions into the system. Then it will delete the old case so you don't have duplicates in your database. Please note that usually (depending on your mapping and type of Case ID) new case ID's will be generated and since this is an initial version it also does not take linked cases into account, if that is part of your use case you will have to map that yourself.
Attached the BW project and the Business Studio Sample projects.
Happy Coding :-)
For a complete list of compatible and non compatible changes look here:
Docs 4.1 - Upgrading a Case Data Model
Recommended Comments
There are no comments to display.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now