[ https://issues.apache.org/jira/browse/MNG-5571?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15497379#comment-15497379 ]
Matt Nelson commented on MNG-5571: ---------------------------------- There are alternatives that could supply a correct command. * Update the command to include a {{-pl b,c,d}} option that includes all the modules that had not finished building. * Use the reactor dependency graph to only supply the next nodes in the tree with the also make flag, {{-pl b,c -am}} > Instructions to resume the build can be misleading with -T parallel builds > -------------------------------------------------------------------------- > > Key: MNG-5571 > URL: https://issues.apache.org/jira/browse/MNG-5571 > Project: Maven > Issue Type: Bug > Reporter: Derek Lewis > Priority: Minor > Attachments: resume-from-testcase.zip > > > In a project with many modules that are able to build in parallel, if one > fails the build, the output says to use -rf to resume from that module. > However, this may not run the other modules that were running in parallel. > If one of those modules also had failures, but had not yet reached those > failures during the first build, and those modules aren't build in the second > build, the build will pass, despite these 'hidden' errors. > In the example I've attached, there are four submodules, a, b, c and d. > Module d depends on a, b, and c, and all modules share a common parent module. > The properties fail.a, fail.b, and fail.c will cause the respective module to > fail. > Build first with just "mvn install -T4". > Next, imagine making a change in modules a, b, and c that break them, and > build with "mvn install -T4 -Dfail.a -Dfail.b -Dfail.c" > Due to the timing in the test poms (using antrun sleep), this should print: > {noformat} > [ERROR] After correcting the problems, you can resume the build with the > command > [ERROR] mvn <goals> -rf :c > {noformat} > Above that, you will see it reporting the failure of all three modules, but > in a lot of cases where there are surefire tests failing, it's extremely > difficult to tell that more than one module failed. As a result, I generally > just look at the module it's told me to resume from, to find failures. > So, pretend you've done that, but the errors in a and b remain, and run "mvn > install -T4 -Dfail.a -Dfail.b -rf :c" as it's suggested. > The build passes, giving a false sense of confidence. -- This message was sent by Atlassian JIRA (v6.3.4#6332)