You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by GitBox <gi...@apache.org> on 2021/02/08 16:29:52 UTC

[GitHub] [maven] gnodet opened a new pull request #442: Fix maven parallel builds

gnodet opened a new pull request #442:
URL: https://github.com/apache/maven/pull/442


   Fix exception on master when using parallel builds.


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [maven] michael-o commented on pull request #442: Fix maven parallel builds

Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #442:
URL: https://github.com/apache/maven/pull/442#issuecomment-775388791


   Thanks for the fix. We first need to know whether this class was intended to be used concurrently. @rfscholte Can you take a look?


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [maven] rfscholte removed a comment on pull request #442: Fix maven parallel builds

Posted by GitBox <gi...@apache.org>.
rfscholte removed a comment on pull request #442:
URL: https://github.com/apache/maven/pull/442#issuecomment-797673525






----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [maven] gnodet commented on pull request #442: Fix maven parallel builds

Posted by GitBox <gi...@apache.org>.
gnodet commented on pull request #442:
URL: https://github.com/apache/maven/pull/442#issuecomment-775474318


   > I need to investigate this a bit more. My thought would be that during phase 1 the maps are filled, and this is single threaded. During phase 2 the builds are done in parallel, and maps are only used for retrieval. In such case I wouldn't expect the need for concurrent hashmaps. Or am I missing a detail?
   
   Fwiw, the second thread was accessing the map from the following location:
   https://github.com/apache/maven/blob/673a7d1fef55795ea47a147f158a1411475e7495/maven-model-builder/src/main/java/org/apache/maven/model/building/AbstractModelSourceTransformer.java#L153-L163


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [maven] gnodet edited a comment on pull request #442: Fix maven parallel builds

Posted by GitBox <gi...@apache.org>.
gnodet edited a comment on pull request #442:
URL: https://github.com/apache/maven/pull/442#issuecomment-775365752


   @michael-o this looks like a fix for https://issues.apache.org/jira/projects/MNG/issues/MNG-7087 at first glance
   I create this PR to fix the `input contained no data` exception I had with master + parallel build


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [maven] rfscholte removed a comment on pull request #442: Fix maven parallel builds

Posted by GitBox <gi...@apache.org>.
rfscholte removed a comment on pull request #442:
URL: https://github.com/apache/maven/pull/442#issuecomment-797673264






----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [maven] rfscholte commented on pull request #442: Fix maven parallel builds

Posted by GitBox <gi...@apache.org>.
rfscholte commented on pull request #442:
URL: https://github.com/apache/maven/pull/442#issuecomment-775452109


   I need to investigate this a bit more. My thought would be that during phase 1 the maps are filled, and this is single threaded. During phase 2 the builds are done in parallel, and maps are only used for retrieval. In such case I wouldn't expect the need for concurrent hashmaps. Or am I missing a detail?


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [maven] gnodet commented on pull request #442: Fix maven parallel builds

Posted by GitBox <gi...@apache.org>.
gnodet commented on pull request #442:
URL: https://github.com/apache/maven/pull/442#issuecomment-797725461


   > This is the next I want to fix. I do understand the cause: before the commit both filemodel and raw model where part of phase 1, now raw model has moved to phase 2. This is also where the build/consumer builds up the context, so it can be re-used during distribution. So yes, these must become ConcurrentHashMaps.
   > @gnodet I would expect ConcurrentHashMaps to be enough, why the need for the extra layer of `Holder`?
   
   @rfscholte the reason is explain at https://issues.apache.org/jira/browse/MNG-7111, it can cause deadlocks... The holder makes the usage of the concurrent hash map safe.


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [maven] rfscholte closed pull request #442: [MNG-7111] Fix maven parallel builds

Posted by GitBox <gi...@apache.org>.
rfscholte closed pull request #442:
URL: https://github.com/apache/maven/pull/442


   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [maven] gnodet commented on pull request #442: Fix maven parallel builds

Posted by GitBox <gi...@apache.org>.
gnodet commented on pull request #442:
URL: https://github.com/apache/maven/pull/442#issuecomment-775365752


   @michael-o this looks like a fix for https://issues.apache.org/jira/projects/MNG/issues/MNG-7087 at first glance


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [maven] rfscholte commented on pull request #442: Fix maven parallel builds

Posted by GitBox <gi...@apache.org>.
rfscholte commented on pull request #442:
URL: https://github.com/apache/maven/pull/442#issuecomment-797673154


   This is the next I want to fix. I do understand the cause: before the commit both filemodel and raw model where part of phase 1, now raw model has moved to phase 2. This is also where the build/consumer builds up the context, so it can be re-used during distribution. So yes, these must become ConcurrentHashMaps.
   @gnodet I would expect ConcurrentHashMaps to be enough, why the need for the extra layer of `Holder`?
   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [maven] gnodet commented on pull request #442: Fix maven parallel builds

Posted by GitBox <gi...@apache.org>.
gnodet commented on pull request #442:
URL: https://github.com/apache/maven/pull/442#issuecomment-792626463


   @rfscholte I've added another commit which fix a deadlock.


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [maven] rfscholte commented on pull request #442: [MNG-7111] Fix maven parallel builds

Posted by GitBox <gi...@apache.org>.
rfscholte commented on pull request #442:
URL: https://github.com/apache/maven/pull/442#issuecomment-798157524


   Merged with https://github.com/apache/maven/commit/9e19b57c720d226b0b30992535819f700a665d14
   Thanks for this PR!


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [maven] michael-o commented on pull request #442: Fix maven parallel builds

Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #442:
URL: https://github.com/apache/maven/pull/442#issuecomment-775308876


   Is there a JIRA issue for that and exceptions you have observed?


----------------------------------------------------------------
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:
users@infra.apache.org