Solr
  1. Solr
  2. SOLR-610

Add support for hl.maxAnalyzedChars=-1 to highlight the whole field

    Details

    • Type: New Feature New Feature
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 1.3
    • Fix Version/s: 1.3
    • Component/s: highlighter
    • Labels:
      None
    • Environment:

      Tomcat 5.5

      Description

      Add support for specifying negative values for the hl.maxAnalyzedChars parameter to be able highlight the whole field without having to know its size.

      1. SOLR-556-610.patch
        12 kB
        Lars Kotthoff
      2. SOLR-610-maxanalyzed.patch
        3 kB
        Lars Kotthoff

        Issue Links

          Activity

          Hide
          Lars Kotthoff added a comment -

          Patch adding the described feature and a unit test for it. Also using highlighter.setMaxDocCharsToAnalyze instead of the deprecated highlighter.setMaxDocBytesToAnalyze to tell Lucene how many characters to analyze.

          This patch clashes with the changes in SOLR-556, I'll be happy to provide a patch which covers both issues if required.

          Show
          Lars Kotthoff added a comment - Patch adding the described feature and a unit test for it. Also using highlighter.setMaxDocCharsToAnalyze instead of the deprecated highlighter.setMaxDocBytesToAnalyze to tell Lucene how many characters to analyze. This patch clashes with the changes in SOLR-556 , I'll be happy to provide a patch which covers both issues if required.
          Hide
          Mike Klaas added a comment -

          Hi Lars,

          I was planning on commiting SOLR-556. Would you rather I commit that first, or to produce a unified patch instead?

          -Mike

          Show
          Mike Klaas added a comment - Hi Lars, I was planning on commiting SOLR-556 . Would you rather I commit that first, or to produce a unified patch instead? -Mike
          Hide
          Lars Kotthoff added a comment -

          Attaching combined SOLR-556,610 patch. Submitting this one should be easier, as the changes for SOLR-610 can be made in an easier (and more efficient) way with SOLR-556 comitted. I think the SOLR-610 changes are small and non-intrusive enough to be sneaked in piggybacked on another patch

          Show
          Lars Kotthoff added a comment - Attaching combined SOLR-556 ,610 patch. Submitting this one should be easier, as the changes for SOLR-610 can be made in an easier (and more efficient) way with SOLR-556 comitted. I think the SOLR-610 changes are small and non-intrusive enough to be sneaked in piggybacked on another patch
          Hide
          Mike Klaas added a comment -

          commited. Thanks lars!

          Show
          Mike Klaas added a comment - commited. Thanks lars!

            People

            • Assignee:
              Mike Klaas
              Reporter:
              Lars Kotthoff
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development