Maven 3.0.5 is kinda old, do you see the same behaviour with the latest 3.3.1 release? I believe there were changes in parallel build, but don't know if they address your specific problem.
You may also want to try Takari Smart Builder [1]. It schedules build of the longest dependency chain first (called "build critical path"), which results in significant reduction of overall build time for some projects. I can help with setup (which is much easier with Maven 3.3.1, btw) and other questions here or on Takari User google group. [1] https://github.com/takari/takari-smart-builder -- Regards, Igor On Thu, Mar 26, 2015, at 05:47 AM, Wippermann, Peter wrote: > Hi everybody, > > I have a complex multi module build with 171 modules in total and a > nesting depth of up to 4. Too speed up the build, I wanted to use the > parallel build feature of Maven 3.0.5 with 4 threads: > https://cwiki.apache.org/confluence/display/MAVEN/Parallel+builds+in+Maven+3 > > The build starts like normal and the reactor build order is correctly > identified (and is identical to the single threaded one). > But the build fails shortly after, when the assembly plugin is looking > for a submodule's artefact file, which does not (yet!) exist. The final > print of the build status reveals, that projects where tried to build > from "the middle of the reactor build order". This certainly has to fail, > because their dependencies would have been earlier in the build order and > haven't been built yet. > > The situation is repeatable and always the same: 2 aggregators have been > built successfully and 3 aggregator projects have failed. > > I debugged Maven 3.0.5 to the point, that I think this is a bug, but > wanted to assure with you here first. > I suspect the initialisation of the Directed Acyclic Graph (DAG) in the > org.apache.maven.project.ProjectSorter Class to be faulty. I debugged it > for one of my multi module projects. There I can see that for all > dependencies, build plugins, build extensions and the parent, edges are > added to the DAG. But not so for the modules!? > > Since the modules are not considered, these aggregator projects are built > very early and cause the assembly plugin to fail afterwards. > Any ideas? Is this a bug? > > Best regards, > Peter Wippermann > > Senior Consultant > IBM Global Business Services > Application Innovation Services - Insurance > > -------------------------------------------------------------------------------- > Tel: 0511-645 x58384 > 0151-15 16 1870 > E-Mail: [email protected] > > IBM Deutschland; Stockholmer Allee 30a; 44269 Dortmund > -------------------------------------------------------------------------------- > IBM Deutschland GmbH / Vorsitzender des Aufsichtsrats: Martin Jetter - > Geschäftsführung: Martina Koederitz (Vorsitzende), Reinhard Reschke, > Dieter Scholz, Gregor Pillen, Ivo Koerner - Sitz der Gesellschaft: > Ehningen / Registergericht: Amtsgericht Stuttgart, HRB 14562 / > WEEE-Reg.-Nr. DE 99369940 > --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
