ppalaga commented on code in PR #797:
URL: https://github.com/apache/maven-mvnd/pull/797#discussion_r1122109132


##########
daemon/src/main/java/org/apache/maven/project/SnapshotModelCacheFactory.java:
##########
@@ -45,6 +45,9 @@ public SnapshotModelCacheFactory(DefaultModelCacheFactory 
factory) {
 
     @Override
     public ModelCache createCache(RepositorySystemSession session) {
-        return new SnapshotModelCache(globalCache, 
factory.createCache(session));
+        boolean enableModelCache = 
Boolean.parseBoolean(System.getProperty("mvnd.modelCache", "true"));

Review Comment:
   Could you please add the new property to 
`org.mvndaemon.mvnd.common.Environment` and add a bit of JavaDoc describing 
what it is doing?
   
   Naming: Looking at other boolean properties, we have in 
`org.mvndaemon.mvnd.common.Environment`, perhaps the `mvnd.noModelCache` style 
would suit best here. I am not especially happy about negating names, but we 
already have a couple of those, and they are easier to use (given the default 
is with model cache enabled) from command line: `-Dmvnd.noModelCache` vs. 
`-Dmvnd.modelCache=false`. It is less typing. What do others think?



-- 
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: issues-unsubscr...@maven.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to