Note that there are some explanatory texts on larger screens.

plurals
  1. POWhat sort of configuration issues or problems might make Maven Assembly plugin go slowly?
    text
    copied!<p>Our multi-module Maven project used to take 4-6 minutes to build. Over the past few months, it has increased to 20+ minutes per build. One symptom is that sometimes the build appears to pause until I hit &lt;enter&gt;. However, the Maven build still runs fine (6 minutes, no pauses) on our build server.</p> <p>The build command is <code>mvn clean package -D&lt;profile&gt;</code></p> <p>Some of our plugins include:</p> <ul> <li>PMD </li> <li>FindBugs </li> <li>Assembly </li> <li>Thrift Compiler</li> <li>jspc-maven-plugin</li> <li>maven-replacer-plugin</li> </ul> <p>Also, we have an internal Nexus repository.</p> <p><strong>Update: Build Logs</strong></p> <p>Local Build: </p> <pre><code>[INFO] ------------------------------------------------------------------------ [INFO] Reactor Summary: [INFO] [INFO] Project Parent ............................. SUCCESS [17.703s] [INFO] Dependencies ............................... SUCCESS [0.109s] [INFO] Thrift Service ............................. SUCCESS [1:51.141s] [INFO] Thrift API Client Sample ................... SUCCESS [14.219s] [INFO] Application ................................ SUCCESS [14:07.984s] [INFO] Webapps Parent ............................. SUCCESS [1.250s] [INFO] Webapp A ................................... SUCCESS [27.547s] [INFO] Webapp B.................................... SUCCESS [20.672s] [INFO] Webapp C ................................... SUCCESS [1:14.656s] [INFO] Assembly ................................... SUCCESS [5:47.219s] [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESS [INFO] ------------------------------------------------------------------------ [INFO] Total time: 24:23.234s [INFO] Finished at: Fri Jan 27 10:47:38 EST 2012 [INFO] Final Memory: 25M/66M [INFO] ------------------------------------------------------------------------ </code></pre> <p>Build Server (Team City):</p> <pre><code>[02:16:31]: [INFO] ------------------------------------------------------------------------ [02:16:31]: [INFO] Reactor Summary: [02:16:31]: [INFO] [02:16:31]: [INFO] Project Parent ............................. SUCCESS [3.421s] [02:16:31]: [INFO] Dependencies ............................... SUCCESS [3.157s] [02:16:31]: [INFO] Thrift Service ............................. SUCCESS [41.314s] [02:16:31]: [INFO] Thrift API Client Sample ................... SUCCESS [1.220s] [02:16:31]: [INFO] Application ................................ SUCCESS [4:09.617s] [02:16:31]: [INFO] Webapps Parent ............................. SUCCESS [0.323s] [02:16:31]: [INFO] Webapp A ................................... SUCCESS [12.811s] [02:16:31]: [INFO] Webapp B ................................... SUCCESS [16.496s] [02:16:31]: [INFO] Webapp C ................................... SUCCESS [19.011s] [02:16:31]: [INFO] Assembly ................................... SUCCESS [1:45.872s] [02:16:31]: [INFO] ------------------------------------------------------------------------ [02:16:31]: [INFO] BUILD SUCCESS [02:16:31]: [INFO] ------------------------------------------------------------------------ [02:16:31]: [INFO] Total time: 7:33.655s [02:16:31]: [INFO] Finished at: Wed Jan 25 02:16:31 EST 2012 [02:16:31]: [INFO] Final Memory: 42M/317M [02:16:31]: [INFO] ------------------------------------------------------------------------ </code></pre> <p><strong>Update 2</strong></p> <p>Here is an empirical analysis of where my build is spending most of its time, using timestamp analysis provided by this bash script: <a href="https://gist.github.com/993139" rel="nofollow noreferrer">https://gist.github.com/993139</a></p> <p><img src="https://i.stack.imgur.com/PfPFb.gif" alt="Build Times by Task"></p> <p>It seems to me that I could disable FindBugs, PMD and Unit Tests for some builds. But I need the final build output - the Assembly. So let me focus my question - what can make Assembly Plugin run slowly?</p> <p><strong>Update 3</strong></p> <p>As expected, FindBugs, PMD and unit tests cut the build by over 50%</p> <pre><code>[INFO] ------------------------------------------------------------------------ [INFO] Reactor Summary: [INFO] [INFO] Project Parent .................................... SUCCESS [13.969s] [INFO] Dependencies ...................................... SUCCESS [0.094s] [INFO] Thrift Service .................................... SUCCESS [47.125s] [INFO] Thrift API Client Sample .......................... SUCCESS [11.922s] [INFO] Application ....................................... SUCCESS [3:10.922s] [INFO] Webapps parent .................................... SUCCESS [0.468s] [INFO] Webapp A .......................................... SUCCESS [18.157s] [INFO] Webapp B .......................................... SUCCESS [18.437s] [INFO] Webapp C .......................................... SUCCESS [1:00.672s] [INFO] Assembly .......................................... SUCCESS [3:55.969s] [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESS [INFO] ------------------------------------------------------------------------ [INFO] Total time: 9:58.609s [INFO] Finished at: Mon Feb 06 10:21:01 EST 2012 [INFO] Final Memory: 24M/59M [INFO] ---------------------------------------------------------------------- </code></pre> <p>I don't think that Assembly should take 4 minutes. During the assembly phase, I'm seeing a lot of the following:</p> <pre><code>[INFO] --- maven-assembly-plugin:2.2:single (assembly-full) @ assembly --- [INFO] Reading assembly descriptor: C:\projects\my-project\assembly/src/main/assembly/assembly-full.xml [INFO] project-2.9.3-SNAPSHOT/config/ already added, skipping [INFO] project-2.9.3-SNAPSHOT/config/ already added, skipping [INFO] project-2.9.3-SNAPSHOT/ already added, skipping [INFO] project-2.9.3-SNAPSHOT/var/ already added, skipping </code></pre> <p>Repeated with each assembly artifact. Could this somehow be the source of the slowness?</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload