<div dir="ltr"><div><div>Thanks Fred!<br><br></div>We&#39;ll explore some options and see what door we choose to open. :)<br><br></div>--Fitz<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, May 5, 2016 at 1:23 PM, Fred Bricon <span dir="ltr">&lt;<a href="mailto:fbricon@redhat.com" target="_blank">fbricon@redhat.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi Brian,<div><br></div><div>sooo, m2e doesn&#39;t know if it&#39;s safe to execute a 3rd party plugin or not, during an Eclipse build[1]. It needs hints whether to ignore or execute this maven plugin or maybe delegate its execution to some eclipse plugin adapter. </div><div><br></div><div>So the very first question you need to answer is : does the maven plugin need to be invoked during an eclipse (incremental or full) build, or can it be safely ignored? </div><div>I&#39;m guessing (but you prolly want to ask the exoerts):</div><div>- <span style="font-size:12.8px">cxf-java2wadl-</span><span style="font-size:12.8px">plugin:</span><span style="font-size:12.8px">parsejavadoc: probably ignored</span></div><div><div>- <span style="font-size:12.8px">cxf-java2wadl-</span><span style="font-size:12.8px">plugin:</span><span style="font-size:12.8px"> java2wadl</span><span style="font-size:12.8px">: probably executed on full builds only (you don&#39;t want to regenerate the wadl every time you save a file in your project)</span></div></div><div><div>- <span style="font-size:12.8px">fabric-cxf-</span><span style="font-size:12.8px">plugins</span><span style="font-size:12.8px">:</span><span style="font-size:12.8px"> java2swagger</span><span style="font-size:12.8px">: </span><span style="font-size:12.8px">probably executed on full builds only</span></div></div><div><br></div><div>Once you have the answer to that question, the next step is to declare a lifecycle mapping (LM), which can be done in several ways, depending on your use case:</div><div><br></div><div>1 - add a LM descriptor within the maven plugin itself:</div><div>     * this only affects consumers of the new maven plugin version containing the LM. For older versions, see #2-#3</div><div>     * if must be executed, need to ensure this is done in an optimal way by using the incremental build API [2], to at least automatically refresh resources modified by the plugin execution</div><div>2 - define m2e LM in pom.xml</div><div>     * define it once in a common parent pom to avoid xml bloat, that should be easy to do for new example projects, won&#39;t work for previous example releases </div><div>3 - create an m2e configurator (eclipse plugin) [3]</div><div>    * can simply define the LM. Can also enhance eclipse integration by configuring some eclipse specific configuration</div><div>    * the eclipse plugin needs to be added to the m2e discovery catalog [4]</div><div><br></div><div>You could reach out to the <span style="font-size:12.8px">fabric8 team and ask them if they&#39;re willing to make their plugins incremental-build friendly. For Apache CXF, that might be a bit more tricky, bit doesn&#39;t hurt to ask.</span></div><div><span style="font-size:12.8px"><br></span></div><div><span style="font-size:12.8px">Chances are though, it&#39;ll be faster/easier to create an m2e eclipse plugin for that (#3). I have commit access to the m2e discovery repo, so it&#39;ll be easy to get in. </span>Now, the m2e project is not responsible for providing LMs for 3rd party maven plugins. <span style="font-size:12.8px">So I&#39;d suggest you open JBIDE issues for each of your problems.  </span></div><div><span style="font-size:12.8px"><br></span></div><div><span style="font-size:12.8px">Fred</span></div><div><span style="font-size:12.8px"><br></span></div><div><br></div><div>[1] <a href="https://www.eclipse.org/m2e/documentation/m2e-execution-not-covered.html" style="border-bottom-width:1px;border-bottom-style:solid;border-bottom-color:orange" target="_blank">https://www.eclipse.org/m2e/documentation/m2e-execution-not-covered.html</a></div><div>[2] <a href="https://www.eclipse.org/m2e/documentation/m2e-making-maven-plugins-compat.html" style="border-bottom-width:1px;border-bottom-style:solid;border-bottom-color:orange" target="_blank">https://www.eclipse.org/m2e/documentation/m2e-making-maven-plugins-compat.html</a></div><div>[3] <a href="https://www.eclipse.org/m2e/documentation/m2e-extension-development.html" style="border-bottom-width:1px;border-bottom-style:solid;border-bottom-color:orange" target="_blank">https://www.eclipse.org/m2e/documentation/m2e-extension-development.html</a></div><div>[4] <a href="https://github.com/takari/m2e-discovery-catalog#m2e-discovery-catalog" style="border-bottom-width:1px;border-bottom-style:solid;border-bottom-color:orange" target="_blank">https://github.com/takari/m2e-discovery-catalog#m2e-discovery-catalog</a></div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="h5">On Thu, May 5, 2016 at 10:49 AM, Brian Fitzpatrick <span dir="ltr">&lt;<a href="mailto:bfitzpat@redhat.com" target="_blank">bfitzpat@redhat.com</a>&gt;</span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5"><div dir="ltr"><div>Hey guys,<br><br></div><div>We&#39;ve hit some maven plug-ins that aren&#39;t supported yet by m2e that we use in the Fuse world... if I was to log a feature request for some of these, should I put it in Eclipse? or in JBIDE?<br><br></div><div>Or a better question, what is the policy for additions to m2e? How do we petition to have plug-ins added or contribute back? These may not be broadly applicable to other projects, so less apt to be pushed upstream.<br><br></div><div>Thanks in advance.<br><br></div><div>--Fitz<br><br></div><div>p.s. For a bit more detail about what we&#39;re looking for... <br><br>Importing the camel-cxf example (<a href="https://github.com/jboss-fuse/quickstarts/tree/master/cxf/rest" target="_blank">https://github.com/jboss-fuse/quickstarts/tree/master/cxf/rest</a>) we hit three issues.<br></div><div><br></div><div>We have an org.apache.cxf plug-ins that isn&#39;t supported yet...<br><br>      &lt;plugin&gt;<br>        &lt;groupId&gt;org.apache.cxf&lt;/groupId&gt;<br>        &lt;artifactId&gt;cxf-java2wadl-plugin&lt;/artifactId&gt;<br>        &lt;version&gt;3.0.4.redhat-621084&lt;/version&gt;<br>        &lt;executions&gt;<br>          &lt;execution&gt;<br>            &lt;id&gt;parsejavadoc&lt;/id&gt;<br>            &lt;phase&gt;generate-sources&lt;/phase&gt;<br>            &lt;goals&gt;<br>              &lt;goal&gt;parsejavadoc&lt;/goal&gt;<br>            &lt;/goals&gt;<br>          &lt;/execution&gt;<br>          &lt;execution&gt;<br>            &lt;id&gt;process-classes&lt;/id&gt;<br>            &lt;phase&gt;process-classes&lt;/phase&gt;<br>            &lt;goals&gt;<br>              &lt;goal&gt;java2wadl&lt;/goal&gt;<br>            &lt;/goals&gt;<br>            &lt;configuration&gt;<br>              &lt;classResourceNames&gt;<br>                &lt;classResourceName&gt;io.fabric8.quickstarts.rest.CustomerService&lt;/classResourceName&gt;<br>              &lt;/classResourceNames&gt;<br>              &lt;docProvider&gt;org.apache.cxf.maven_plugin.javatowadl.ResourceMapJavaDocProvider&lt;/docProvider&gt;<br>              &lt;attachWadl&gt;false&lt;/attachWadl&gt;<br>            &lt;/configuration&gt;<br>          &lt;/execution&gt;<br>        &lt;/executions&gt;<br>      &lt;/plugin&gt;<br><br></div><div>And a fabric8 plug-in that isn&#39;t supported yet.<br><br>      &lt;plugin&gt;<br>        &lt;groupId&gt;io.fabric8&lt;/groupId&gt;<br>        &lt;artifactId&gt;fabric-cxf-plugins&lt;/artifactId&gt;<br>        &lt;version&gt;1.2.0.redhat-621084&lt;/version&gt;<br>        &lt;executions&gt;<br>          &lt;execution&gt;<br>            &lt;id&gt;process-classes&lt;/id&gt;<br>            &lt;phase&gt;process-classes&lt;/phase&gt;<br>            &lt;goals&gt;<br>              &lt;goal&gt;java2swagger&lt;/goal&gt;<br>            &lt;/goals&gt;<br>            &lt;configuration&gt;<br>              &lt;classResourceNames&gt;<br>                &lt;classResourceName&gt;io.fabric8.quickstarts.rest.CustomerService&lt;/classResourceName&gt;<br>              &lt;/classResourceNames&gt;<br>              &lt;attachSwagger&gt;false&lt;/attachSwagger&gt;<br>            &lt;/configuration&gt;<br>          &lt;/execution&gt;<br>        &lt;/executions&gt;<br>      &lt;/plugin&gt;<br><br></div></div>
<br></div></div>_______________________________________________<br>
jbosstools-dev mailing list<br>
<a href="mailto:jbosstools-dev@lists.jboss.org" target="_blank">jbosstools-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/jbosstools-dev" rel="noreferrer" target="_blank">https://lists.jboss.org/mailman/listinfo/jbosstools-dev</a><br></blockquote></div><br></div>
</blockquote></div><br></div>