Technologies used

For migration of AMALTHEA models, plane java approach has been used ( non EMF) along with the following 3rd party libraries :

Framework for model migration

Using the above specified technologies, eclipse plugin based framework for model migration is developed.

Components of Model Migration Framework

All the above specified components are contributed as extension points in the plugin org.eclipse.app4mc.amalthea.converters.common

Detailed description of each component can be found below:

Converters: This component is responsible for converting the model (xmi) content from one version to another. A Converter component is executed for selected model files and the corresponding referred model files for migration ( each execution is w.r.t. specific model file).

Converter can be registered by adding extension definition for : org.eclipse.app4mc.amalthea.model.converters and defining the following parameters :

First version of APP4MC was 0.7.0

From version 0.9.3 of APP4MC, there will not be any support for migration of AMALTHEA models based on ITEA releases (itea.103, itea.110, itea.111)

Converter dependencies can be specified at the extension level in the following way:


Cache Builders: This component is responsible for building the required cache, by querying the input models or storing the necessary information - > before executing the Converters for specific migration step ( e.g. 0.9.0 to 0.9.1)
Scope of each Cache Builder component is only during a step of model migration ( e.g. 0.9.0 to 0.9.1)

Cache Builder can be registered by adding extension definition for : org.eclipse.app4mc.amalthea.model.converters.cachebuilders and defining the following parameters :

Each Cache Builder component is tightly coupled to a specific AMALTHEA model version

Pre Processor: This component is responsible for fetching/modifying specific information before invocation of Cache Builders/Converters components.

This component is tightly coupled to input version of the AMALTHEA model files which are selected (explicitly/implicitly) for model migration. Each Pre-Processor component is executed only once for the input model files, irrespective of number of migration steps.

Pre Processor component can be registered by adding extension definition for : org.eclipse.app4mc.amalthea.model.converters.preprocessor and defining the following parameters :

Each Pre processor component is tightly coupled to the specified AMALTHEA model versions

Post Processor: This component is responsible for adding/modifying specific information after invocation of Cache Builders/Converters components for a specific migration step ( e.g. 0.9.0 to 0.9.1)

This component is tightly coupled to input and output version of the AMALTHEA model files which are selected (explicitly/implicitly) for model migration. Each Pre-Processor component is executed after the migration step if the below criteria is full filled:

Post Processor component can be registered by adding extension definition for : org.eclipse.app4mc.amalthea.model.converters.postprocessor and defining the following parameters :

Example how Post-Processor’s are invoked:

If Post-Processor is defined with input-model-versions :0.9.0, 0.9.1 and output version 0.9.2.In case if the migration is invoked from 0.9.0 to 0.9.2 for the specified AMALTHEA models.Following migration steps are to be performed internally:

In this case post-processor is invoked after migration step 0.9.1 to 0.9.2

Flexibility of post-processors is, they are defined in a generalized way to specify in the direction which they should be invoked as a part of model migration.

Model migration sequence

Sequence in which various components are invoked during model migration

How to add custom Model Migration components

As described above, Model Migration framework is part of org.eclipse.app4mc.amalthea.converters.common plugin. This plugin should be added as a dependency to the custom plugin which shall contain Model Migration components.

Below are the various extension points available as a part of Model Migration framework:

For defining custom Model Migration, minimum requirement is to define a extension for org.eclipse.app4mc.amalthea.model.converters extension point and specify the class which has the implementation for migrating the model contents.

CacheBuilders, PreProcessor, PostProcessor components are optional - > based on the scenarios to migrate the model elements, it must me decided if these components are required.