My pom.xml has a packaging of ear and i'm using it to generate an ear, create
webservices using antrun plugin, and compile the ear using weblogic:appc.

<project>
<parent>

    ----parent pom info---

</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>app-web</artifactId>
<packaging>ear</packaging>
<name>App Ear</name>

<dependencies>
 ......dependencies.....
/dependencies>

<build>
 <plugins>
  <plugin>
   <groupId>org.apache.maven.plugins</groupId>
   <artifactId>maven-ear-plugin</artifactId>
   <configuration>
   
     ------ear----
    
   </configuration>
  </plugin>
  
  <plugin>
   <artifactId>maven-antrun-plugin</artifactId>
   <version>1.0</version>
   <executions>
    <execution>
    <phase>package</phase>
    <configuration>
     <tasks>
        ----Tasks to generate webservice using servicegen-----
     </tasks>
    </configuration> 
    <goals>
       <goal>run</goal>
    </goals>
    </execution>
   </executions>

   <dependencies>
      
      ----plugin dependency-----

   </dependencies>
  </plugin>
  
  <!-- Plugin to compile ear.-->
  <plugin>
   <groupId>org.codehaus.mojo</groupId>
   <artifactId>weblogic-maven-plugin</artifactId>
   <version>2.8.0-SNAPSHOT</version>
   <configuration>
   
<objectPath>${project.build.directory}/${project.artifactId}-${project.version}.ear</objectPath>
    <verbose>true</verbose>
    <debugging>true</debugging>
    <nowarnings>false</nowarnings>
    <lineNumbers>true</lineNumbers>
   </configuration>
   <executions>
    <execution>
     <phase>package</phase>
     <goals>
        <goal>appc</goal>
     </goals>
     </execution>
   </executions>
   <dependencies>
    <dependency> 
      <groupId>sun.jdk</groupId> 
      <artifactId>tools</artifactId> 
      <version>1.5.1</version>
      <scope>system</scope> 
      <systemPath>${java.home}/../lib/tools.jar</systemPath>      
    </dependency>    
   </dependencies>
  </plugin> 
 </plugins>
</build>
</project>

When i do 'mvn install', first the ear is generated, the task in antrun
plugin are executed, and then instead of weblogic:appc goal, the ear is
again generated followed by the antrun plugin tasks and then finally the
weblogic:appc is executed. 

Both the antrun plugin and weblogic-maven-plugin have 'package' as the
execution phase. Even if i put antrun to 'compile' phase the build is
executed twice. 

Is there some problem with the weblogic-maven-plugin?? (Scott ?? same thing
happens when i do a weblogic:deploy) or am i putting the plugins in wrong
phases?? 




-- 
View this message in context: 
http://www.nabble.com/EAR%3A-build-executed-twice.-tf2593630s177.html#a7233745
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to