Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Epsilon » Problem with running ETL in ANT
Problem with running ETL in ANT [message #1752519] Tue, 24 January 2017 16:36 Go to next message
Bugra M. Yildiz is currently offline Bugra M. YildizFriend
Messages: 106
Registered: July 2014
Senior Member
Hello,

Context:

I am trying to run a model transformation using ANT. I have Model 1 and Model 2, conforming to Metamodel A and Metamodel B. Metamodel B is an extension of Metamodel A; and Model 2's elements refer to elements of Model 1. The transformation takes both models and updates Model 1.

Problem:

The model transformation works perfectly when I run it using the configuration in Eclipse (screenshots are attached.).

However, it does not run correctly using ANT. ANT file is given below. ANT execution finds the models, metamodels (registered beforehand) and the transformation together with its referenced EOL files correctly. It executes the transformation. Then, the following error occurs:

EXCEPTION: Property 'start' not found in object org.eclipse.emf.ecore.impl.DynamicEObjectImpl@1d6dcd79 [eProxyURI: ...


ANT file:

<project default="main">	
	<!-- This transformation works fine in the normal case, however it does not run in ANT file. -->	
	
	<target name="main">
		
		<epsilon.emf.loadModel name="Model 1"
			read="true"
			store="true"
			metamodeluri="metamodel A uri"
			modelfile="absolute path of Model 1"
		/>
		
		<epsilon.emf.loadModel name="Model 2"
			read="true"
			store="false"
			metamodeluri="metamodel B uri"
			modelfile="absolute path of Model 2"
		/>		
	
		<epsilon.etl src="absolute path of the transformation ...Transformation.etl">
			<model ref="Model 1"/>
			<model ref="Model 2"/>						
		</epsilon.etl>
	</target>
</project>


Launch configuration:

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<launchConfiguration type="org.eclipse.ant.AntLaunchConfigurationType">
	<booleanAttribute key="editedByExternalToolsMainTab" value="true"/>
	<booleanAttribute key="org.eclipse.ant.ui.DEFAULT_VM_INSTALL" value="false"/>
	<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS">
	<listEntry value="<Ant file relative path>"/>
	</listAttribute>
	<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES">
	<listEntry value="1"/>
	</listAttribute>
	<booleanAttribute key="org.eclipse.jdt.launching.ATTR_USE_START_ON_FIRST_THREAD" value="true"/>
	<stringAttribute key="org.eclipse.jdt.launching.CLASSPATH_PROVIDER" value="org.eclipse.ant.ui.AntClasspathProvider"/>
	<stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value="<name of the project>"/>
	<stringAttribute key="org.eclipse.jdt.launching.SOURCE_PATH_PROVIDER" value="org.eclipse.ant.ui.AntClasspathProvider"/>
	<stringAttribute key="org.eclipse.ui.externaltools.ATTR_LOCATION" value="${workspace_loc:<Ant file relative path>}"/>
	<stringAttribute key="process_factory_id" value="org.eclipse.ant.ui.remoteAntProcessFactory"/>
</launchConfiguration>


Note: I could not provide the full project since it is commercial. If you have a quick proposal, I will try. Otherwise, I can try to provide a minimal example.

Thanks.
Re: Problem with running ETL in ANT [message #1752521 is a reply to message #1752519] Tue, 24 January 2017 16:40 Go to previous messageGo to next message
Dimitris Kolovos is currently offline Dimitris KolovosFriend
Messages: 1551
Registered: July 2009
Location: York, UK
Senior Member

Hi Bugra,

I can't see what may be going wrong; your ANT file looks fine at a first glance. A minimal example would help a lot.

Cheers,
Dimitris
Re: Problem with running ETL in ANT [message #1752845 is a reply to message #1752521] Sat, 28 January 2017 19:07 Go to previous messageGo to next message
Bugra M. Yildiz is currently offline Bugra M. YildizFriend
Messages: 106
Registered: July 2014
Senior Member
I have attached a minimal example.

Thank you.
Re: Problem with running ETL in ANT [message #1752888 is a reply to message #1752845] Mon, 30 January 2017 11:17 Go to previous messageGo to next message
Dimitris Kolovos is currently offline Dimitris KolovosFriend
Messages: 1551
Registered: July 2009
Location: York, UK
Senior Member

Hi Bugra,

Adding expand="true" (the equivalent of "Include external references" in your model configuration dialog) to your epsilon.emf.loadModel tasks seems to be doing the trick.

Cheers,
Dimitris
Re: Problem with running ETL in ANT [message #1752898 is a reply to message #1752888] Mon, 30 January 2017 12:21 Go to previous messageGo to next message
Bugra M. Yildiz is currently offline Bugra M. YildizFriend
Messages: 106
Registered: July 2014
Senior Member
Hello Dimitris, I have tried in the toy example. It worked fine. However, for my real example, I still can't execute the transformation through ANT file.
Re: Problem with running ETL in ANT [message #1752899 is a reply to message #1752898] Mon, 30 January 2017 12:24 Go to previous messageGo to next message
Dimitris Kolovos is currently offline Dimitris KolovosFriend
Messages: 1551
Registered: July 2009
Location: York, UK
Senior Member

I'm sorry to hear that. Are you getting the same error or a different one?

Cheers,
Dimitris
Re: Problem with running ETL in ANT [message #1752919 is a reply to message #1752899] Mon, 30 January 2017 16:40 Go to previous message
Bugra M. Yildiz is currently offline Bugra M. YildizFriend
Messages: 106
Registered: July 2014
Senior Member
I have fixed it this one. The last one was a problem with my transformation. expand="true" works fine. Thanks for helping me out. I will report back on the other question in the other post soon.
Previous Topic:Solution for exceeding the 65535 bytes limit error
Next Topic:A problem with model transformations with element deletions on dependent models
Goto Forum:
  


Current Time: Mon Jun 25 16:10:07 GMT 2018

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

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

Back to the top