cstamas commented on code in PR #1008:
URL: https://github.com/apache/maven/pull/1008#discussion_r1115375813
##########
maven-core/src/main/java/org/apache/maven/project/DefaultProjectBuilder.java:
##########
@@ -999,6 +1000,9 @@ class InternalConfig {
}
private ModelCache createModelCache(RepositorySystemSession session) {
- return modelCacheFactory.createCache(session);
+ // MNG-7693: for older clients (not injecting ModelCacheFactory), make
this work OOTB w/ defaults
+ return modelCacheFactory != null
+ ? modelCacheFactory.createCache(session)
+ : new DefaultModelCacheFactory().createCache(session);
Review Comment:
We can investigate this, yes, but for this PR I'd really not change any
semantics here, just fix the NPE for older clients. ie. restore backward
compatibility.
--
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]