<div dir="ltr">I&#39;ll create the test-case for the JIRA, but in the meanwhile I think that I should switch to forge2, do you think I can use it for &quot;production&quot; ??</div><div class="gmail_extra"><br><br><div class="gmail_quote">

2013/9/13 George Gastaldi <span dir="ltr">&lt;<a href="mailto:ggastald@redhat.com" target="_blank">ggastald@redhat.com</a>&gt;</span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<div dir="auto"><div>Hi Luca,</div><div><br></div><div>We fixed that in Forge 2. In Forge 1 I believe you have no choice but to bundle the JAXB implementation in your plugin. </div><div><br></div><div>Since this looks like a bug still present in Forge 1,  could you please open a JIRA with a simple test case? We&#39;ll try to make the fix available in the next release or find a better workaround for it, since it may impact exisiting plugins.</div>

<div><br></div><div>Best Regards,</div><div><br></div><div>George Gastaldi</div><div><br></div><div><br>Em 13/09/2013, ās 06:40, Luca Masini &lt;<a href="mailto:luca.masini@gmail.com" target="_blank">luca.masini@gmail.com</a>&gt; escreveu:<br>

<br></div><div><div class="h5"><blockquote type="cite"><div><div dir="ltr">Hi guys, I&#39;m developing a plugin where I need to unmarshal some beans using JAXB.<div><br></div><div>The parsing works great outside forge, but when I try to execute the same code inside a plugin I got this Exception:</div>



<div><br></div><div><div>javax.xml.bind.JAXBException</div><div> - with linked exception:</div><div>[java.lang.ClassNotFoundException: com.sun.xml.internal.bind.v2.ContextFactory from [Module &quot;it.xxxxxxx.forge.prova-plugin:1.0.0-SNAPSHOT-c1d512df-2daa-4ebe-ae7a-154e102bb88d&quot; from local module loader @15aaf0b3 (roots: /Applications/sviluppo/jboss/forge-distribution-1.4.0.Final/modules,/Users/ictlm1/.forge/plugins,/Users/ictlm1/Documents/progetti/forge)]]</div>



<div><span style="white-space:pre-wrap">        </span>at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:187)</div><div><span style="white-space:pre-wrap">        </span>at javax.xml.bind.ContextFinder.find(ContextFinder.java:376)</div>



<div><span style="white-space:pre-wrap">        </span>at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:574)</div><div><span style="white-space:pre-wrap">        </span>at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:522)</div>



<div><span style="white-space:pre-wrap">        </span>at it.xxx.forge.parser.Parser.parse(Parser.java:17)</div><div><span style="white-space:pre-wrap">        </span>at it.xxx.forge.forge.CreateEntitiesPlugin.parse(CreateEntitiesPlugin.java:19)</div>



<div><span style="white-space:pre-wrap">        </span>at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)</div><div><span style="white-space:pre-wrap">        </span>at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)</div>



<div><span style="white-space:pre-wrap">        </span>at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)</div><div><span style="white-space:pre-wrap">        </span>at java.lang.reflect.Method.invoke(Method.java:597)</div>



<div><span style="white-space:pre-wrap">        </span>at org.jboss.forge.shell.command.Execution.perform(Execution.java:160)</div><div>...</div><div>...</div><div><div>Caused by: java.lang.ClassNotFoundException: com.sun.xml.internal.bind.v2.ContextFactory from [Module &quot;it.esselunga.forge.prova-plugin:1.0.0-SNAPSHOT-c1d512df-2daa-4ebe-ae7a-154e102bb88d&quot; from local module loader @15aaf0b3 (roots: /Applications/sviluppo/jboss/forge-distribution-1.4.0.Final/modules,/Users/ictlm1/.forge/plugins,/Users/ictlm1/Documents/progetti/forge)]</div>



<div><span style="white-space:pre-wrap">        </span>at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:190)</div><div><span style="white-space:pre-wrap">        </span>at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:468)</div>



<div><span style="white-space:pre-wrap">        </span>at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:456)</div><div><span style="white-space:pre-wrap">        </span>at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:398)</div>



<div><span style="white-space:pre-wrap">        </span>at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:120)</div><div><span style="white-space:pre-wrap">        </span>at javax.xml.bind.ContextFinder.safeLoadClass(ContextFinder.java:481)</div>



<div><span style="white-space:pre-wrap">        </span>at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:185)</div><div><span style="white-space:pre-wrap">        </span>... 41 more</div></div><div><br></div><div>
ContextFactory is part of rt.jar with is bundled with the JDK, how can I tell the ModuleClassLoader to let me load it ??</div>
<div><br></div><div>Thank you.</div><div><br></div><div><br></div><div><br></div>-- <br>****************************************<br><a href="http://www.lucamasini.net" target="_blank">http://www.lucamasini.net</a><br><a href="http://twitter.com/lmasini" target="_blank">http://twitter.com/lmasini</a><br>



<a href="http://www.linkedin.com/pub/luca-masini/7/10/2b9" target="_blank">http://www.linkedin.com/pub/luca-masini/7/10/2b9</a><br>****************************************
</div></div>
</div></blockquote></div></div><blockquote type="cite"><div><span>_______________________________________________</span><br><span>forge-dev mailing list</span><br><span><a href="mailto:forge-dev@lists.jboss.org" target="_blank">forge-dev@lists.jboss.org</a></span><br>

<span><a href="https://lists.jboss.org/mailman/listinfo/forge-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/forge-dev</a></span></div></blockquote></div><br>_______________________________________________<br>


forge-dev mailing list<br>
<a href="mailto:forge-dev@lists.jboss.org">forge-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/forge-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/forge-dev</a><br></blockquote></div><br><br clear="all"><div><br></div>-- <br>****************************************<br>

<a href="http://www.lucamasini.net">http://www.lucamasini.net</a><br><a href="http://twitter.com/lmasini">http://twitter.com/lmasini</a><br><a href="http://www.linkedin.com/pub/luca-masini/7/10/2b9">http://www.linkedin.com/pub/luca-masini/7/10/2b9</a><br>

****************************************
</div>