Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-16500

Enable JDK 19 preview options for MMapDirectory V2

    XMLWordPrintableJSON

Details

    • Task
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • main (10.0), 9.2
    • scripts and tools
    • None

    Description

      uschindler wrote on https://issues.apache.org/jira/browse/SOLR-16442?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17620361#comment-17620361 ticket:

      We should also think of updating the startup scripts to pass --enable-preview to JVM if exactly Java 19 is detected. Elasticsearch and Opensearch will / have already done this. Not doing this will print a startup warning on Java 19 to Java logging.

      The main reason to pass --enable-preview to the JVM is to allow MMapDirectory V2 to be enabled and memory mapping happening in larger junks for less overhead and use of kernel resources (see vm.max-map-count sysctl). It also reduces risk of crushing JDK on bad written plugins or bugs with reopening IndexSearcher/IndexReader.

      See https://github.com/apache/lucene/pull/912 for more details.

      Attachments

        Issue Links

          Activity

            People

              krisden Kevin Risden
              cpoerschke Christine Poerschke
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 50m
                  50m