goutamadwant opened a new pull request, #12766:
URL: https://github.com/apache/maven/pull/12766

   Fixes #12597.
   
   `mappedSources` uses a `ConcurrentHashMap`, but its values were ordinary
   `HashSet` instances. Parallel model discovery could therefore lose sources
   when multiple tasks updated the same group/artifact index.
   
   Use `ConcurrentHashMap.newKeySet()` for each mapped source set. This 
preserves
   duplicate suppression while making concurrent updates and iteration safe.
   
   Regression coverage exercises concurrent writes to both the direct
   group/artifact key and the secondary null-group key, verifies concurrent
   collection semantics and multi-source lookup behavior, and preserves 
duplicate
   suppression.
   
   A backport to `maven-4.0.x` may be appropriate.
   
   Tests:
   - `mvn -pl impl/maven-impl verify` (552 tests passed, 4 skipped)
   - `mvn -Prun-its verify` under Java 21 (all 1,051 Core ITs executed)
   - Targeted Java 21 rerun of the two previously toolchain-sensitive IT classes
     (4 tests passed)
   
   The full Core IT run reported two stale generated-file errors in toolchain
   tests and one existing MNG-8181 log-format assertion. None exercises the
   changed model-source code.
   
   - [x] Your pull request should address just one issue, without pulling in 
other changes.
   - [x] Write a pull request description that is detailed enough to understand 
what the pull request does, how, and why.
   - [x] Each commit in the pull request should have a meaningful subject line 
and body.
   - [x] Write unit tests that match behavioral changes, where the tests fail 
if the changes to the runtime are not applied.
   - [x] Run `mvn verify` to make sure basic checks pass.
   - [ ] You have run the Core IT successfully. See the test details above.
   - [x] I hereby declare this contribution to be licenced under the Apache 
License Version 2.0, January 2004.
   - [ ] In any other case, please file an Apache Individual Contributor 
License Agreement.


-- 
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]

Reply via email to