Solr
  1. Solr
  2. SOLR-6560

Solr example file has outdated termIndexInterval entry

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 4.10
    • Fix Version/s: 5.0, 6.0
    • Component/s: documentation
    • Labels:
      None

      Description

      The termIndexInterval comment and example settings in the example solrconfig.xml file is left over from Solr 3.x versions. It does not apply to the default Solr 4.x installation and its presence in the example is confusing.

      According to the JavaDocs for IndexWriterConfig, the Lucene level
      implementations of setTermIndexInterval and setReaderTermsIndexDivisor these do not apply to the default Solr4 PostingsFormat implementation.

      From (http://lucene.apache.org/core/4_10_0/core/org/apache/lucene/index/IndexWriterConfig.html#setTermIndexInterval%28int%29 )
      "This parameter does not apply to all PostingsFormat implementations, including the default one in this release. It only makes sense for term indexes that are implemented as a fixed gap between terms. For example, Lucene41PostingsFormat implements the term index instead based upon how terms share prefixes. To configure its parameters (the minimum and maximum size for a block), you would instead use Lucene41PostingsFormat.Lucene41PostingsFormat(int, int). which can also be configured on a per-field basis:"

      The (soon to be ) attached patch just removes the outdated example.
      Documentation on the wiki and Solr ref guide should also be updated.

      Since the Solr 4 default postingsformat is so much more efficient than Solr 3.x, there might no longer be a use case for messing with the parameters.

      for users who have a strong need to explicitly control this type of setting, you'll need to do so by overridding the default codec – either by specifing a custom <codecFactory>, or by using the default SchemaCodecFactory, but specify per-field postingsFormats )(for the fields you want to modify) using custom classes – for example: that subclass Lucene41PostingsFormat using the desired values...

      https://lucene.apache.org/solr/4_10_2/solr-core/org/apache/solr/core/CodecFactory.html
      https://lucene.apache.org/solr/4_10_2/solr-core/org/apache/solr/core/SchemaCodecFactory.html
      https://lucene.apache.org/core/4_10_2/core/org/apache/lucene/codecs/lucene41/Lucene41PostingsFormat.html#Lucene41PostingsFormat(int,%20int)

      https://cwiki.apache.org/confluence/display/solr/Field+Type+Definitions+and+Properties#FieldTypeDefinitionsandProperties-GeneralProperties

      1. CHANGES.SOLR-4136.patch
        1 kB
        Hoss Man
      2. SOLR-6560.patch
        4 kB
        Hoss Man
      3. SOLR-6560.patch
        0.7 kB
        Tom Burton-West

        Issue Links

          Activity

          Hide
          Tom Burton-West added a comment -

          Patch removes offending lines in example solrconfig.xml

          Show
          Tom Burton-West added a comment - Patch removes offending lines in example solrconfig.xml
          Hide
          Hoss Man added a comment -

          it looks like this was cleaned up in the example configs as part of SOLR-3619.

          there's still some stray test files refering to this that would be nice to clean up though (patch in a second)

          Show
          Hoss Man added a comment - it looks like this was cleaned up in the example configs as part of SOLR-3619 . there's still some stray test files refering to this that would be nice to clean up though (patch in a second)
          Hide
          Hoss Man added a comment -

          remove all remaining vestigates of termIndexInterval in some test configs

          Show
          Hoss Man added a comment - remove all remaining vestigates of termIndexInterval in some test configs
          Hide
          Hoss Man added a comment -

          updated patch to include "Upgrade" note regarding this option (since starting in 5.0, it will actaully cause an error to try and use it in solrconfig.xml)

          Show
          Hoss Man added a comment - updated patch to include "Upgrade" note regarding this option (since starting in 5.0, it will actaully cause an error to try and use it in solrconfig.xml)
          Hide
          Hoss Man added a comment -

          updated description with notes for expert users who still want to try and customize the postings format to override the defaults.

          Show
          Hoss Man added a comment - updated description with notes for expert users who still want to try and customize the postings format to override the defaults.
          Hide
          ASF subversion and git services added a comment -

          Commit 1643381 from hossman@apache.org in branch 'dev/trunk'
          [ https://svn.apache.org/r1643381 ]

          SOLR-6560: Purge termIndexInterval from example/test configs

          Show
          ASF subversion and git services added a comment - Commit 1643381 from hossman@apache.org in branch 'dev/trunk' [ https://svn.apache.org/r1643381 ] SOLR-6560 : Purge termIndexInterval from example/test configs
          Hide
          ASF subversion and git services added a comment -

          Commit 1643382 from hossman@apache.org in branch 'dev/branches/branch_5x'
          [ https://svn.apache.org/r1643382 ]

          SOLR-6560: Purge termIndexInterval from example/test configs (merge r1643381)

          Show
          ASF subversion and git services added a comment - Commit 1643382 from hossman@apache.org in branch 'dev/branches/branch_5x' [ https://svn.apache.org/r1643382 ] SOLR-6560 : Purge termIndexInterval from example/test configs (merge r1643381)
          Hide
          Hoss Man added a comment -

          thanks tom,

          i think we're good to go in 5.0

          Show
          Hoss Man added a comment - thanks tom, i think we're good to go in 5.0
          Hide
          Anshum Gupta added a comment -

          Bulk close after 5.0 release.

          Show
          Anshum Gupta added a comment - Bulk close after 5.0 release.

            People

            • Assignee:
              Hoss Man
              Reporter:
              Tom Burton-West
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development