<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<body link="#355491" alink="#4262a1" vlink="#355491" style="background: #e2e2e2; margin: 0; padding: 20px;">
<div>
        <table cellpadding="0" bgcolor="#FFFFFF" border="0" cellspacing="0" style="border: 1px solid #dadada; margin-bottom: 30px; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                <tbody>
                        <tr>
                                <td>
                                        <table border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" style="border: solid 2px #ccc; background: #dadada; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                                                <tbody>
                                                        <tr>
                                                                <td bgcolor="#000000" valign="middle" height="58px" style="border-bottom: 1px solid #ccc; padding: 20px; -moz-border-radius-topleft: 3px; -moz-border-radius-topright: 3px; -webkit-border-top-right-radius: 5px; -webkit-border-top-left-radius: 5px;">
                                                                        <h1 style="color: #333333; font: bold 22px Arial, Helvetica, sans-serif; margin: 0; display: block !important;">
                                                                        <!-- To have a header image/logo replace the name below with your img tag -->
                                                                        <!-- Email clients will render the images when the message is read so any image -->
                                                                        <!-- must be made available on a public server, so that all recipients can load the image. -->
                                                                        <a href="http://community.jboss.org/index.jspa" style="text-decoration: none; color: #E1E1E1">JBoss Community</a></h1>
                                                                </td>
                                                        </tr>
                                                        <tr>
                                                                <td bgcolor="#FFFFFF" style="font: normal 12px Arial, Helvetica, sans-serif; color:#333333; padding: 20px; -moz-border-radius-bottomleft: 4px; -moz-border-radius-bottomright: 4px; -webkit-border-bottom-right-radius: 5px; -webkit-border-bottom-left-radius: 5px;"><h3 style="margin: 10px 0 5px; font-size: 17px; font-weight: normal;">
