eolivelli commented on a change in pull request #290: [MNG-6774] - Speedup
project graph build by paralleling operations
URL: https://github.com/apache/maven/pull/290#discussion_r382974440
##########
File path:
maven-core/src/main/java/org/apache/maven/graph/DefaultGraphBuilder.java
##########
@@ -401,18 +403,49 @@ else if ( selectedProject.isDirectory() )
return projects;
}
- List<File> files = Arrays.asList( request.getPom().getAbsoluteFile() );
+ List<File> files = Collections.singletonList(
request.getPom().getAbsoluteFile() );
collectProjects( projects, files, request );
return projects;
}
- private void collectProjects( List<MavenProject> projects, List<File>
files, MavenExecutionRequest request )
- throws ProjectBuildingException
+ private void collectProjects( List<MavenProject> projects, final
List<File> files,
+ final MavenExecutionRequest request ) throws
ProjectBuildingException
{
- ProjectBuildingRequest projectBuildingRequest =
request.getProjectBuildingRequest();
+ final ProjectBuildingRequest projectBuildingRequest =
request.getProjectBuildingRequest();
+
+ List<ProjectBuildingResult> results;
+ long start = System.currentTimeMillis();
+ if ( request.getDegreeOfConcurrency() <= 1 || Boolean.getBoolean(
"maven.concurrentGraph.disable" ) )
Review comment:
Why binding this improvement to **request.getDegreeOfConcurrency()**?
This is only about building the model and not executing plugins, isn't it?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services