You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@solr.apache.org by "risdenk (via GitHub)" <gi...@apache.org> on 2023/03/01 17:23:56 UTC

[GitHub] [solr] risdenk commented on a diff in pull request #1360: SOLR 16642 : upgrade Solr to use Lucene 9.5.0

risdenk commented on code in PR #1360:
URL: https://github.com/apache/solr/pull/1360#discussion_r1122086282


##########
solr/core/src/java/org/apache/solr/core/MMapDirectoryFactory.java:
##########
@@ -63,7 +63,7 @@ protected Directory create(String path, LockFactory lockFactory, DirContext dirC
       throws IOException {
     MMapDirectory mapDirectory = new MMapDirectory(Path.of(path), lockFactory, maxChunk);
     try {
-      mapDirectory.setUseUnmap(unmapHack);
+      System.setProperty(MMapDirectory.ENABLE_UNMAP_HACK_SYSPROP, String.valueOf(unmapHack));

Review Comment:
   I vote to remove the `unmapHack` references. `unmap` isn't documented in Solr codebase anyway. https://github.com/search?q=repo%3Aapache%2Fsolr%20unmap&type=code
   
   If someone is down at this level - they can follow the Lucene docs for disabling this - https://lucene.apache.org/core/9_5_0/core/org/apache/lucene/store/MMapDirectory.html#ENABLE_UNMAP_HACK_SYSPROP
   
   If we want to be nicer to users - then logging a warning is a valid option.



-- 
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-unsubscribe@solr.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org