Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF "Technology" (Ecore Tools, EMFatic, etc)  » [Edapt] Migrate programmatically - Incorrect strategy?
[Edapt] Migrate programmatically - Incorrect strategy? [message #1012887] Fri, 22 February 2013 11:39 Go to next message
Kirsten M. Z. is currently offline Kirsten M. Z.
Messages: 131
Registered: July 2010
Senior Member
Hi there and thanks for your efforts on Edapt so far.

Edapt is exactly what is needed in our project. However, we are not able to get everything working well right now. I have to mention that Edapt (UI) does not run on Juno/Kepler. Some error messages, missing buttons etc. Therefore, we cannot use Edapt as expected and it is hard to learn how Edapt works.

However, this is not the actual problematic spot. We need to migrate programmatically, so we started investigating the code anyway. Due to the lack of advanced documentation and examples, it was hard to get the first steps working. A very simple use case (renaming of an attribute) worked. A slightly more difficult case does not work (deletion of an attribute and creation of a new attribute). The console output:

Migrate...
Release 1
Step 1
Step 2
Step 3
Step 4
Step 5
Step 6
Step 7
...done
Exception in thread "main" java.lang.IllegalArgumentException: The feature 'name' is not a valid changeable feature
	at org.eclipse.emf.ecore.impl.BasicEObjectImpl.eOpenSet(BasicEObjectImpl.java:1145)
	at org.eclipse.emf.ecore.impl.BasicEObjectImpl.eSet(BasicEObjectImpl.java:1075)
	at org.eclipse.emf.edapt.migration.BackwardConverter.initProperties(BackwardConverter.java:145)
	at org.eclipse.emf.edapt.migration.BackwardConverter.initProperties(BackwardConverter.java:109)
	at org.eclipse.emf.edapt.migration.BackwardConverter.convert(BackwardConverter.java:54)
	at org.eclipse.emf.edapt.migration.Persistency.saveModel(Persistency.java:109)
	at org.eclipse.emf.edapt.migration.execution.Migrator.migrateAndSave(Migrator.java:162)
	at MinimalExample.main(MinimalExample.java:66)


Ok, I don't think that the problem is Edapt. I really think that the Problem is our code or the arrangement of our files. The solution is probably very easy. However, we have no idea how Edapt is expected to work. Before I post all the code of a minimal example and required files, here the arrangement:

****************************************

AClassInstance.xmi ---- meta ----> MyLibraryOld.ecore

MyLibrary.ecore (copy of "MyLibraryOld.ecore") ---- refactor ----> MyLibrary.ecore + MyLibrary.hist (the Edapt history of changes)

AClassInstance.xmi ---- migration using the history ----> AClassInstance.xmi ***crash***

****************************************

All the code and the files we got so far. I will also try attaching them.

public class MinimalExample {

	/**
	 * @param args
	 */
	public static void main(String[] args) {

		Resource.Factory.Registry.INSTANCE.getExtensionToFactoryMap().put("*",
				new XMIResourceFactoryImpl());

		ResourceSet resourceSet = new ResourceSetImpl();
		resourceSet.getPackageRegistry().put(HistoryPackage.eNS_URI,
				HistoryPackage.eINSTANCE);

		Resource resource = resourceSet.getResource(
				URI.createFileURI("T:\\AClassInstance.xmi"), true);
		Resource resourceHistory = resourceSet.getResource(
				URI.createFileURI("T:\\MyLibrary.hist"), true);

		History history = (History) resourceHistory.getContents().get(0);

		Migrator mig = new Migrator(history, new ClassLoaderFacade(Thread
				.currentThread().getContextClassLoader()));
		// mig.setLevel(ValidationLevel.HISTORY);
		mig.setLevel(ValidationLevel.NONE);

		List<URI> uris = new ArrayList<URI>();
		uris.add(resource.getURI());

		LibraryExtractor libex = new LibraryExtractor();
		Library lib = libex.extractLibrary(BaseLibrary.class);

		OperationRegistry.getInstance()
				.registerLibrary(lib.getImplementation());

		try {
			mig.migrateAndSave(uris, history.getFirstRelease(), history
					.getLastRelease(), new PrintStreamProgressMonitor(
					System.out));
		} catch (MigrationException e) {
			e.printStackTrace();
		}

	}
}


AClassInstance.xmi

<?xml version="1.0" encoding="ASCII"?>
<ml:AClass xmi:version="2.0"
    xmlns:xmi="http://www.omg.org/XMI"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xmlns:ml="http://www.example.org/MyLibrary"
    xsi:schemaLocation="http://www.example.org/MyLibrary MyLibraryOld.ecore"
    name="Simple Name"/>


MyLibraryOld.ecore

<?xml version="1.0" encoding="UTF-8"?>
<ecore:EPackage xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="MyLibrary" nsURI="http://www.example.org/MyLibrary" nsPrefix="ml">
  <eClassifiers xsi:type="ecore:EClass" name="AClass">
    <eStructuralFeatures xsi:type="ecore:EAttribute" name="name" lowerBound="1">
      <eType xsi:type="ecore:EDataType" href="http://www.eclipse.org/emf/2002/Ecore#//EString"/>
    </eStructuralFeatures>
  </eClassifiers>
</ecore:EPackage>


MyLibrary.ecore

<?xml version="1.0" encoding="UTF-8"?>
<ecore:EPackage xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="MyLibrary" nsURI="http://www.example.org/MyLibrary" nsPrefix="ml">
  <eAnnotations source="http://www.eclipse.org/edapt">
    <details key="historyURI" value="MyLibrary.hist"/>
  </eAnnotations>
  <eClassifiers xsi:type="ecore:EClass" name="AClass">
    <eStructuralFeatures xsi:type="ecore:EAttribute" name="AnotherProp" lowerBound="1"
        eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EInt" defaultValueLiteral="0"/>
  </eClassifiers>
</ecore:EPackage>


MyLibrary.hist

<?xml version="1.0" encoding="ASCII"?>
<history:History xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" xmlns:history="http://www.eclipse.org/emf/edapt/history/0.3">
  <releases date="2013-02-22T12:04:33.758+0100" label="Initial">
    <changes xsi:type="history:CompositeChange">
      <changes xsi:type="history:Create">
        <element href="MyLibrary.ecore#/"/>
        <changes xsi:type="history:Set" featureName="name" dataValue="MyLibrary">
          <element href="MyLibrary.ecore#/"/>
        </changes>
        <changes xsi:type="history:Set" featureName="nsURI" dataValue="http://www.example.org/MyLibrary">
          <element href="MyLibrary.ecore#/"/>
        </changes>
        <changes xsi:type="history:Set" featureName="nsPrefix" dataValue="ml">
          <element href="MyLibrary.ecore#/"/>
        </changes>
      </changes>
      <changes xsi:type="history:Create" referenceName="eAnnotations">
        <target href="MyLibrary.ecore#/"/>
        <element href="MyLibrary.ecore#//%http:%2F%2Fwww.eclipse.org%2Fedapt%"/>
        <changes xsi:type="history:Set" featureName="source" dataValue="http://www.eclipse.org/edapt">
          <element href="MyLibrary.ecore#//%http:%2F%2Fwww.eclipse.org%2Fedapt%"/>
        </changes>
      </changes>
      <changes xsi:type="history:Create" referenceName="details">
        <target href="MyLibrary.ecore#//%http:%2F%2Fwww.eclipse.org%2Fedapt%"/>
        <element href="MyLibrary.ecore#//%http:%2F%2Fwww.eclipse.org%2Fedapt%/@details.0"/>
        <changes xsi:type="history:Set" featureName="key" dataValue="historyURI">
          <element href="MyLibrary.ecore#//%http:%2F%2Fwww.eclipse.org%2Fedapt%/@details.0"/>
        </changes>
        <changes xsi:type="history:Set" featureName="value" dataValue="MyLibrary.hist">
          <element href="MyLibrary.ecore#//%http:%2F%2Fwww.eclipse.org%2Fedapt%/@details.0"/>
        </changes>
      </changes>
      <changes xsi:type="history:Create" referenceName="eClassifiers">
        <target href="MyLibrary.ecore#/"/>
        <element href="MyLibrary.ecore#//AClass"/>
        <changes xsi:type="history:Set" featureName="name" dataValue="AClass">
          <element href="MyLibrary.ecore#//AClass"/>
        </changes>
      </changes>
      <changes xsi:type="history:Create" referenceName="eStructuralFeatures" element="//@releases.1/@changes.0/@element">
        <target href="MyLibrary.ecore#//AClass"/>
        <changes xsi:type="history:Set" element="//@releases.1/@changes.0/@element" featureName="name" dataValue="name"/>
        <changes xsi:type="history:Set" element="//@releases.1/@changes.0/@element" featureName="lowerBound" dataValue="1" oldDataValue="0"/>
        <changes xsi:type="history:Set" element="//@releases.1/@changes.0/@element" featureName="eType">
          <referenceValue href="http://www.eclipse.org/emf/2002/Ecore#//EString"/>
        </changes>
      </changes>
    </changes>
  </releases>
  <releases>
    <changes xsi:type="history:Delete" referenceName="eStructuralFeatures">
      <target href="MyLibrary.ecore#//AClass"/>
      <element xsi:type="ecore:EAttribute" name="name" lowerBound="1">
        <eType xsi:type="ecore:EDataType" href="http://www.eclipse.org/emf/2002/Ecore#//EString"/>
      </element>
    </changes>
    <changes xsi:type="history:Create" referenceName="eStructuralFeatures">
      <target href="MyLibrary.ecore#//AClass"/>
      <element href="MyLibrary.ecore#//AClass/AnotherProp"/>
    </changes>
    <changes xsi:type="history:Set" featureName="name" dataValue="AnotherProp">
      <element href="MyLibrary.ecore#//AClass/AnotherProp"/>
    </changes>
    <changes xsi:type="history:Set" featureName="eType">
      <element href="MyLibrary.ecore#//AClass/AnotherProp"/>
      <referenceValue href="http://www.eclipse.org/emf/2002/Ecore#//EInt"/>
    </changes>
    <changes xsi:type="history:Set" featureName="defaultValueLiteral" dataValue="">
      <element href="MyLibrary.ecore#//AClass/AnotherProp"/>
    </changes>
    <changes xsi:type="history:Set" featureName="defaultValueLiteral" dataValue="0" oldDataValue="">
      <element href="MyLibrary.ecore#//AClass/AnotherProp"/>
    </changes>
    <changes xsi:type="history:Set" featureName="lowerBound" dataValue="1" oldDataValue="0">
      <element href="MyLibrary.ecore#//AClass/AnotherProp"/>
    </changes>
  </releases>
</history:History>

[Updated on: Fri, 22 February 2013 11:39]

Report message to a moderator

Re: [Edapt] Migrate programmatically - Incorrect strategy? [message #1014694 is a reply to message #1012887] Tue, 26 February 2013 09:44 Go to previous messageGo to next message
Maximilian Koegel is currently offline Maximilian Koegel
Messages: 199
Registered: July 2009
Senior Member
Hi Kirsten,

thank you for reporting your issue with Edapt!
I am not sure if this causes the problem, but did you try to obtain the
migrator with the code from the tutorial:
http://www.eclipse.org/edapt/libraryexample.php#migrator

Cheers,
Maximilian

Am 22.02.2013 12:39, schrieb Kirsten M. Z.:
> Hi there and thanks for your efforts on Edapt so far.
>
> Edapt is exactly what is needed in our project. However, we are not able to get everything working well right now. I have to mention that Edapt (UI) does not run on Juno/Kepler. Some error messages, missing buttons etc. Therefore, we cannot use Edapt as expected and it is hard to learn how Edapt works.
>
> However, this is not the actual problematic spot. We need to migrate programmatically, so we started investigating the code anyway. Due to the lack of advanced documentation and examples, it was hard to get the first steps working. A very simple use case (renaming of an attribute) worked. A slightly more difficult case does not work (deletion of an attribute and creation of a new attribute). The console output:
>
> Migrate...
> Release 1
> Step 1
> Step 2
> Step 3
> Step 4
> Step 5
> Step 6
> Step 7
> ..done
> Exception in thread "main" java.lang.IllegalArgumentException: The feature 'name' is not a valid changeable feature
> at org.eclipse.emf.ecore.impl.BasicEObjectImpl.eOpenSet(BasicEObjectImpl.java:1145)
> at org.eclipse.emf.ecore.impl.BasicEObjectImpl.eSet(BasicEObjectImpl.java:1075)
> at org.eclipse.emf.edapt.migration.BackwardConverter.initProperties(BackwardConverter.java:145)
> at org.eclipse.emf.edapt.migration.BackwardConverter.initProperties(BackwardConverter.java:109)
> at org.eclipse.emf.edapt.migration.BackwardConverter.convert(BackwardConverter.java:54)
> at org.eclipse.emf.edapt.migration.Persistency.saveModel(Persistency.java:109)
> at org.eclipse.emf.edapt.migration.execution.Migrator.migrateAndSave(Migrator.java:162)
> at MinimalExample.main(MinimalExample.java:66)
>
> Ok, I don't think that the problem is Edapt. I really think that the Problem is our code or the arrangement of our files. The solution is probably very easy. However, we have no idea how Edapt is expected to work. Before I post all the code of a minimal example and required files, here the arrangement:
>
> ****************************************
>
> AClassInstance.xmi ---- meta ----> MyLibraryOld.ecore
>
> MyLibrary.ecore (copy of "MyLibraryOld.ecore") ---- refactor ----> MyLibrary.ecore + MyLibrary.hist (the Edapt history of changes)
>
> AClassInstance.xmi ---- migration using the history ----> AClassInstance.xmi ***crash***
>
> ****************************************
>
> All the code and the files we got so far. I will also try attaching them.
>
>
> public class MinimalExample {
>
> /**
> * @param args
> */
> public static void main(String[] args) {
>
> Resource.Factory.Registry.INSTANCE.getExtensionToFactoryMap().put("*",
> new XMIResourceFactoryImpl());
>
> ResourceSet resourceSet = new ResourceSetImpl();
> resourceSet.getPackageRegistry().put(HistoryPackage.eNS_URI,
> HistoryPackage.eINSTANCE);
>
> Resource resource = resourceSet.getResource(
> URI.createFileURI("T:\\AClassInstance.xmi"), true);
> Resource resourceHistory = resourceSet.getResource(
> URI.createFileURI("T:\\MyLibrary.hist"), true);
>
> History history = (History) resourceHistory.getContents().get(0);
>
> Migrator mig = new Migrator(history, new ClassLoaderFacade(Thread
> .currentThread().getContextClassLoader()));
> // mig.setLevel(ValidationLevel.HISTORY);
> mig.setLevel(ValidationLevel.NONE);
>
> List<URI> uris = new ArrayList<URI>();
> uris.add(resource.getURI());
>
> LibraryExtractor libex = new LibraryExtractor();
> Library lib = libex.extractLibrary(BaseLibrary.class);
>
> OperationRegistry.getInstance()
> .registerLibrary(lib.getImplementation());
>
> try {
> mig.migrateAndSave(uris, history.getFirstRelease(), history
> .getLastRelease(), new PrintStreamProgressMonitor(
> System.out));
> } catch (MigrationException e) {
> e.printStackTrace();
> }
>
> }
> }
>
> AClassInstance.xmi
>
> <?xml version="1.0" encoding="ASCII"?>
> <ml:AClass xmi:version="2.0"
> xmlns:xmi="http://www.omg.org/XMI"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xmlns:ml="http://www.example.org/MyLibrary"
> xsi:schemaLocation="http://www.example.org/MyLibrary MyLibraryOld.ecore"
> name="Simple Name"/>
>
> MyLibraryOld.ecore
>
> <?xml version="1.0" encoding="UTF-8"?>
> <ecore:EPackage xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="MyLibrary" nsURI="http://www.example.org/MyLibrary" nsPrefix="ml">
> <eClassifiers xsi:type="ecore:EClass" name="AClass">
> <eStructuralFeatures xsi:type="ecore:EAttribute" name="name" lowerBound="1">
> <eType xsi:type="ecore:EDataType" href="http://www.eclipse.org/emf/2002/Ecore#//EString"/>
> </eStructuralFeatures>
> </eClassifiers>
> </ecore:EPackage>
>
> MyLibrary.ecore
>
> <?xml version="1.0" encoding="UTF-8"?>
> <ecore:EPackage xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="MyLibrary" nsURI="http://www.example.org/MyLibrary" nsPrefix="ml">
> <eAnnotations source="http://www.eclipse.org/edapt">
> <details key="historyURI" value="MyLibrary.hist"/>
> </eAnnotations>
> <eClassifiers xsi:type="ecore:EClass" name="AClass">
> <eStructuralFeatures xsi:type="ecore:EAttribute" name="AnotherProp" lowerBound="1"
> eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EInt" defaultValueLiteral="0"/>
> </eClassifiers>
> </ecore:EPackage>
>
> MyLibrary.hist
>
> <?xml version="1.0" encoding="ASCII"?>
> <history:History xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" xmlns:history="http://www.eclipse.org/emf/edapt/history/0.3">
> <releases date="2013-02-22T12:04:33.758+0100" label="Initial">
> <changes xsi:type="history:CompositeChange">
> <changes xsi:type="history:Create">
> <element href="MyLibrary.ecore#/"/>
> <changes xsi:type="history:Set" featureName="name" dataValue="MyLibrary">
> <element href="MyLibrary.ecore#/"/>
> </changes>
> <changes xsi:type="history:Set" featureName="nsURI" dataValue="http://www.example.org/MyLibrary">
> <element href="MyLibrary.ecore#/"/>
> </changes>
> <changes xsi:type="history:Set" featureName="nsPrefix" dataValue="ml">
> <element href="MyLibrary.ecore#/"/>
> </changes>
> </changes>
> <changes xsi:type="history:Create" referenceName="eAnnotations">
> <target href="MyLibrary.ecore#/"/>
> <element href="MyLibrary.ecore#//%http:%2F%2Fwww.eclipse.org%2Fedapt%"/>
> <changes xsi:type="history:Set" featureName="source" dataValue="http://www.eclipse.org/edapt">
> <element href="MyLibrary.ecore#//%http:%2F%2Fwww.eclipse.org%2Fedapt%"/>
> </changes>
> </changes>
> <changes xsi:type="history:Create" referenceName="details">
> <target href="MyLibrary.ecore#//%http:%2F%2Fwww.eclipse.org%2Fedapt%"/>
> <element href="MyLibrary.ecore#//%http:%2F%2Fwww.eclipse.org%2Fedapt%/@details.0"/>
> <changes xsi:type="history:Set" featureName="key" dataValue="historyURI">
> <element href="MyLibrary.ecore#//%http:%2F%2Fwww.eclipse.org%2Fedapt%/@details.0"/>
> </changes>
> <changes xsi:type="history:Set" featureName="value" dataValue="MyLibrary.hist">
> <element href="MyLibrary.ecore#//%http:%2F%2Fwww.eclipse.org%2Fedapt%/@details.0"/>
> </changes>
> </changes>
> <changes xsi:type="history:Create" referenceName="eClassifiers">
> <target href="MyLibrary.ecore#/"/>
> <element href="MyLibrary.ecore#//AClass"/>
> <changes xsi:type="history:Set" featureName="name" dataValue="AClass">
> <element href="MyLibrary.ecore#//AClass"/>
> </changes>
> </changes>
> <changes xsi:type="history:Create" referenceName="eStructuralFeatures" element="//@releases.1/@changes.0/@element">
> <target href="MyLibrary.ecore#//AClass"/>
> <changes xsi:type="history:Set" element="//@releases.1/@changes.0/@element" featureName="name" dataValue="name"/>
> <changes xsi:type="history:Set" element="//@releases.1/@changes.0/@element" featureName="lowerBound" dataValue="1" oldDataValue="0"/>
> <changes xsi:type="history:Set" element="//@releases.1/@changes.0/@element" featureName="eType">
> <referenceValue href="http://www.eclipse.org/emf/2002/Ecore#//EString"/>
> </changes>
> </changes>
> </changes>
> </releases>
> <releases>
> <changes xsi:type="history:Delete" referenceName="eStructuralFeatures">
> <target href="MyLibrary.ecore#//AClass"/>
> <element xsi:type="ecore:EAttribute" name="name" lowerBound="1">
> <eType xsi:type="ecore:EDataType" href="http://www.eclipse.org/emf/2002/Ecore#//EString"/>
> </element>
> </changes>
> <changes xsi:type="history:Create" referenceName="eStructuralFeatures">
> <target href="MyLibrary.ecore#//AClass"/>
> <element href="MyLibrary.ecore#//AClass/AnotherProp"/>
> </changes>
> <changes xsi:type="history:Set" featureName="name" dataValue="AnotherProp">
> <element href="MyLibrary.ecore#//AClass/AnotherProp"/>
> </changes>
> <changes xsi:type="history:Set" featureName="eType">
> <element href="MyLibrary.ecore#//AClass/AnotherProp"/>
> <referenceValue href="http://www.eclipse.org/emf/2002/Ecore#//EInt"/>
> </changes>
> <changes xsi:type="history:Set" featureName="defaultValueLiteral" dataValue="">
> <element href="MyLibrary.ecore#//AClass/AnotherProp"/>
> </changes>
> <changes xsi:type="history:Set" featureName="defaultValueLiteral" dataValue="0" oldDataValue="">
> <element href="MyLibrary.ecore#//AClass/AnotherProp"/>
> </changes>
> <changes xsi:type="history:Set" featureName="lowerBound" dataValue="1" oldDataValue="0">
> <element href="MyLibrary.ecore#//AClass/AnotherProp"/>
> </changes>
> </releases>
> </history:History>
>


--
Maximilian Kögel

Get Professional Eclipse Support: http://eclipsesource.com/munich
Re: [Edapt] Migrate programmatically - Incorrect strategy? [message #1015863 is a reply to message #1014694] Sun, 03 March 2013 22:57 Go to previous messageGo to next message
Kirsten M. Z. is currently offline Kirsten M. Z.
Messages: 131
Registered: July 2010
Senior Member
I had a hard time debugging into the Edapt code, but I finally found the "problem".
What I had to do is loading the metamodel (the old one) and register the package via

Registry.INSTANCE.put(ePackageHero.getNsURI(), (EPackage) oldMetaModelResource.getContents().get(0));


Afterwards, at least migrateAndLoad works, which does the job.

Would be nice if the development of Edapt would continue and also tutorials would be improved.
Re: [Edapt] Migrate programmatically - Incorrect strategy? [message #1015924 is a reply to message #1015863] Mon, 04 March 2013 09:36 Go to previous messageGo to next message
Maximilian Koegel is currently offline Maximilian Koegel
Messages: 199
Registered: July 2009
Senior Member
OK, great it worked for you and thanks for your feedback!

Am 03.03.2013 23:57, schrieb Kirsten M. Z.:
> I had a hard time debugging into the Edapt code, but I finally found the
> "problem".
> What I had to do is loading the metamodel (the old one) and register the
> package via
> Registry.INSTANCE.put(ePackageHero.getNsURI(), (EPackage)
> oldMetaModelResource.getContents().get(0));
>
> Afterwards, at least migrateAndLoad works, which does the job.
>
> Would be nice if the development of Edapt would continue and also
> tutorials would be improved.


--
Maximilian Kögel

Get Professional Eclipse Support: http://eclipsesource.com/munich
Re: [Edapt] Migrate programmatically - Incorrect strategy? [message #1015963 is a reply to message #1015924] Mon, 04 March 2013 12:33 Go to previous messageGo to next message
Kirsten M. Z. is currently offline Kirsten M. Z.
Messages: 131
Registered: July 2010
Senior Member
Oh, and there was another important issue in my strategy... sorry, that I forgot that in my previous post:

- If the meta model evolves, also the namespace (NS URI) has to be changed, e.g. "http://xxx/v1" => "http://xxx/v2". I found this in an example, but there are not too much hints about that requirement!
Re: [Edapt] Migrate programmatically - Incorrect strategy? [message #1016191 is a reply to message #1015963] Tue, 05 March 2013 12:29 Go to previous messageGo to next message
Maximilian Koegel is currently offline Maximilian Koegel
Messages: 199
Registered: July 2009
Senior Member
Hi,

yes, that´s true, it is the easiest way to evolve, but in general you
can also provide the migrator with manual information of source and
target version for migration. This information could be stored somewhere
else.

Cheers,
Maximilian

Am 04.03.2013 13:33, schrieb Kirsten M. Z.:
> Oh, and there was another important issue in my strategy... sorry, that
> I forgot that in my previous post:
>
> - If the meta model evolves, also the namespace (NS URI) has to be
> changed, e.g. "http://xxx/v1" => "http://xxx/v2". I found this in an
> example, but there are not too much hints about that requirement!


--
Maximilian Kögel

Get Professional Eclipse Support: http://eclipsesource.com/munich
Re: [Edapt] Migrate programmatically - Incorrect strategy? [message #1042764 is a reply to message #1015863] Tue, 16 April 2013 21:08 Go to previous messageGo to next message
Jim Foscue is currently offline Jim Foscue
Messages: 14
Registered: June 2012
Junior Member
Hi. I'm also researching Edapt and so your post. Is there anyway you could send me your minimal example with your solution?

I'm trying to migrate 2 models. Model2 references Model1.

Thanks!
Re: [Edapt] Migrate programmatically - Incorrect strategy? [message #1043261 is a reply to message #1015963] Wed, 17 April 2013 13:35 Go to previous message
Jim Foscue is currently offline Jim Foscue
Messages: 14
Registered: June 2012
Junior Member
Hi. I'm also researching Edapt and so your post. Is there anyway you could send me your minimal example with your solution?

I'm trying to migrate 2 models. Model2 references Model1.

Thanks!
Previous Topic:Validating emf model using OAW framework and Check language
Next Topic:Use of EMFStore with models and GMF diagrams
Goto Forum:
  


Current Time: Mon Oct 20 08:23:46 GMT 2014

Powered by FUDForum. Page generated in 0.02604 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software