famod commented on a change in pull request #662:
URL: https://github.com/apache/maven/pull/662#discussion_r785506735
##########
File path:
maven-core/src/main/java/org/apache/maven/lifecycle/internal/builder/multithreaded/MultiThreadedBuilder.java
##########
@@ -183,19 +196,26 @@ private void multiThreadedProjectTaskSegmentBuild(
ConcurrencyDependencyGraph an
private Callable<ProjectSegment> createBuildCallable( final MavenSession
rootSession,
final ProjectSegment
projectBuild,
final ReactorContext
reactorContext,
- final TaskSegment
taskSegment, final ThreadOutputMuxer muxer )
+ final TaskSegment
taskSegment,
+ final
ThreadOutputMuxer muxer,
+ final Set<String>
duplicateArtifactIds )
{
return () ->
{
final Thread currentThread = Thread.currentThread();
final String originalThreadName = currentThread.getName();
- currentThread.setName( "mvn-builder-" +
projectBuild.getProject().getId() );
+ final MavenProject project = projectBuild.getProject();
+
+ final String threadNameSuffix = duplicateArtifactIds.contains(
project.getArtifactId() )
+ ? project.getGroupId() + ":" + project.getArtifactId()
+ : project.getArtifactId();
+ currentThread.setName( "mvn-builder_" + threadNameSuffix );
Review comment:
I did it just for readability. It's not a big thing, so I can change it
back.
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]