| Failed MweReader with deployed dsl [message #514041] |
Fri, 12 February 2010 04:40  |
Dirk Michael Goldschmidt Messages: 2 Registered: July 2009 |
Junior Member |
|
|
Hi all,
I really liked the xtext/xpand tutorials for instance at http://eclipse.dzone.com/articles/getting-started-xtext-part -2.
However I always run into problems when I try to use the generator workflow in a "user scenario" where the
xtext defined dsl is used from an installed plugin.
I know that I can test the workflow in a runtime instance and that works fine.
When I deploy the dsl as a plugin and install it I can use the generated editor for the created dsl, so the plugin
seems to work.
However running the workflow always fails because the class "org.xtext.example.MyDslStandaloneSetup" can't be
registered as the reader for "org.eclipse.xtext.MweReader".
Maybe this is just a trivial question and I am missing some points since I am new to Java? Is the problem
caused by insufficient exports in the original plugin for the dsl or do I have to change something in the
workflow file?
The problem does not occur when I additionally open the original dsl plugin project in the workspace. Since
I would like to deploy the dsl to users this is not an option for me.
Any help would be greatly appreciated.
mwe configuration file used:
<workflow>
<property name="modelFile" value="classpath:/model/MyModel.mydsl"/>
<property name="targetDir" value="src-gen"/>
<bean class="org.eclipse.emf.mwe.utils.StandaloneSetup" platformUri=".."/>
<component class="org.eclipse.emf.mwe.utils.DirectoryCleaner" directory="${targetDir}"/>
<component class="org.eclipse.xtext.MweReader" uri="${modelFile}">
<!-- this class will be generated by the xtext generator -->
<register class="org.xtext.example.MyDslStandaloneSetup"/>
</component>
<component class="org.eclipse.xpand2.Generator">
<metaModel class="org.eclipse.xtend.typesystem.emf.EmfRegistryMetaModel "/>
<fileEncoding value="Cp1252"/>
<expand value="templates::Template::main FOR model"/>
<genPath value="${targetDir}"/>
</component>
</workflow>
Error messages:
12.02.2010 10:19:24 org.eclipse.emf.mwe.core.WorkflowRunner prepare
INFO: ------------------------------------------------------------ --------------------------
12.02.2010 10:19:24 org.eclipse.emf.mwe.core.WorkflowRunner prepare
INFO: EMF Modeling Workflow Engine 0.7.2, Build v200908120417
12.02.2010 10:19:24 org.eclipse.emf.mwe.core.WorkflowRunner prepare
INFO: (c) 2005-2009 openarchitectureware.org and contributors
12.02.2010 10:19:24 org.eclipse.emf.mwe.core.WorkflowRunner prepare
INFO: ------------------------------------------------------------ --------------------------
12.02.2010 10:19:24 org.eclipse.emf.mwe.core.WorkflowRunner prepare
INFO: running workflow: G:/dg/Projekte/Eclipse/testWorkflow/src/workflow/MyDslGenera tor.mwe
12.02.2010 10:19:24 org.eclipse.emf.mwe.core.WorkflowRunner prepare
INFO:
12.02.2010 10:19:25 org.eclipse.emf.mwe.core.WorkflowRunner logIssues
SCHWERWIEGEND: [ERROR]: Class not found: 'org.eclipse.xtext.MweReader'(Element: bean component class='org.eclipse.xtext.MweReader' in G:/dg/Projekte/Eclipse/testWorkflow/src/workflow/MyDslGenera tor.mwe:9; Reported by: -UNKNOWN-)
12.02.2010 10:19:25 org.eclipse.emf.mwe.core.WorkflowRunner logIssues
SCHWERWIEGEND: [ERROR]: No getter or adder method for property 'uri' in clazz 'org.eclipse.emf.mwe.core.WorkflowComponent' found.(Element: uri='classpath:/model/MyModel.mydsl' in G:/dg/Projekte/Eclipse/testWorkflow/src/workflow/MyDslGenera tor.mwe:9; Reported by: -UNKNOWN-)
12.02.2010 10:19:25 org.eclipse.emf.mwe.core.WorkflowRunner logIssues
SCHWERWIEGEND: [ERROR]: No getter or adder method for property 'register' in clazz 'org.eclipse.emf.mwe.core.WorkflowComponent' found. Forgot to customize?(Element: bean register class='org.xtext.example.MyDslStandaloneSetup' in G:/dg/Projekte/Eclipse/testWorkflow/src/workflow/MyDslGenera tor.mwe:11; Reported by: -UNKNOWN-)
12.02.2010 10:19:25 org.eclipse.emf.mwe.core.WorkflowRunner prepare
SCHWERWIEGEND: Workflow interrupted because of configuration errors.
Regards,
Dirk Michael Goldschmidt
|
|
|
| Re: Failed MweReader with deployed dsl [message #514099 is a reply to message #514041] |
Fri, 12 February 2010 07:27   |
Sven Efftinge Messages: 1667 Registered: July 2009 |
Senior Member |
|
|
I'm assuming that you run the workflow using the Run As... launch
configuration. In that case the dsl bundle needs to be on your
classpath. This can be done by either having the project in the
workspace or referencing the jared project from the project you start
the mwe file from.
Sven
Dirk Michael Goldschmidt schrieb:
> Hi all,
>
> I really liked the xtext/xpand tutorials for instance at
> http://eclipse.dzone.com/articles/getting-started-xtext-part -2
>
> However I always run into problems when I try to use the generator
> workflow in a "user scenario" where the
> xtext defined dsl is used from an installed plugin.
>
> I know that I can test the workflow in a runtime instance and that works
> fine.
> When I deploy the dsl as a plugin and install it I can use the generated
> editor for the created dsl, so the plugin
> seems to work.
> However running the workflow always fails because the class
> "org.xtext.example.MyDslStandaloneSetup" can't be
> registered as the reader for "org.eclipse.xtext.MweReader".
>
> Maybe this is just a trivial question and I am missing some points since
> I am new to Java? Is the problem
> caused by insufficient exports in the original plugin for the dsl or do
> I have to change something in the
> workflow file?
>
> The problem does not occur when I additionally open the original dsl
> plugin project in the workspace. Since
> I would like to deploy the dsl to users this is not an option for me.
>
> Any help would be greatly appreciated.
>
>
> mwe configuration file used:
> <workflow>
> <property name="modelFile" value="classpath:/model/MyModel.mydsl"/>
> <property name="targetDir" value="src-gen"/>
> <bean class="org.eclipse.emf.mwe.utils.StandaloneSetup"
> platformUri=".."/> <component
> class="org.eclipse.emf.mwe.utils.DirectoryCleaner"
> directory="${targetDir}"/> <component
> class="org.eclipse.xtext.MweReader" uri="${modelFile}">
> <!-- this class will be generated by the xtext generator -->
> <register class="org.xtext.example.MyDslStandaloneSetup"/>
> </component> <component class="org.eclipse.xpand2.Generator">
> <metaModel
> class="org.eclipse.xtend.typesystem.emf.EmfRegistryMetaModel "/>
> <fileEncoding value="Cp1252"/>
> <expand value="templates::Template::main FOR model"/>
> <genPath value="${targetDir}"/>
> </component>
> </workflow>
>
>
> Error messages:
> 12.02.2010 10:19:24 org.eclipse.emf.mwe.core.WorkflowRunner prepare
> INFO: ------------------------------------------------------------
> --------------------------
> 12.02.2010 10:19:24 org.eclipse.emf.mwe.core.WorkflowRunner prepare
> INFO: EMF Modeling Workflow Engine 0.7.2, Build v200908120417
> 12.02.2010 10:19:24 org.eclipse.emf.mwe.core.WorkflowRunner prepare
> INFO: (c) 2005-2009 openarchitectureware.org and contributors
> 12.02.2010 10:19:24 org.eclipse.emf.mwe.core.WorkflowRunner prepare
> INFO: ------------------------------------------------------------
> --------------------------
> 12.02.2010 10:19:24 org.eclipse.emf.mwe.core.WorkflowRunner prepare
> INFO: running workflow:
> G:/dg/Projekte/Eclipse/testWorkflow/src/workflow/MyDslGenera tor.mwe
> 12.02.2010 10:19:24 org.eclipse.emf.mwe.core.WorkflowRunner prepare
> INFO:
> 12.02.2010 10:19:25 org.eclipse.emf.mwe.core.WorkflowRunner logIssues
> SCHWERWIEGEND: [ERROR]: Class not found:
> 'org.eclipse.xtext.MweReader'(Element: bean component
> class='org.eclipse.xtext.MweReader' in
> G:/dg/Projekte/Eclipse/testWorkflow/src/workflow/MyDslGenera tor.mwe:9;
> Reported by: -UNKNOWN-)
> 12.02.2010 10:19:25 org.eclipse.emf.mwe.core.WorkflowRunner logIssues
> SCHWERWIEGEND: [ERROR]: No getter or adder method for property 'uri' in
> clazz 'org.eclipse.emf.mwe.core.WorkflowComponent' found.(Element:
> uri='classpath:/model/MyModel.mydsl' in
> G:/dg/Projekte/Eclipse/testWorkflow/src/workflow/MyDslGenera tor.mwe:9;
> Reported by: -UNKNOWN-)
> 12.02.2010 10:19:25 org.eclipse.emf.mwe.core.WorkflowRunner logIssues
> SCHWERWIEGEND: [ERROR]: No getter or adder method for property
> 'register' in clazz 'org.eclipse.emf.mwe.core.WorkflowComponent' found.
> Forgot to customize?(Element: bean register
> class='org.xtext.example.MyDslStandaloneSetup' in
> G:/dg/Projekte/Eclipse/testWorkflow/src/workflow/MyDslGenera tor.mwe:11;
> Reported by: -UNKNOWN-)
> 12.02.2010 10:19:25 org.eclipse.emf.mwe.core.WorkflowRunner prepare
> SCHWERWIEGEND: Workflow interrupted because of configuration errors.
>
> Regards,
>
> Dirk Michael Goldschmidt
--
Need professional support for Xtext and EMF?
Go to: http://xtext.itemis.com
Twitter : @svenefftinge
Blog : blog.efftinge.de
--
Need professional support for Xtext and EMF?
Go to: http://xtext.itemis.com
Twitter : @svenefftinge
Blog : blog.efftinge.de
|
|
|
|
Powered by
FUDForum. Page generated in 0.01551 seconds