Maven plugin classpath woes
</h3>
<span style="margin-bottom: 10px;">
created by <a href="http://community.jboss.org/people/dpalmer%40redhat.com">Douglas Palmer</a> in <i>JBoss AOP</i> - <a href="http://community.jboss.org/message/567643#567643">View the full discussion</a>
</span>
<hr style="margin: 20px 0; border: none; background-color: #dadada; height: 1px;">
<div class="jive-rendered-content"><p><strong>Hi</strong></p><p><strong><br/></strong></p><p><strong>I am currently trying to move the JBoss ESB build from ant to maven. In the ant build we use the aopc ant task modify an external jar (which is one of the project dependencies); I am having problems replicating this with the maven aop plugin. I have the maven plugin configured as follows:</strong></p><p style="min-height: 8pt; height: 8pt; padding: 0px;"> </p><p><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">      <plugin></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">        <groupId>org.jboss.maven.plugins</groupId></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">        <artifactId>maven-jbossaop-plugin</artifactId></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">        <version>2.1.3.GA</version></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">        <executions></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">          <execution></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">            <id>compile</id></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">            <configuration></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">              <aoppaths></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">                <aoppath>src/main/resources/jboss-aop.xml</aoppath></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">              </aoppaths></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">              <classPath>${project.build.outputDirectory}:${maven.plugin.classpath}:${maven.compile.classpath}</classPath></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">              <includeProjectDependency>true</includeProjectDependency></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">              <includes></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">                <include>com/eviware/soapui/impl/wsdl/support/wsdl/WsdlContext\$Loader.class</include></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">              </includes></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">            </configuration></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">            <goals></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">              <goal>compile</goal></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">            </goals></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">          </execution></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">        </executions></div><div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">      </plugin> </div><div> </div><p>      <plugin></p><p>        <groupId>org.jboss.maven.plugins</groupId></p><p>        <artifactId>maven-jbossaop-plugin</artifactId></p><p>        <version>2.1.3.GA</version></p><p>        <executions></p><p>          <execution></p><p>            <id>compile</id></p><p>            <configuration></p><p>              <aoppaths></p><p>                <aoppath>src/main/resources/jboss-aop.xml</aoppath></p><p>              </aoppaths></p><p>              <includeProjectDependency>true</includeProjectDependency></p><p>              <includes></p><p>                <include>com/eviware/soapui/impl/wsdl/support/wsdl/WsdlContext\$Loader.class</include></p><p>              </includes></p><p>            </configuration></p><p>            <goals></p><p>              <goal>compile</goal></p><p>            </goals></p><p>          </execution></p><p>        </executions></p><p>      </plugin> </p><div> </div></p><p><strong>From this configuration the aop plugin generates the following command:</strong></p><p style="min-height: 8pt; height: 8pt; padding: 0px;"> </p><p>java -cp /home/dpalmer/.m2/repository/org/codehaus/plexus/plexus-utils/1.4.9/plexus-utils-1.4.9.jar:/home/dpalmer/.m2/repository/org/apache/maven/plugins/maven-surefire-plugin/2.4/maven-surefire-plugin-2.4.jar:/home/dpalmer/.m2/repository/org/apache/maven/surefire/surefire-booter/2.4/surefire-booter-2.4.jar:/home/dpalmer/.m2/repository/org/apache/maven/surefire/surefire-api/2.4/surefire-api-2.4.jar:/home/dpalmer/.m2/repository/org/jboss/aop/jboss-aop/2.1.3.GA/jboss-aop-2.1.3.GA.jar:/home/dpalmer/.m2/repository/org/apache/ant/ant/1.7.0/ant-1.7.0.jar:/home/dpalmer/.m2/repository/org/apache/ant/ant-launcher/1.7.0/ant-launcher-1.7.0.jar:/home/dpalmer/.m2/repository/javassist/javassist/3.10.0.GA/javassist-3.10.0.GA.jar:/home/dpalmer/.m2/repository/org/jboss/jboss-reflect/2.0.2.GA/jboss-reflect-2.0.2.GA.jar:/home/dpalmer/.m2/repository/org/jboss/logging/jboss-logging-spi/2.0.5.GA/jboss-logging-spi-2.0.5.GA.jar:/home/dpalmer/.m2/repository/org/jboss/jboss-common-core/2.2.11.GA/jboss-common-core-2.2.11.GA.jar:/home/dpalmer/.m2/repository/org/jboss/jboss-mdr/2.0.1.GA/jboss-mdr-2.0.1.GA.jar:/home/dpalmer/.m2/repository/trove/trove/2.1.1/trove-2.1.1.jar:/home/dpalmer/.m2/repository/org/jboss/logging/jboss-logging-log4j/2.0.5.GA/jboss-logging-log4j-2.0.5.GA.jar:/usr/local/maven/maven_home/lib/maven-2.2.1-uber.jar:/usr/local/maven/maven_home/lib/maven-2.2.1-uber.jar:/home/dpalmer/Work/ESB/checkouts/branches/dpalmer/JBESB_4_9_CP/product/services/soapui-client/soapui/../../../lib/ext/soapui-1.7.1.jar:/home/dpalmer/.m2/repository/eviware/soapui-xmlbeans/1.7/soapui-xmlbeans-1.7.jar:/home/dpalmer/.m2/repository/eviware/soap-xmlbeans/1.2/soap-xmlbeans-1.2.jar:/home/dpalmer/.m2/repository/xmlbeans/xbean/2.2.0/xbean-2.2.0.jar:/home/dpalmer/.m2/repository/log4j/log4j/1.2.14/log4j-1.2.14.jar:/home/dpalmer/.m2/repository/wsdl4j/wsdl4j/1.6.2/wsdl4j-1.6.2.jar:/home/dpalmer/.m2/repository/org/jboss/soa/esb/aop/4.9.SNAPSHOT/aop-4.9.SNAPSHOT.jar:/home/dpalmer/Work/ESB/checkouts/branches/dpalmer/JBESB_4_9_CP/product/services/soapui-client/soapui/target/classes org.jboss.aop.standalone.Compiler -verbose -suppress -aoppath /home/dpalmer/Work/ESB/checkouts/branches/dpalmer/JBESB_4_9_CP/product/services/soapui-client/soapui/src/main/resources/jboss-aop.xml /home/dpalmer/Work/ESB/checkouts/branches/dpalmer/JBESB_4_9_CP/product/services/soapui-client/soapui/target/classes/com/eviware/soapui/impl/wsdl/support/wsdl/WsdlContext\$Loader.class</p><p style="min-height: 8pt; height: 8pt; padding: 0px;"> </p><p><strong>This fails with:</strong></p><p style="min-height: 8pt; height: 8pt; padding: 0px;"> </p><p>Trying to compile /home/dpalmer/Work/ESB/checkouts/branches/dpalmer/JBESB_4_9_CP/product/services/soapui-client/soapui/target/classes/com/eviware/soapui/impl/wsdl/support/wsdl/WsdlContext$Loader.class and found it also within file:/home/dpalmer/Work/ESB/checkouts/branches/dpalmer/JBESB_4_9_CP/product/lib/ext/soapui-1.7.1.jar!/com/eviware/soapui/impl/wsdl/support/wsdl/WsdlContext$Loader.class will not proceed.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;"> </p><p><strong>However, if I move the classpath entry for my project.build.outputDirectory from the end of the classpath to the start of the classpath then the aop compile succeeds. Is it possible to change the order of the classpath entries? Or have I configure this incorrectly?</strong></p><p style="min-height: 8pt; height: 8pt; padding: 0px;"> </p><p><strong>Regards</strong></p><p><strong>Doug</strong></p></div>
<div style="background-color: #f4f4f4; padding: 10px; margin-top: 20px;">
<p style="margin: 0;">Reply to this message by <a href="http://community.jboss.org/message/567643#567643">going to Community</a></p>
        <p style="margin: 0;">Start a new discussion in JBoss AOP at <a href="http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2027">Community</a></p>
</div></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</div>
</body>
</html>