Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » M2T (model-to-text transformation) » Executing JET Transformations in ANT
Executing JET Transformations in ANT [message #35106] Thu, 18 October 2007 19:23 Go to next message
Eclipse UserFriend
Originally posted by: christopher.valorose.kronos.com

Hi,

Is it possible to use ANT to run a JET transformation on a JET Model outside
of Eclipse?

My Eclipse has a plugin that I use to run the JET transformation. The
transformation input is set as ColumnSetJETModel.xml and the transformation
ID is com.kronos.jet.mdd.crud. When I attempt to use
<jet.transform transformid="com.kronos.jet.mdd.crud"
resource="ColumnSetJETModel.xml"/>


I get the following errors:
Cause: The name is undefined.
Action: Check the spelling.
Action: Check that any custom tasks/types have been declared.
Action: Check that any <presetdef>/<macrodef> declarations have taken place.
Any help would be greatly apprecieated.


Thanks
Chris
Re: Executing JET Transformations in ANT [message #35172 is a reply to message #35106] Tue, 23 October 2007 12:23 Go to previous messageGo to next message
Paul Elder is currently offline Paul ElderFriend
Messages: 849
Registered: July 2009
Senior Member
Chris:

Yes and no.

No, JET requires Eclipse. Yes, you can use the jet.transform task in a
headless Ant build, so long as you use the Eclipse ant runner:

eclipse -application org.eclipse.ant.core.antRunner
your-ant-command-line-arguments-go-here

Paul

"Chris" <christopher.valorose@kronos.com> wrote in message
news:ff8br7$vpo$1@build.eclipse.org...
> Hi,
>
> Is it possible to use ANT to run a JET transformation on a JET Model
> outside of Eclipse?
>
> My Eclipse has a plugin that I use to run the JET transformation. The
> transformation input is set as ColumnSetJETModel.xml and the
> transformation ID is com.kronos.jet.mdd.crud. When I attempt to use
> <jet.transform transformid="com.kronos.jet.mdd.crud"
> resource="ColumnSetJETModel.xml"/>
>
>
> I get the following errors:
> Cause: The name is undefined.
> Action: Check the spelling.
> Action: Check that any custom tasks/types have been declared.
> Action: Check that any <presetdef>/<macrodef> declarations have taken
> place.
> Any help would be greatly apprecieated.
>
>
> Thanks
> Chris
>
>
Re: Executing JET Transformations in ANT [message #36373 is a reply to message #35172] Fri, 16 November 2007 19:39 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: christopher.valorose.kronos.com

Paul,

I have tried running the following command from the command line:
"eclipse -application org.eclipse.ant.core.antRunner build.xml"

I see the Eclispe slash screen appear and that is it. The default target in
my build.xml file does not seem to get executed. Should the eclispe command
be run form a command line?
Would Eclispe write any log files anywhere that I can get a sense of what is
going on?
Is my command correct?

Chris


"Paul Elder" <pelder@ca.ibm.com> wrote in message
news:ffkp64$api$1@build.eclipse.org...
> Chris:
>
> Yes and no.
>
> No, JET requires Eclipse. Yes, you can use the jet.transform task in a
> headless Ant build, so long as you use the Eclipse ant runner:
>
> eclipse -application org.eclipse.ant.core.antRunner
> your-ant-command-line-arguments-go-here
>
> Paul
>
> "Chris" <christopher.valorose@kronos.com> wrote in message
> news:ff8br7$vpo$1@build.eclipse.org...
>> Hi,
>>
>> Is it possible to use ANT to run a JET transformation on a JET Model
>> outside of Eclipse?
>>
>> My Eclipse has a plugin that I use to run the JET transformation. The
>> transformation input is set as ColumnSetJETModel.xml and the
>> transformation ID is com.kronos.jet.mdd.crud. When I attempt to use
>> <jet.transform transformid="com.kronos.jet.mdd.crud"
>> resource="ColumnSetJETModel.xml"/>
>>
>>
>> I get the following errors:
>> Cause: The name is undefined.
>> Action: Check the spelling.
>> Action: Check that any custom tasks/types have been declared.
>> Action: Check that any <presetdef>/<macrodef> declarations have taken
>> place.
>> Any help would be greatly apprecieated.
>>
>>
>> Thanks
>> Chris
>>
>>
>
>
Re: Executing JET Transformations in ANT [message #36696 is a reply to message #36373] Tue, 20 November 2007 14:48 Go to previous messageGo to next message
Paul Elder is currently offline Paul ElderFriend
Messages: 849
Registered: July 2009
Senior Member
Chris:

Something is not working. I am investigating. The full command-line may have
to include the workspace path (-data "fully-qualified-ws-path"). Also, there
is a switch to turn off the splash screen. But, even then, in my tests today
(with Eclipse 3.4, I'll try other platforms also), JET is having trouble
loading projects.

I will continue to investigate and post another response tomorrow.

Paul


"Chris" <christopher.valorose@kronos.com> wrote in message
news:fhkrmd$a4u$1@build.eclipse.org...
> Paul,
>
> I have tried running the following command from the command line:
> "eclipse -application org.eclipse.ant.core.antRunner build.xml"
>
> I see the Eclispe slash screen appear and that is it. The default target
> in my build.xml file does not seem to get executed. Should the eclispe
> command be run form a command line?
> Would Eclispe write any log files anywhere that I can get a sense of what
> is going on?
> Is my command correct?
>
> Chris
>
>
> "Paul Elder" <pelder@ca.ibm.com> wrote in message
> news:ffkp64$api$1@build.eclipse.org...
>> Chris:
>>
>> Yes and no.
>>
>> No, JET requires Eclipse. Yes, you can use the jet.transform task in a
>> headless Ant build, so long as you use the Eclipse ant runner:
>>
>> eclipse -application org.eclipse.ant.core.antRunner
>> your-ant-command-line-arguments-go-here
>>
>> Paul
>>
>> "Chris" <christopher.valorose@kronos.com> wrote in message
>> news:ff8br7$vpo$1@build.eclipse.org...
>>> Hi,
>>>
>>> Is it possible to use ANT to run a JET transformation on a JET Model
>>> outside of Eclipse?
>>>
>>> My Eclipse has a plugin that I use to run the JET transformation. The
>>> transformation input is set as ColumnSetJETModel.xml and the
>>> transformation ID is com.kronos.jet.mdd.crud. When I attempt to use
>>> <jet.transform transformid="com.kronos.jet.mdd.crud"
>>> resource="ColumnSetJETModel.xml"/>
>>>
>>>
>>> I get the following errors:
>>> Cause: The name is undefined.
>>> Action: Check the spelling.
>>> Action: Check that any custom tasks/types have been declared.
>>> Action: Check that any <presetdef>/<macrodef> declarations have taken
>>> place.
>>> Any help would be greatly apprecieated.
>>>
>>>
>>> Thanks
>>> Chris
>>>
>>>
>>
>>
>
>
Re: Executing JET Transformations in ANT [message #36764 is a reply to message #36696] Tue, 20 November 2007 20:37 Go to previous messageGo to next message
Paul Elder is currently offline Paul ElderFriend
Messages: 849
Registered: July 2009
Senior Member
An update:

I've got this to work in both Eclipse 3.3 (Europa) and 3.4 M3 (Ganymede).
All of this from windows. Here's a sample command line:

eclipse -data "...full path to your workspace..." -application
org.eclipse.ant.core.antRunner -nosplash

This assumes that build.xml is in the current directory. If not, you can
specify:

eclipse -data "...full path to your workspace..." -application
org.eclipse.ant.core.antRunner -nosplash -buildfile "...full path to build
file..." -Dbasedir=...full to build dir

In my environment, I had a little trouble seeing the standard output. Turns
output be a number of things:

* On windows, in Eclipse 3.3 or later, use eclipsec.exe to run console
applications.
* If you specify a -vm switch in eclipse.ini (mine specified javaw.exe),
then create a copy of eclipse.ini named eclipsec.ini, and use java.exe
instead.

With those changes, I got the ant output I wanted.

Paul

"Paul Elder" <pelder@ca.ibm.com> wrote in message
news:fhus6e$6f7$1@build.eclipse.org...
> Chris:
>
> Something is not working. I am investigating. The full command-line may
> have to include the workspace path (-data "fully-qualified-ws-path").
> Also, there is a switch to turn off the splash screen. But, even then, in
> my tests today (with Eclipse 3.4, I'll try other platforms also), JET is
> having trouble loading projects.
>
> I will continue to investigate and post another response tomorrow.
>
> Paul
>
>
> "Chris" <christopher.valorose@kronos.com> wrote in message
> news:fhkrmd$a4u$1@build.eclipse.org...
>> Paul,
>>
>> I have tried running the following command from the command line:
>> "eclipse -application org.eclipse.ant.core.antRunner build.xml"
>>
>> I see the Eclispe slash screen appear and that is it. The default target
>> in my build.xml file does not seem to get executed. Should the eclispe
>> command be run form a command line?
>> Would Eclispe write any log files anywhere that I can get a sense of what
>> is going on?
>> Is my command correct?
>>
>> Chris
>>
>>
>> "Paul Elder" <pelder@ca.ibm.com> wrote in message
>> news:ffkp64$api$1@build.eclipse.org...
>>> Chris:
>>>
>>> Yes and no.
>>>
>>> No, JET requires Eclipse. Yes, you can use the jet.transform task in a
>>> headless Ant build, so long as you use the Eclipse ant runner:
>>>
>>> eclipse -application org.eclipse.ant.core.antRunner
>>> your-ant-command-line-arguments-go-here
>>>
>>> Paul
>>>
>>> "Chris" <christopher.valorose@kronos.com> wrote in message
>>> news:ff8br7$vpo$1@build.eclipse.org...
>>>> Hi,
>>>>
>>>> Is it possible to use ANT to run a JET transformation on a JET Model
>>>> outside of Eclipse?
>>>>
>>>> My Eclipse has a plugin that I use to run the JET transformation. The
>>>> transformation input is set as ColumnSetJETModel.xml and the
>>>> transformation ID is com.kronos.jet.mdd.crud. When I attempt to use
>>>> <jet.transform transformid="com.kronos.jet.mdd.crud"
>>>> resource="ColumnSetJETModel.xml"/>
>>>>
>>>>
>>>> I get the following errors:
>>>> Cause: The name is undefined.
>>>> Action: Check the spelling.
>>>> Action: Check that any custom tasks/types have been declared.
>>>> Action: Check that any <presetdef>/<macrodef> declarations have taken
>>>> place.
>>>> Any help would be greatly apprecieated.
>>>>
>>>>
>>>> Thanks
>>>> Chris
>>>>
>>>>
>>>
>>>
>>
>>
>
>
Re: Executing JET Transformations in ANT [message #36900 is a reply to message #36764] Mon, 26 November 2007 15:51 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: christopher.valorose.kronos.com

Paul,

Thank you for your help. I am now able to get the headless Eclipse to
attempt to execute the JET Transformation.

I was getting an error of "jet.transform doesn't support the "resource"
attribute". I cahnged the resource attribute to source. Now I am getting an
error that states "could not find resource".

Here is my section of the build.xml
<target name="transform" depends="clean" description="Runs JET
transformation on JET Model">

<jet.transform transformid="com.kronos.jet.mdd.crud"
source="D:/AccuRev/wfp.06.01.qa.int.es/ColumnSetJETModel.xml "/>

</target>

Is the source attribute to be the XML JET Model file? Any documentation I
find shows that the attribute should be "resource" and not "source". What
should the attribute name be?

Do you know of any links for documentation of the jet.transform ant task?
Here is the one that I have found:
http://help.eclipse.org/help33/index.jsp?topic=/org.eclipse. jet.doc/references/ant/antTasks.xhtml

Thank You
Chris

"Paul Elder" <pelder@ca.ibm.com> wrote in message
news:fhvgkj$ck6$1@build.eclipse.org...
> An update:
>
> I've got this to work in both Eclipse 3.3 (Europa) and 3.4 M3 (Ganymede).
> All of this from windows. Here's a sample command line:
>
> eclipse -data "...full path to your workspace..." -application
> org.eclipse.ant.core.antRunner -nosplash
>
> This assumes that build.xml is in the current directory. If not, you can
> specify:
>
> eclipse -data "...full path to your workspace..." -application
> org.eclipse.ant.core.antRunner -nosplash -buildfile "...full path to build
> file..." -Dbasedir=...full to build dir
>
> In my environment, I had a little trouble seeing the standard output.
> Turns output be a number of things:
>
> * On windows, in Eclipse 3.3 or later, use eclipsec.exe to run console
> applications.
> * If you specify a -vm switch in eclipse.ini (mine specified javaw.exe),
> then create a copy of eclipse.ini named eclipsec.ini, and use java.exe
> instead.
>
> With those changes, I got the ant output I wanted.
>
> Paul
>
> "Paul Elder" <pelder@ca.ibm.com> wrote in message
> news:fhus6e$6f7$1@build.eclipse.org...
>> Chris:
>>
>> Something is not working. I am investigating. The full command-line may
>> have to include the workspace path (-data "fully-qualified-ws-path").
>> Also, there is a switch to turn off the splash screen. But, even then, in
>> my tests today (with Eclipse 3.4, I'll try other platforms also), JET is
>> having trouble loading projects.
>>
>> I will continue to investigate and post another response tomorrow.
>>
>> Paul
>>
>>
>> "Chris" <christopher.valorose@kronos.com> wrote in message
>> news:fhkrmd$a4u$1@build.eclipse.org...
>>> Paul,
>>>
>>> I have tried running the following command from the command line:
>>> "eclipse -application org.eclipse.ant.core.antRunner build.xml"
>>>
>>> I see the Eclispe slash screen appear and that is it. The default target
>>> in my build.xml file does not seem to get executed. Should the eclispe
>>> command be run form a command line?
>>> Would Eclispe write any log files anywhere that I can get a sense of
>>> what is going on?
>>> Is my command correct?
>>>
>>> Chris
>>>
>>>
>>> "Paul Elder" <pelder@ca.ibm.com> wrote in message
>>> news:ffkp64$api$1@build.eclipse.org...
>>>> Chris:
>>>>
>>>> Yes and no.
>>>>
>>>> No, JET requires Eclipse. Yes, you can use the jet.transform task in a
>>>> headless Ant build, so long as you use the Eclipse ant runner:
>>>>
>>>> eclipse -application org.eclipse.ant.core.antRunner
>>>> your-ant-command-line-arguments-go-here
>>>>
>>>> Paul
>>>>
>>>> "Chris" <christopher.valorose@kronos.com> wrote in message
>>>> news:ff8br7$vpo$1@build.eclipse.org...
>>>>> Hi,
>>>>>
>>>>> Is it possible to use ANT to run a JET transformation on a JET Model
>>>>> outside of Eclipse?
>>>>>
>>>>> My Eclipse has a plugin that I use to run the JET transformation. The
>>>>> transformation input is set as ColumnSetJETModel.xml and the
>>>>> transformation ID is com.kronos.jet.mdd.crud. When I attempt to use
>>>>> <jet.transform transformid="com.kronos.jet.mdd.crud"
>>>>> resource="ColumnSetJETModel.xml"/>
>>>>>
>>>>>
>>>>> I get the following errors:
>>>>> Cause: The name is undefined.
>>>>> Action: Check the spelling.
>>>>> Action: Check that any custom tasks/types have been declared.
>>>>> Action: Check that any <presetdef>/<macrodef> declarations have taken
>>>>> place.
>>>>> Any help would be greatly apprecieated.
>>>>>
>>>>>
>>>>> Thanks
>>>>> Chris
>>>>>
>>>>>
>>>>
>>>>
>>>
>>>
>>
>>
>
>
Re: Executing JET Transformations in ANT [message #36935 is a reply to message #36900] Tue, 27 November 2007 13:27 Go to previous message
Paul Elder is currently offline Paul ElderFriend
Messages: 849
Registered: July 2009
Senior Member
Chris:

For the 'source' attribute, the jet.transform tag is expecting a 'workspace
relative path'. Something like: 'my.project/my.folder/my.file.xml'.

Paul


"Chris" <christopher.valorose@kronos.com> wrote in message
news:fieq2u$lmg$1@build.eclipse.org...
> Paul,
>
> Thank you for your help. I am now able to get the headless Eclipse to
> attempt to execute the JET Transformation.
>
> I was getting an error of "jet.transform doesn't support the "resource"
> attribute". I cahnged the resource attribute to source. Now I am getting
> an error that states "could not find resource".
>
> Here is my section of the build.xml
> <target name="transform" depends="clean" description="Runs JET
> transformation on JET Model">
>
> <jet.transform transformid="com.kronos.jet.mdd.crud"
> source="D:/AccuRev/wfp.06.01.qa.int.es/ColumnSetJETModel.xml "/>
>
> </target>
>
> Is the source attribute to be the XML JET Model file? Any documentation I
> find shows that the attribute should be "resource" and not "source". What
> should the attribute name be?
>
> Do you know of any links for documentation of the jet.transform ant task?
> Here is the one that I have found:
> http://help.eclipse.org/help33/index.jsp?topic=/org.eclipse. jet.doc/references/ant/antTasks.xhtml
>
> Thank You
> Chris
>
> "Paul Elder" <pelder@ca.ibm.com> wrote in message
> news:fhvgkj$ck6$1@build.eclipse.org...
>> An update:
>>
>> I've got this to work in both Eclipse 3.3 (Europa) and 3.4 M3 (Ganymede).
>> All of this from windows. Here's a sample command line:
>>
>> eclipse -data "...full path to your workspace..." -application
>> org.eclipse.ant.core.antRunner -nosplash
>>
>> This assumes that build.xml is in the current directory. If not, you can
>> specify:
>>
>> eclipse -data "...full path to your workspace..." -application
>> org.eclipse.ant.core.antRunner -nosplash -buildfile "...full path to
>> build file..." -Dbasedir=...full to build dir
>>
>> In my environment, I had a little trouble seeing the standard output.
>> Turns output be a number of things:
>>
>> * On windows, in Eclipse 3.3 or later, use eclipsec.exe to run console
>> applications.
>> * If you specify a -vm switch in eclipse.ini (mine specified javaw.exe),
>> then create a copy of eclipse.ini named eclipsec.ini, and use java.exe
>> instead.
>>
>> With those changes, I got the ant output I wanted.
>>
>> Paul
>>
>> "Paul Elder" <pelder@ca.ibm.com> wrote in message
>> news:fhus6e$6f7$1@build.eclipse.org...
>>> Chris:
>>>
>>> Something is not working. I am investigating. The full command-line may
>>> have to include the workspace path (-data "fully-qualified-ws-path").
>>> Also, there is a switch to turn off the splash screen. But, even then,
>>> in my tests today (with Eclipse 3.4, I'll try other platforms also), JET
>>> is having trouble loading projects.
>>>
>>> I will continue to investigate and post another response tomorrow.
>>>
>>> Paul
>>>
>>>
>>> "Chris" <christopher.valorose@kronos.com> wrote in message
>>> news:fhkrmd$a4u$1@build.eclipse.org...
>>>> Paul,
>>>>
>>>> I have tried running the following command from the command line:
>>>> "eclipse -application org.eclipse.ant.core.antRunner build.xml"
>>>>
>>>> I see the Eclispe slash screen appear and that is it. The default
>>>> target in my build.xml file does not seem to get executed. Should the
>>>> eclispe command be run form a command line?
>>>> Would Eclispe write any log files anywhere that I can get a sense of
>>>> what is going on?
>>>> Is my command correct?
>>>>
>>>> Chris
>>>>
>>>>
>>>> "Paul Elder" <pelder@ca.ibm.com> wrote in message
>>>> news:ffkp64$api$1@build.eclipse.org...
>>>>> Chris:
>>>>>
>>>>> Yes and no.
>>>>>
>>>>> No, JET requires Eclipse. Yes, you can use the jet.transform task in
>>>>> a headless Ant build, so long as you use the Eclipse ant runner:
>>>>>
>>>>> eclipse -application org.eclipse.ant.core.antRunner
>>>>> your-ant-command-line-arguments-go-here
>>>>>
>>>>> Paul
>>>>>
>>>>> "Chris" <christopher.valorose@kronos.com> wrote in message
>>>>> news:ff8br7$vpo$1@build.eclipse.org...
>>>>>> Hi,
>>>>>>
>>>>>> Is it possible to use ANT to run a JET transformation on a JET Model
>>>>>> outside of Eclipse?
>>>>>>
>>>>>> My Eclipse has a plugin that I use to run the JET transformation. The
>>>>>> transformation input is set as ColumnSetJETModel.xml and the
>>>>>> transformation ID is com.kronos.jet.mdd.crud. When I attempt to use
>>>>>> <jet.transform transformid="com.kronos.jet.mdd.crud"
>>>>>> resource="ColumnSetJETModel.xml"/>
>>>>>>
>>>>>>
>>>>>> I get the following errors:
>>>>>> Cause: The name is undefined.
>>>>>> Action: Check the spelling.
>>>>>> Action: Check that any custom tasks/types have been declared.
>>>>>> Action: Check that any <presetdef>/<macrodef> declarations have taken
>>>>>> place.
>>>>>> Any help would be greatly apprecieated.
>>>>>>
>>>>>>
>>>>>> Thanks
>>>>>> Chris
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>
>>>
>>
>>
>
>
Previous Topic:JET2 vs JMerge vs Codegen vs EMF
Next Topic:Could be bug in JET
Goto Forum:
  


Current Time: Thu Apr 25 05:09:39 GMT 2024

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

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

Back to the top